WFSDataStoreFactory.createGetCapbilitiesRequest(url) garbles mapserver MAP path 
encoding
----------------------------------------------------------------------------------------

                 Key: GEOT-3442
                 URL: http://jira.codehaus.org/browse/GEOT-3442
             Project: GeoTools
          Issue Type: Bug
          Components: data wfs
    Affects Versions: 2.7-RC2
            Reporter: Jody Garnett


>From email, thanks Joaquín Rodríguez-Guerra Urcelay:

I took a look at the wfs catalog to see how the URL is read and it seems like 
before starting the parsing, a hack is done to make sure the URL uses wfs 
version 1.0.0, and it is there where URL is modified from:

* 
http://localhost:8080/cgi-bin/mapserv?SERVICE=WFS&VERSION=1.0.0&REQUEST=GetCapabilities&MAP=/opt/fgs/www/htdocs/mariss/data/states.map

to:

* 
http://localhost:8080/cgi-bin/mapserv?VERSION=1.0.0&SERVICE=WFS&REQUEST=GetCapabilities&MAP=%2Fopt%2Ffgs%2Fwww%2Fhtdocs%2Fmariss%2Fdata%2Fstates.map

Geotools is able to parse the first URL but not the second one, and commenting 
line 185 fixes the problem about having "/" in the URL, but of course probably 
that line is there for some other reasons...

WFSServiceImpl:183
{code}
// HACK: explicitly ask for WFS 1.0
URL url = (URL) params.get(WFSDataStoreFactory.URL.key);
url = WFSDataStoreFactory.createGetCapabilitiesRequest(url); // this line makes 
the URL wrong if it contains "/" in the params
params = new HashMap<String, Serializable>(params);
params.put(WFSDataStoreFactory.URL.key, url);
ds = (WFSDataStore) dsf.createDataStore(params);
url = WFSDataStoreFactory.createGetCapabilitiesRequest(url);
{code}


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to