[Geoserver-users] Python geoscript input types
Dear list, I need your help with a more advanced wps python script with Geoscript. Thank you all in advance for your valuable time and comments. I have successfully installed the 2.5.1 Geoserver with the geoscript and wps extensions and implemented some simple examples as the one described here: http://suite.opengeo.org/opengeo-docs/processing/scripting/processcreate.html I have also successfully implemented my own wps that combines gs:BarnesSurface and gs:Contour For your help gs:Contour is defined here: http://www.massapi.com/source/geoserver-2.1.1-src/geoserver-2.1.1/extension/wps/wps-core/src/main/java/org/geoserver/wps/gs/ContourProcess.java.html As you can see it requires as input either levels that is type double[] either interval that is type Double The following code is working fine having interval in place of levels and Double instead of ArrayListDouble() but I can't find how I should define levels1 in order to make it work with Double[]. I have made some efforts as the following code that is throwing an error org.geotools.process.ProcessException: Could not convert -100 to target type [D Do you have any ideas how to define levels1 in order to make it work? Kind Regars, Vassilis Dalakas from java.lang import String, Integer, Double from geoscript.layer import Layer, Raster from geoserver.wps import process from geoscript.process import Process from geoscript.geom import * from org.geotools.data.simple import SimpleFeatureCollection from org.geotools.geometry.jts import ReferencedEnvelope from org.geotools.coverage.grid import GridCoverage2D from java.util import ArrayList as ArrayList barnes = Process.lookup('gs:BarnesSurface') contour = Process.lookup('gs:Contour') @process( title = 'Barnes and Contour', description = 'Uses Barnes Analysis to compute an interpolated surface over a set of irregular data points and computes contour lines at specified intervals or levels for the values in a raster.', inputs = { 'data1': (SimpleFeatureCollection, 'Input features'), 'valueAttr1': (String, 'Name of attribute containing the data value to be interpolated'), 'scale1': (Double, 'Length scale for the interpolation, in units of the source data CRS'), 'maxObservationDistance1': (Double, 'Maximum distance to an observation for it to support a grid cell, in units of the source CRS (default = 0, meaning all observations used)'), 'pixelsPerCell1': (Integer, 'Resolution of the computed grid in pixels per grid cell (default = 1)'), 'queryBuffer1': (Double, 'Distance to expand the query envelope by, in units of the source CRS (larger values provide a more stable surface)'), 'outputBBOX1': (ReferencedEnvelope, 'Bounding box for output'), 'outputWidth1': (Integer, 'Width of the output raster in pixels'), 'outputHeight1': (Integer, 'Height of the output raster in pixels'), 'levels1': (ArrayListDouble(), 'Values of levels at which to generate contours') }, outputs = { 'result': (SimpleFeatureCollection, 'Contour line features. Contour level is in value attribute.') } ) def run(data1, valueAttr1, scale1, maxObservationDistance1, pixelsPerCell1, queryBuffer1, outputBBOX1, outputWidth1, outputHeight1, levels1): barnesed = barnes.run(data=data1, valueAttr=valueAttr1, scale=scale1, maxObservationDistance=maxObservationDistance1, pixelsPerCell=pixelsPerCell1, queryBuffer=queryBuffer1, outputBBOX=outputBBOX1, outputWidth=outputWidth1, outputHeight=outputHeight1)['result'] return contour.run(data=barnesed, levels=levels1)['result'] -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Geoserver CSS Module
I suppose I am just confused about the use of z-index there - I usually use a z-index 1 or 2 (and then only if needed based on funny overlapping - like simulating line casing, or ensuring that a polygon outline is drawn separately overtop of the fill). I recommend trying very simple examples like this and reviewing the SLD that is produced. Jody Garnett On Wed, Jun 25, 2014 at 2:42 PM, Mark Cupitt markcup...@gmail.com wrote: Hi Jody, in thinking through your remarks, in my last response would this be a better approach to the example I gave? [landuse='forest'][@scale6][@scale10]{ fill-size: 20px; } [landuse='forest'][@scale6]{ fill-size: 30px; } [landuse='commercial'][@scale100] { z-index: 40; stroke: #5F9EA0; fill: #87CEFA, url( http://icons.markware.net/geoserver/icons/img/areas/commercial.png;); stroke-width: 0.5px; fill-opacity: 0.75; label: [name]; font-size: 10px; font-fill: #00; } [landuse='forest']{ z-index: 30; stroke: #CBEBB6; fill: #CBEBB6, url( http://icons.markware.net/geoserver/icons/img/areas/forest.png;); } Regards Mark -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
[Geoserver-users] [geoserver-user]call geoserver api rest by script bash
Hi all, I have problems with calls rest of GeoServer. I would like to post some geotiff. In my bash script I compose the string and then run it with exec $nameVariable The execution of this command causes this error in GeoServer: /org.geoserver.rest.RestletException//:java.net.MalformedURLException//: noprotocol:file :/ // home // The same statement if I do an echo in the terminal and then run it, everything works fine maybe there are problems with double quotes? This is the instruction: /instruction='//curl-//v-//u//' $8 '//,' $9 '//-//XPUT//-HContent-type//: text / plain//-dfile :/ ///'$ 7 $baseName'//' http://'$4'//: 8080/GeoServer/ rest/ workspaces/'//$ {//10}//'/coveragestores/'//$ {//11}//'/external.geotiff'/ ///exec//$//instruction/ Note: I also tried this instruction = curl-v-u $ 8 , $ 9 -XPUT-H \Content-type: text / plain\-d \file :/ / $ 7 $ baseName \'' http:// $ 4: 8080 / GeoServer / rest / workspaces / $ {10} / coveragestores / $ {11} / external.geotiff Regards. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] [geoserver-user]call geoserver api rest by script bash
Please, send the full bash script. == GeoServer Professional Services from the experts! Visit http://goo.gl/NWWaa2 for more information. == Ing. Alessio Fabiani @alfa7691 Founder/Technical Lead GeoSolutions S.A.S. Via Poggio alle Viti 1187 55054 Massarosa (LU) Italy phone: +39 0584 962313 fax: +39 0584 1660272 mob: +39 331 6233686 http://www.geo-solutions.it http://twitter.com/geosolutions_it --- On Wed, Jun 25, 2014 at 12:21 PM, sanguinela sanguin...@gmail.com wrote: Hi all, I have problems with calls rest of GeoServer. I would like to post some geotiff. In my bash script I compose the string and then run it with exec $nameVariable The execution of this command causes this error in GeoServer: *org.geoserver.rest.RestletException**:* *java.net.MalformedURLException**: no* *protocol:* *file :/ /* */ home /* ** The same statement if I do an echo in the terminal and then run it, everything works fine maybe there are problems with double quotes? This is the instruction: *instruction* *=* *'**curl-**v-**u**' $* *8 '**,' $* *9 '**-**XPUT**-H* *Content-type**: text / plain**-d* *file :/ /**'* *$ 7 $* *baseName* *'**' http://* *'$* *4'**: 8080* */* *GeoServer* */ rest* */ workspaces* */* *'**$ {**10}**'* */* *coveragestores* */* *'**$ {**11}**'* */* *external.geotiff* *'* *exec** $**instruction* Note: I also tried this instruction = curl-v-u $ 8 , $ 9 -XPUT-H \Content-type: text / plain\-d \file :/ / $ 7 $ baseName \'' http:// $ 4: 8080 / GeoServer / rest / workspaces / $ {10} / coveragestores / $ {11} / external.geotiff Regards. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Geoserver CSS Module
Hi Jody, FYI, I tried the recode function, it is excellent, however, it does not reproduce this stroke: #00, #4169E1; using .. stroke:[ recode(highway, 'motorway', '#00, #4169E1' )]; Which is sad .. that would be killer .. Cheers Mark Regards Mark Cupitt If we change the world, let it bear the mark of our intelligence See me on Open StreetMap https://www.openstreetmap.org/user/Mark_Cupitt See me on LinkedIn http://ph.linkedin.com/in/markcupitt *See me on StackExchange http://gis.stackexchange.com/users/17846/mark-c* === The contents of this email are intended only for the individual(s) to whom it is addressed and may contain confidential or privileged information. If you are not the intended recipient, you must not disclose, copy, distribute, or use the contents of this email. If you have received this email in error, please notify the sender immediately and delete the email and any attachments. === On Wed, Jun 25, 2014 at 5:59 PM, Jody Garnett jody.garn...@gmail.com wrote: I suppose I am just confused about the use of z-index there - I usually use a z-index 1 or 2 (and then only if needed based on funny overlapping - like simulating line casing, or ensuring that a polygon outline is drawn separately overtop of the fill). I recommend trying very simple examples like this and reviewing the SLD that is produced. Jody Garnett On Wed, Jun 25, 2014 at 2:42 PM, Mark Cupitt markcup...@gmail.com wrote: Hi Jody, in thinking through your remarks, in my last response would this be a better approach to the example I gave? [landuse='forest'][@scale6][@scale10]{ fill-size: 20px; } [landuse='forest'][@scale6]{ fill-size: 30px; } [landuse='commercial'][@scale100] { z-index: 40; stroke: #5F9EA0; fill: #87CEFA, url( http://icons.markware.net/geoserver/icons/img/areas/commercial.png;); stroke-width: 0.5px; fill-opacity: 0.75; label: [name]; font-size: 10px; font-fill: #00; } [landuse='forest']{ z-index: 30; stroke: #CBEBB6; fill: #CBEBB6, url( http://icons.markware.net/geoserver/icons/img/areas/forest.png;); } Regards Mark -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Geoserver CSS Module
Hi Jody, I am using the z-index as follows In the polygon styling: water z-index: 50; forest z-index: 40; national parks z-index: 30; This should ensure that river polys are drawn over the top of forests and both drawn over the top of National Parks The docs to not specify any magnitudes for it, and it appears to be a way of grouping styles within a feature type style and ordering the featuretypestyle so the rendering is as required. For roads, I am using the following CSS stroke: #00, #3CB371; stroke-width: 5.0px, 3.0px; which forces two draws of the line. the first at # 5px, then drawn again with #3CB371 at 3px to give the thinner line with a black casing. I do use z-index on the roads to ensure that motorways are drawn on top of trunks, which are drawn on top of primary's, which are drawn on top of secondary's, etc Cheers Mark Regards Mark Cupitt If we change the world, let it bear the mark of our intelligence See me on Open StreetMap https://www.openstreetmap.org/user/Mark_Cupitt See me on LinkedIn http://ph.linkedin.com/in/markcupitt *See me on StackExchange http://gis.stackexchange.com/users/17846/mark-c* === The contents of this email are intended only for the individual(s) to whom it is addressed and may contain confidential or privileged information. If you are not the intended recipient, you must not disclose, copy, distribute, or use the contents of this email. If you have received this email in error, please notify the sender immediately and delete the email and any attachments. === On Wed, Jun 25, 2014 at 5:59 PM, Jody Garnett jody.garn...@gmail.com wrote: I suppose I am just confused about the use of z-index there - I usually use a z-index 1 or 2 (and then only if needed based on funny overlapping - like simulating line casing, or ensuring that a polygon outline is drawn separately overtop of the fill). I recommend trying very simple examples like this and reviewing the SLD that is produced. Jody Garnett On Wed, Jun 25, 2014 at 2:42 PM, Mark Cupitt markcup...@gmail.com wrote: Hi Jody, in thinking through your remarks, in my last response would this be a better approach to the example I gave? [landuse='forest'][@scale6][@scale10]{ fill-size: 20px; } [landuse='forest'][@scale6]{ fill-size: 30px; } [landuse='commercial'][@scale100] { z-index: 40; stroke: #5F9EA0; fill: #87CEFA, url( http://icons.markware.net/geoserver/icons/img/areas/commercial.png;); stroke-width: 0.5px; fill-opacity: 0.75; label: [name]; font-size: 10px; font-fill: #00; } [landuse='forest']{ z-index: 30; stroke: #CBEBB6; fill: #CBEBB6, url( http://icons.markware.net/geoserver/icons/img/areas/forest.png;); } Regards Mark -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Geoserver CSS Module
I don't think you did that correctly - you were trying to provide two expressions right - for different z-indexs? So keep using two expressions: stroke: [recode(highway, 'motorway', '#00')], [recode(highway, 'motorway', '#4169E1')] Jody Garnett On Wed, Jun 25, 2014 at 8:33 PM, Mark Cupitt markcup...@gmail.com wrote: Hi Jody, FYI, I tried the recode function, it is excellent, however, it does not reproduce this stroke: #00, #4169E1; using .. stroke:[ recode(highway, 'motorway', '#00, #4169E1' )]; Which is sad .. that would be killer .. Cheers Mark Regards Mark Cupitt If we change the world, let it bear the mark of our intelligence See me on Open StreetMap https://www.openstreetmap.org/user/Mark_Cupitt See me on LinkedIn http://ph.linkedin.com/in/markcupitt *See me on StackExchange http://gis.stackexchange.com/users/17846/mark-c* === The contents of this email are intended only for the individual(s) to whom it is addressed and may contain confidential or privileged information. If you are not the intended recipient, you must not disclose, copy, distribute, or use the contents of this email. If you have received this email in error, please notify the sender immediately and delete the email and any attachments. === On Wed, Jun 25, 2014 at 5:59 PM, Jody Garnett jody.garn...@gmail.com wrote: I suppose I am just confused about the use of z-index there - I usually use a z-index 1 or 2 (and then only if needed based on funny overlapping - like simulating line casing, or ensuring that a polygon outline is drawn separately overtop of the fill). I recommend trying very simple examples like this and reviewing the SLD that is produced. Jody Garnett On Wed, Jun 25, 2014 at 2:42 PM, Mark Cupitt markcup...@gmail.com wrote: Hi Jody, in thinking through your remarks, in my last response would this be a better approach to the example I gave? [landuse='forest'][@scale6][@scale10]{ fill-size: 20px; } [landuse='forest'][@scale6]{ fill-size: 30px; } [landuse='commercial'][@scale100] { z-index: 40; stroke: #5F9EA0; fill: #87CEFA, url( http://icons.markware.net/geoserver/icons/img/areas/commercial.png;); stroke-width: 0.5px; fill-opacity: 0.75; label: [name]; font-size: 10px; font-fill: #00; } [landuse='forest']{ z-index: 30; stroke: #CBEBB6; fill: #CBEBB6, url( http://icons.markware.net/geoserver/icons/img/areas/forest.png;); } Regards Mark -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Geoserver CSS Module
On Wed, Jun 25, 2014 at 4:40 AM, Mark Cupitt markcup...@gmail.com wrote: Good Day all. I am still having trouble with the Geoserver CSS Module with large CSS files. I have two smaller CSS files that process nicely and produce expected SLD, but when I combine them, they produce a humungus 84K line sld I am certain I am missing something, or have I have possibly hit a limitation of the CSS module. ANy help or suggestions are very much appreciated. The files are available at http://markware.net/css.zip osmph_polys.csss (4 seconds to process) (160 lines) osmph_polys.sld ( result = 2895 lines) osmph_polys_landuse.csss (5 seconds to process) (357 lines) osmph_polys_lamduse.sld ( result = 1209 lines) osmph_polys_combined.csss ( 9 minutes to process, 100% cpu, 100% java Container Memory) (500 lines) osmph_polys_combined.sld (result = 80,440 lines) Hi, is it possible to share some of these long css styles? I'm working on a java version of the css parser/translator (the current one is written in scala) and addressing directly the issue of large css styles by building an efficient filtered power set generator. I'm still not done with the translator, so I cannot give you something to try out, but it would be nice to have some complex css styles to work against as tests Cheers Andrea -- == GeoServer Professional Services from the experts! Visit http://goo.gl/NWWaa2 for more information. == Ing. Andrea Aime @geowolf Technical Lead GeoSolutions S.A.S. Via Poggio alle Viti 1187 55054 Massarosa (LU) Italy phone: +39 0584 962313 fax: +39 0584 1660272 mob: +39 339 8844549 http://www.geo-solutions.it http://twitter.com/geosolutions_it --- -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
[Geoserver-users] (no subject)
Lennert De Feyter GeoICT Project Manager GIM Geographic Information Management Researchpark Haasrode Interleuvenlaan 5 B-3001 HEVERLEE BELGIUM Tel. + 32 16 40 30 39 Fax + 32 16 40 69 39 http://www.gim.be -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Geoserver CSS Module
Hi Andrea, no problem, I will just fix the recode as Jody suggested, that is a great way to do things and keeps the code small so woudl be good for you to test. I can alos give you my first cut as well, that is a little more traditions. Will zip them up and send them a bit later on. Cheers Mark Cupitt Regards Mark Cupitt If we change the world, let it bear the mark of our intelligence See me on Open StreetMap https://www.openstreetmap.org/user/Mark_Cupitt See me on LinkedIn http://ph.linkedin.com/in/markcupitt *See me on StackExchange http://gis.stackexchange.com/users/17846/mark-c* === The contents of this email are intended only for the individual(s) to whom it is addressed and may contain confidential or privileged information. If you are not the intended recipient, you must not disclose, copy, distribute, or use the contents of this email. If you have received this email in error, please notify the sender immediately and delete the email and any attachments. === On Wed, Jun 25, 2014 at 7:56 PM, Andrea Aime andrea.a...@geo-solutions.it wrote: On Wed, Jun 25, 2014 at 4:40 AM, Mark Cupitt markcup...@gmail.com wrote: Good Day all. I am still having trouble with the Geoserver CSS Module with large CSS files. I have two smaller CSS files that process nicely and produce expected SLD, but when I combine them, they produce a humungus 84K line sld I am certain I am missing something, or have I have possibly hit a limitation of the CSS module. ANy help or suggestions are very much appreciated. The files are available at http://markware.net/css.zip osmph_polys.csss (4 seconds to process) (160 lines) osmph_polys.sld ( result = 2895 lines) osmph_polys_landuse.csss (5 seconds to process) (357 lines) osmph_polys_lamduse.sld ( result = 1209 lines) osmph_polys_combined.csss ( 9 minutes to process, 100% cpu, 100% java Container Memory) (500 lines) osmph_polys_combined.sld (result = 80,440 lines) Hi, is it possible to share some of these long css styles? I'm working on a java version of the css parser/translator (the current one is written in scala) and addressing directly the issue of large css styles by building an efficient filtered power set generator. I'm still not done with the translator, so I cannot give you something to try out, but it would be nice to have some complex css styles to work against as tests Cheers Andrea -- == GeoServer Professional Services from the experts! Visit http://goo.gl/NWWaa2 for more information. == Ing. Andrea Aime @geowolf Technical Lead GeoSolutions S.A.S. Via Poggio alle Viti 1187 55054 Massarosa (LU) Italy phone: +39 0584 962313 fax: +39 0584 1660272 mob: +39 339 8844549 http://www.geo-solutions.it http://twitter.com/geosolutions_it --- -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Geoserver CSS Module
On Wed, Jun 25, 2014 at 2:35 PM, Mark Cupitt markcup...@gmail.com wrote: Hi Andrea, no problem, I will just fix the recode as Jody suggested, that is a great way to do things and keeps the code small so woudl be good for you to test. I can alos give you my first cut as well, that is a little more traditions. Will zip them up and send them a bit later on. Yep, having both versions would be great Cheers Andrea -- == GeoServer Professional Services from the experts! Visit http://goo.gl/NWWaa2 for more information. == Ing. Andrea Aime @geowolf Technical Lead GeoSolutions S.A.S. Via Poggio alle Viti 1187 55054 Massarosa (LU) Italy phone: +39 0584 962313 fax: +39 0584 1660272 mob: +39 339 8844549 http://www.geo-solutions.it http://twitter.com/geosolutions_it --- -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Geoserver CSS Module
Hi Jody, that appears to have worked Ok (It generates two LineSymbolizers), thanks heaps for pointing that out. Cheers Mark Regards Mark Cupitt If we change the world, let it bear the mark of our intelligence See me on Open StreetMap https://www.openstreetmap.org/user/Mark_Cupitt See me on LinkedIn http://ph.linkedin.com/in/markcupitt *See me on StackExchange http://gis.stackexchange.com/users/17846/mark-c* === The contents of this email are intended only for the individual(s) to whom it is addressed and may contain confidential or privileged information. If you are not the intended recipient, you must not disclose, copy, distribute, or use the contents of this email. If you have received this email in error, please notify the sender immediately and delete the email and any attachments. === On Wed, Jun 25, 2014 at 7:42 PM, Jody Garnett jody.garn...@gmail.com wrote: I don't think you did that correctly - you were trying to provide two expressions right - for different z-indexs? So keep using two expressions: stroke: [recode(highway, 'motorway', '#00')], [recode(highway, 'motorway', '#4169E1')] Jody Garnett On Wed, Jun 25, 2014 at 8:33 PM, Mark Cupitt markcup...@gmail.com wrote: Hi Jody, FYI, I tried the recode function, it is excellent, however, it does not reproduce this stroke: #00, #4169E1; using .. stroke:[ recode(highway, 'motorway', '#00, #4169E1' )]; Which is sad .. that would be killer .. Cheers Mark Regards Mark Cupitt If we change the world, let it bear the mark of our intelligence See me on Open StreetMap https://www.openstreetmap.org/user/Mark_Cupitt See me on LinkedIn http://ph.linkedin.com/in/markcupitt *See me on StackExchange http://gis.stackexchange.com/users/17846/mark-c* === The contents of this email are intended only for the individual(s) to whom it is addressed and may contain confidential or privileged information. If you are not the intended recipient, you must not disclose, copy, distribute, or use the contents of this email. If you have received this email in error, please notify the sender immediately and delete the email and any attachments. === On Wed, Jun 25, 2014 at 5:59 PM, Jody Garnett jody.garn...@gmail.com wrote: I suppose I am just confused about the use of z-index there - I usually use a z-index 1 or 2 (and then only if needed based on funny overlapping - like simulating line casing, or ensuring that a polygon outline is drawn separately overtop of the fill). I recommend trying very simple examples like this and reviewing the SLD that is produced. Jody Garnett On Wed, Jun 25, 2014 at 2:42 PM, Mark Cupitt markcup...@gmail.com wrote: Hi Jody, in thinking through your remarks, in my last response would this be a better approach to the example I gave? [landuse='forest'][@scale6][@scale10]{ fill-size: 20px; } [landuse='forest'][@scale6]{ fill-size: 30px; } [landuse='commercial'][@scale100] { z-index: 40; stroke: #5F9EA0; fill: #87CEFA, url( http://icons.markware.net/geoserver/icons/img/areas/commercial.png;); stroke-width: 0.5px; fill-opacity: 0.75; label: [name]; font-size: 10px; font-fill: #00; } [landuse='forest']{ z-index: 30; stroke: #CBEBB6; fill: #CBEBB6, url( http://icons.markware.net/geoserver/icons/img/areas/forest.png;); } Regards Mark -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Possible Memory Leak causing server to not server pages
Hello, I haven't resolved this yet, but for the record, here is some information I have collected that could be of use. 2014-06-23 16:38 GMT-04:30 Jesús Gómez jgo...@gmail.com: Hello. Installed Geoserver 2.5.1 as a WAR on tomcat 7.0.28-4+deb7u1 (Debian wheezy). The server runs normally but i notice the following on catalina.out when i stop the server:: Jun 23, 2014 10:54:44 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads SEVERE: The web application [/geoserver] appears to have started a thread named [Thread-6] but has failed to stop it. This is very likely to create a memory leak. Jun 23, 2014 10:54:44 AM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/geoserver] created a ThreadLocal with key of type [java.lang.InheritableThreadLocal] (value [java.lang.InheritableThreadLocal@48f111fa]) and a value of type [org.geoserver.ows.Request] (value [WMS 1.1.1 GetMap]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak. What we are seeing is a mechanism of Tomcat that we could name MemoryLeakProtection[1]. The first thing I've learned is that it is normally and expected that this precise information about memory leak will be printed out on the logs _when_ the application _stops_: Hopefully tomcat 6.0.24 can detect the leak when the application is stopped as the documents explains. By reading in that documentation the examples of different kinds of ThreadLocal leaks, we can see the logs are really similar to the ones I've posted. You can see: Mar 16, 2010 11:47:24 PM org.apache.catalina.loader.WebappClassLoader clearThreadLocalMap SEVERE: A web application created a ThreadLocal with key of type [test.MyThreadLocal] (value [test.MyThreadLocal@4dbb9a58]) and a value of type [test.MyCounter] (value [test.MyCounter@57922f46]) but failed to remove it when the web application was stopped. To prevent a memory leak, the ThreadLocal has been forcibly removed. So this is a big hint about Geoserver causing memory leaks. This cause a real problem to me when i try to add the following to /etc/tomcat/web.xml :: filter filter-nameCorsFilter/filter-name filter-classorg.apache.catalina.filters.CorsFilter/filter-class /filter filter-mapping filter-nameCorsFilter/filter-name url-pattern/*/url-pattern /filter-mapping ... Jun 23, 2014 11:04:43 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads SEVERE: The web application [/geoserver] appears to have started a thread named [Thread-5] but has failed to stop it. This is very likely to create a memory leak. Jun 23, 2014 11:04:43 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads ... This time i don't have to wait for stoping the server to see the errors. Second, now I'm sure that the memory leak is causing Geoserver to stop. The fact I can cause an inevitable stop by enabling the CorsFilter doesn't change the fact that there is a memory leak problem in Geoserver. Of course, i think I can live with that time bomb if I disable the CorsFilter, because I could be monitoring the tomcat and use the Find Leaks button in low traffic periods and bypass the need of CorsFilter by using a Proxy. But: 1) It is a time bomb. I would not like to live with the Damocles sword on my head. 2) This could be a bug if I've understand right the situation. So, why is this happening?. So, by far I don't know why this is happening, but it would be of great help if you point me to where to look, give me some hints about how to hunt this bug or about the reasons behind this problem. Tank you! P.D: Since this is a potential BUG, I'm also sending a copy to the developers list. [1] http://wiki.apache.org/tomcat/MemoryLeakProtection -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Create Directory of Shape files Datastore with REST API JSON
I've been dealing with this situation for a couple of days now and here's what I found First, your original question includes an example that WORKS if you POST it to /rest/workspaces/topp/datastores.json with a header setting Content-type: application/json. It will create a datastore of the type Shapefile even if your url parameters point to a directory that holds a shapefile. (/I thought I should mention this because the web interface only lets you create a Shapefile datastore if you point 'url' to an specific shapefile and won let you pick just a directory/). Your example doesn't work if you POST it to /rest/workspaces/myWorkspace/datastores/name because that's not the REST endpoint for creating datastores. This is the minimum object you should POST if you specifically want to create a data store of the type Directory of spatial files (shapefiles) instead of Shapefile datastore. dataStore: { name: name, type: Directory of spatial files (shapefiles), connectionParameters: { url: file:data/shapefiles, fstype: shape } } What Andreas said is true. geowolf wrote Whenever something is not documented there is an easy way to discover the data structure you need: * go into the user interface, create the objects you need * go into the rest api, and grab their xml/json representation The problem with this being seamlessly useful is a REST API implementation detail that makes it represent some plain objects in a strange way when you ask the API for a JSON representation about any resource. I mean, when the REST API tells you something like connectionParameters:{ entry:[ {@key:memory mapped buffer,$:false}, {@key:fstype,$:shape} ] } it means that what you have to POST for a new datastore is: connectionParameters:{ memory mapped buffer:false, fstype:shape } I think this is due to Geoserver or the REST module using a specific library to convert to JSON objects that behaves in that way when serializing a JAVA object -- View this message in context: http://osgeo-org.1560.x6.nabble.com/Create-Directory-of-Shape-files-Datastore-with-REST-API-JSON-tp5144395p5147893.html Sent from the GeoServer - User mailing list archive at Nabble.com. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Create Directory of Shape files Datastore with REST API JSON
I've been dealing with this situation for a couple of days now and here's what I found First, your original question includes an example that WORKS if you POST it to /rest/workspaces/topp/datastores.json with a header setting Content-type: application/json. It will create a datastore of the type Shapefile even if your url parameters point to a directory that holds a shapefile. (/I thought I should mention this because the web interface only lets you create a Shapefile datastore if you point 'url' to an specific shapefile and won let you pick just a directory/). Your example doesn't work if you POST it to /rest/workspaces/myWorkspace/datastores/name because that's not the REST endpoint for creating datastores. This is the minimum object you should POST if you specifically want to create a data store of the type Directory of spatial files (shapefiles) instead of Shapefile datastore. dataStore: { name: name, type: Directory of spatial files (shapefiles), connectionParameters: { url: file:data/shapefiles, fstype: shape } } What Andreas said is true. geowolf wrote Whenever something is not documented there is an easy way to discover the data structure you need: * go into the user interface, create the objects you need * go into the rest api, and grab their xml/json representation The problem with this being seamlessly useful is a REST API implementation detail that makes it represent some plain objects in a strange way when you ask the API for a JSON representation about any resource. I mean, when the REST API tells you something like connectionParameters:{ entry:[ {@key:memory mapped buffer,$:false}, {@key:fstype,$:shape} ] } it means that what you have to POST for a new datastore is: connectionParameters:{ memory mapped buffer:false, fstype:shape } I think this is due to Geoserver or the REST module using a specific library to convert to JSON objects that behaves in that way when serializing a JAVA object -- View this message in context: http://osgeo-org.1560.x6.nabble.com/Create-Directory-of-Shape-files-Datastore-with-REST-API-JSON-tp5144395p5147634.html Sent from the GeoServer - User mailing list archive at Nabble.com. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Transfer geoserver data to another computer
Thank you for information. It solved my problem. Mehmet -- View this message in context: http://osgeo-org.1560.x6.nabble.com/Transfer-geoserver-data-to-another-computer-tp5146652p5146960.html Sent from the GeoServer - User mailing list archive at Nabble.com. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] GetFeatureInfo to Geoserver
My simple application gives me the following error QUERY_LAYERS contains layers not cited in LAYERS. It should be a proper subset of those instead. Yes, i do not want to query all layers so under the 'layers' parameter under 'get feature info' i skipped adding a layer. What should be the correct approach? How can i get rid of the error message? Thanks -- View this message in context: http://osgeo-org.1560.x6.nabble.com/GetFeatureInfo-to-Geoserver-tp3802214p5147541.html Sent from the GeoServer - User mailing list archive at Nabble.com. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] SLD filter function usage
Hi, Thanks for the reply. I wan't to place a symbol on the boundary of the ellipse at the top. In my question I had pointed two filter functions (numPoints and pointN) which I guess could be useful but I don't know how to use them. I could find any documentation on their usage. If someone has idea about how in SLD we use a filter function (numPoints) which returns a value(n) and then performing an arithmetic operation on that return value (3/4*n), please suggest. thanks -- View this message in context: http://osgeo-org.1560.x6.nabble.com/SLD-filter-function-usage-tp5146766p5147010.html Sent from the GeoServer - User mailing list archive at Nabble.com. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] GetFeatureInfo to Geoserver
Hi, There two parameters layers= and query_layers=. The layer (or list of layers) in query_layers must appear also in layers but not vice versa. You do not need to query all the layers, put the name of the one you are interested in into query_layers. -Jukka Rahkonen- raphsus wrote: My simple application gives me the following error QUERY_LAYERS contains layers not cited in LAYERS. It should be a proper subset of those instead. Yes, i do not want to query all layers so under the 'layers' parameter under 'get feature info' i skipped adding a layer. What should be the correct approach? How can i get rid of the error message? Thanks -- View this message in context: http://osgeo- org.1560.x6.nabble.com/GetFeatureInfo-to-Geoserver- tp3802214p5147541.html Sent from the GeoServer - User mailing list archive at Nabble.com. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] SLD filter function usage
Hi, Yes, the documentation is sparse in that area unfortunately. Something like the following may do it. I've not tested it. Note that it's SLD 1.1. You can remove the namespace stuff for SLD 1.0. se:Geometry ogc:Function name=pointN ogc:PropertyNameSDO_GEOMETRY/ogc:PropertyName !--round the result of 0.75 * numPoints as it may be a float-- ogc:Function name=round / !--Get point 3/4 the way around by multiplying. No div by 0 error chance -- ogc:Mul ogc:Literal0.75/ogc:Literal ogc:Function name=numPoints / /ogc:Mul /ogc:Function /ogc:Function /se:Geometry Should get you started at least. Cheers, Jonathan On 20 June 2014 13:49, shariq md.shariqk...@gmail.com wrote: Hi, Thanks for the reply. I wan't to place a symbol on the boundary of the ellipse at the top. In my question I had pointed two filter functions (numPoints and pointN) which I guess could be useful but I don't know how to use them. I could find any documentation on their usage. If someone has idea about how in SLD we use a filter function (numPoints) which returns a value(n) and then performing an arithmetic operation on that return value (3/4*n), please suggest. thanks -- View this message in context: http://osgeo-org.1560.x6.nabble.com/SLD-filter-function-usage-tp5146766p5147010.html Sent from the GeoServer - User mailing list archive at Nabble.com. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- This transmission is intended for the named addressee(s) only and may contain confidential, sensitive or personal information and should be handled accordingly. Unless you are the named addressee (or authorised to receive it for the addressee) you may not copy or use it, or disclose it to anyone else. If you have received this transmission in error please notify the sender immediately. All email traffic sent to or from us, including without limitation all GCSX traffic, may be subject to recording and/or monitoring in accordance with relevant legislation. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] Problem : Geoserver's layer displayed three times on maxExtent
Hi Sandra, Are you loading the data from a WMS or a WFS? This question may be better suited to the OpenLayers user list though - it may be an issue with your OL config (though I understand why you think it may be GeoServer given it works in MapServer). Cheers, Jonathan On 24 June 2014 22:14, Brochant Cassandra cassandra.broch...@gmail.com wrote: Hi, I don't know if it's the correct e-mail to ask for question. I'm trying to display a layer in WGS84 with the following bounding boxes -180,-90,180,90. But when i zoom out on maxextent in OpenLayers, my layer is displayed three times like if world is multiplied three times. If we take GeoServer 2.5.1's default layer topp:states, change bounding boxes (Native Bounding Box and Lat/Lon Bounding Box) in Data tab to -180.-90.180.90, and preview it on OpenLayers. Zoom out to maxextent, you'll see that USA states appears three times. I've taken source code of the html page, tried to set displayOutsideMaxExtent attribute of the WMS layer to false. Nothing better. I also verified map's maxextent corresponds to -180,-90,180,90. The option may be to block pan to the extent, but i don't want to use it. However, it seems to work fine with a layer from a MapServer server. I search for daysand days, don't know how to solve this... Thank you in advance for any help. Sandra -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- This transmission is intended for the named addressee(s) only and may contain confidential, sensitive or personal information and should be handled accordingly. Unless you are the named addressee (or authorised to receive it for the addressee) you may not copy or use it, or disclose it to anyone else. If you have received this transmission in error please notify the sender immediately. All email traffic sent to or from us, including without limitation all GCSX traffic, may be subject to recording and/or monitoring in accordance with relevant legislation. -- Open source business process management suite built on Java and Eclipse Turn processes into business applications with Bonita BPM Community Edition Quickly connect people, data, and systems into organized workflows Winner of BOSSIE, CODIE, OW2 and Gartner awards http://p.sf.net/sfu/Bonitasoft___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users