[mapserver-users] Mapserver6 calls exit() in FastCGI-mode
Hello list, when Mapserver 5 got a WMS request like this: mapserv?request=getcapabilitiesmap=mymap.map it responded with an wms_exception saying that the SERVICE parameter was missing. Mapserver 6 can not decide if the request if for a wms service or another ows service and responds with: mapserv(): Web application error. Traditional BROWSE mode requires a TEMPLATE in the WEB section, but none was provided. The problem is that the error from Mapserver 6, apart from its user unfriendlyness for ows-requests, is reported by writeError() in mapserv.c which calls exit() even if we are running under FastCGI. As this error is non fatal I consider this a bug. Less important: I also think mapserver could be a bit more helpful. An error message like: Traditional BROWSE mode requires a TEMPLATE in the WEB section, but none was provided. For OWS-requests the SERVICE-parameter is needed. Or maybe msOWSDispatch could check for all known requests (getmap, getcapabilities, etc) and return an exception instead of returning MS_DONE to mapserv.c -- Erik Gustafson ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] SLD support: Anyone for fixing 5 yr old tickets?
Hi there, I have updated both issues in trac. It would be good if you could add yourself in cc in the bugs and comment on them. I agree that #1166 is still relevant and could be fixed for 6.2. I am not sure if #1602 is something that needs to be done and fits the way the specs describe sld and wms. best regards, On 15/04/2011 9:39 AM, Hollingbery, Julian wrote: Hi list, I have just joined the list for the following reason: We have been running SLD-enabled WMS services for some years now, on a closed source platform. For that, and several other reasons, we are now looking at using MapServer as a replacement. I have compared our existing platform and MapServer 5.6.6, and have noticed a couple of incompatibilities. After having looked around, I find that both of these issues exist as old tickets: _http://trac.osgeo.org/mapserver/ticket/1602_ _http://trac.osgeo.org/mapserver/ticket/1166_ We do not have the developer resources to provide patches, so I am looking for someone to do it for us. Our migration is organized as a project, for which we have some funds. Therefore, I am looking for someone who would be willing to provide me with an estimate of what it would cost (time and/or money) to come up with a patch. Regarding #1602, what I would like to achieve is to highlight an object given by a ogc:Filter, while rendering the remaining objects in that layer in the default style. I could of course use an ElseFilter, but since this is a question of providing backward compatibility, I'd prefer not to. It is not exactly the same thing as in #1602, but it seems to me that it might be the same fix. My particular SLD looks something like this: StyledLayerDescriptor version=1.0.0 xmlns=http://www.opengis.net/sld; xmlns:ogc=http://www.opengis.net/ogc; NamedLayer NameJordstykke/Name UserStyle FeatureTypeStyle Rule ogc:Filter And ogc:PropertyIsEqualTo ogc:PropertyNamelandsejerlavskode/ogc:PropertyName ogc:Literal90552/ogc:Literal /ogc:PropertyIsEqualTo ogc:PropertyIsEqualTo ogc:PropertyNamematrikelnummer/ogc:PropertyName ogc:Literal7fv/ogc:Literal /ogc:PropertyIsEqualTo /And /ogc:Filter PolygonSymbolizer Fill CssParameter name=fill#FF/CssParameter CssParameter name=fill-opacity1/CssParameter /Fill Stroke CssParameter name=stroke#FF/CssParameter CssParameter name=stroke-width3/CssParameter /Stroke /PolygonSymbolizer /Rule /FeatureTypeStyle /UserStyle /NamedLayer NamedLayer NameJordstykke/Name NamedStyle Namedefault/Name /NamedStyle /NamedLayer /StyledLayerDescriptor Thanks in advance, Julian Hollingbery Danish Ministry of The Environment, National Survey and Cadastre ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users -- Assefa Yewondwossen Software Analyst Email: yass...@dmsolutions.ca http://www.dmsolutions.ca/ Phone: (613) 565-5056 (ext 14) Fax: (613) 565-0925 ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] MapServer 6.0.0-beta6 Incorrect error response to missing parameter
When I omit the request=GetCapabilities parameter on the below request http://ogcdev.bgs.ac.uk/cgi-bin/BGS_Bedrock_and_Superficial_Geology/wms?service=wms; The exception reported is: ?xml version='1.0' encoding=ISO-8859-1 standalone=no ? ServiceExceptionReport version=1.3.0 xmlns=http://www.opengis.net/ogc; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://www.opengis.net/ogc http://schemas.opengis.net/wms/1.3.0/exceptions_1_3_0.xsd; ServiceException msWMSDispatch(): WMS server error. Incomplete WMS request: VERSION parameter missing msOutputFormatValidate(): General error message. OUTPUTFORMAT png has IMAGEMODE RGB/RGBA, which is not supported for GD drivers. /ServiceException /ServiceExceptionReport I believe this is incorrect. When the service parameter is specified the request can only be GetCapabilities. For a GetCapabilities request the version parameter is optional. The error should therefore report: msWMSDispatch(): WMS server error. Incomplete WMS request: REQUEST parameter missing. James James Passmore GIS and WWW Specialist Information Systems and Infrastructure, British Geological Survey, http://www.bgs.ac.uk/ +44 (0)115 936 3125 -- This message (and any attachments) is for the recipient only. NERC is subject to the Freedom of Information Act 2000 and the contents of this email and any reply you make may be disclosed by NERC unless it is exempt from release under the Act. Any material supplied to NERC may be stored in an electronic records management system.___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Problems with png output when using libpng 1.5
Christy, I suspect this is due to a bug in libpng. see http://sourceforge.net/tracker/index.php?func=detailaid=3288207group_id=5624atid=105624 . On Wed, Apr 20, 2011 at 15:20, Christy Nieman cnie...@dmsolutions.ca wrote: Hi, I compiled MapServer 6.0 beta6 against libpng 1.5.2 and encountered the following problems: when using the default png IMAGETYPE (i.e. no OUTPUTFORMAT block), I got yellow striped maps (see cyprus.png) when using the AGG/PNG driver and IMAGEMODE RGBA, the output image looks fine when using the default png8 IMAGETYPE, the output image looks fine I also compiled with cairo, and with the driver set to CAIRO/PNG, I had the same yellow striped maps. rgba and png8 use different png formats. agg/png and cairo/png use the same codepath when saving images, so the behavior your are observing is normal. With libpng 1.2.44, everything seems to work properly. Has anyone else seen this problem with libpng 1.5? Should it work properly with MapServer? Regards, Christy ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] relative path for .map file inside a WMS url
Hi, I have a CGI MapServer 5.6.0beta5 instance running on Windows. But I'm not (and won't never be) able to know for sure the folder's path where its files are deployed. I know that MapServer is running fine though, delivering maps as needed. But I'm not able to make some WMS web request because I can't provide an absolute path for the map= parameter : I don't know in which folder my .map files reside. http://myserver/cgi-bin/mapserv.exe?map=?*?/mymapfile.map;... Is there a way to use relative path ? or to use a kind of environment variable MS_INSTALL_PATH inside the map= parameter? I can only act on the server's configuration and MS deployment Thanks for your help Clément ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] relative path for .map file inside a WMS url
I don't think it is possible o have this yet. You could file an enhancement request, as this would be a nice feature to have. regards, thomas On Wed, Apr 20, 2011 at 16:43, Clément MONIER clement.mon...@v-trafic.com wrote: Hi, I have a CGI MapServer 5.6.0beta5 instance running on Windows. But I’m not (and won’t never be) able to know for sure the folder’s path where its files are deployed. I know that MapServer is running fine though, delivering maps as needed. But I’m not able to make some WMS web request because I can’t provide an absolute path for the “map=” parameter : I don’t know in which folder my .map files reside. http://myserver/cgi-bin/mapserv.exe?map=?*?/mymapfile.map;... Is there a way to use relative path ? or to use a kind of environment variable MS_INSTALL_PATH inside the “map=” parameter? I can only act on the server’s configuration and MS deployment Thanks for your help Clément ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Mapserver6 calls exit() in FastCGI-mode
On 11-04-20 03:59 AM, Erik Gustafson wrote: The problem is that the error from Mapserver 6, apart from its user unfriendlyness for ows-requests, is reported by writeError() in mapserv.c which calls exit() even if we are running under FastCGI. As this error is non fatal I consider this a bug. Erik, For reference, I do *not* consider this a bug. In my opinion it is perfectly acceptable for MapServer processes to terminated sometimes on an error even when running in FastCGI mode. Reasonable FastCGI implementations will just start a new process for the next request so the only harm is a slight delay as libraries are reinitialized and DB connections are re-established. The error you are encountering is not something that will happen often in practice. In fact, I believe it is a good practice to have MapServer FastCGI instances recycled occasionally as it is hard to ensure there are no memory leaks in the more esoteric parts of the code. Best regards, -- ---+-- I set the clouds in motion - turn up | Frank Warmerdam, warmer...@pobox.com light and sound - activate the windows | http://pobox.com/~warmerdam and watch the world go round - Rush| Geospatial Programmer for Rent ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] Query on WFS Layer: Fatal error: [MapServer Error]: msQueryByShape(): No matching record(s) found
Hi list, I have a big problem on querying a WFS layer. Here you find both script and layer definition on mapfile. The problem is that $result-shapeindex has value 0 and I get the error: Fatal error: [MapServer Error]: msQueryByShape(): No matching record(s) found. Any suggestions? Best regards Francesco - SCRIPT - $qresult = @$layer-queryByRect($myrect); //get all results $numResults = $layer-getNumResults(); for ($i=0; $i $numResults; $i++) { $result = $layer-getResult($i); $layer-open(); $shape = $layer-getFeature($result-shapeindex); $layer-close(); } - MAPFILE LAYER DEFINITION - LAYER NAME parchiGR GROUP Grigioni TYPE POLYGON STATUS DEFAULT CONNECTIONTYPE WFS CONNECTION http://mapserver1.gr.ch/wfs/wildruhezonen?; CLASSITEM beschlussjahr METADATA wfs_typename Eidg_Jagdbanngebiete_und_Schweizerischer_Nationalpark wfs_version 1.0.0 wfs_request_methodGET wfs_connectiontimeout 100 wfs_maxfeatures 1000 END DUMP TRUE PROJECTION init=epsg:21781 END CLASS NAME anno 2004 EXPRESSION 2004 COLOR 159 255 159 OUTLINECOLOR 250 20 10 TEMPLATE templates/default.html END CLASS NAME anno 1980 EXPRESSION 1980 COLOR 140 198 255 OUTLINECOLOR 250 20 10 TEMPLATE templates/default.html END CLASS NAME altro anno COLOR 192 192 192 OUTLINECOLOR 250 20 10 TEMPLATE templates/default.html END END ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] relative path for .map file inside a WMS url
Actually, you can also do this with an apache rewrite rule, I've just tested it and it seems to work quite well ! RewriteEngine On RewriteRule ^/wms/(.*) /cgi-bin/mapserv?map=/datadir/$1.map [PT,QSA] it will translate requests that are like /wms/carto to /cgi-bin/mapserv?map=/datadir/carto.map , along with the query string. regards, thomas On Wed, Apr 20, 2011 at 16:43, Clément MONIER clement.mon...@v-trafic.com wrote: Hi, I have a CGI MapServer 5.6.0beta5 instance running on Windows. But I’m not (and won’t never be) able to know for sure the folder’s path where its files are deployed. I know that MapServer is running fine though, delivering maps as needed. But I’m not able to make some WMS web request because I can’t provide an absolute path for the “map=” parameter : I don’t know in which folder my .map files reside. http://myserver/cgi-bin/mapserv.exe?map=?*?/mymapfile.map;... Is there a way to use relative path ? or to use a kind of environment variable MS_INSTALL_PATH inside the “map=” parameter? I can only act on the server’s configuration and MS deployment Thanks for your help Clément ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/mapserver-users