New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WFS 2.0 wrong extension response to a spatialite zip request #4933

Closed
aperi2007 opened this Issue Jun 2, 2014 · 3 comments

Comments

Projects
None yet
4 participants
@aperi2007

aperi2007 commented Jun 2, 2014

Mapserver use wrong extension in a response to a spatialite zipped request.

Starting from this setting:

OUTPUTFORMAT
NAME "SPATIALITE"
DRIVER "OGR/SQLITE"
MIMETYPE "application/zip"
FORMATOPTION "DSCO:SPATIALITE=YES"
FORMATOPTION "STORAGE=memory"
FORMATOPTION "FORM=zip"
FORMATOPTION "FILENAME=result.db.zip"
END

The zip resulted will not contain a file .sqlite but instead a file with zip extension.
But this is not a zip file.It is instead a real spatialite db. The MapServer has named its extension .zip instead of .sqlite

@tbonfort

This comment has been minimized.

Show comment
Hide comment
@tbonfort

tbonfort Jun 3, 2014

Member

the FILENAME key is used to create the OGR datasource, so it should probably be set to result.db instead of result.db.zip. However when using zipped form, we should probably append ".zip" to the filename of the Content-Disposition header. cc @rouault

Member

tbonfort commented Jun 3, 2014

the FILENAME key is used to create the OGR datasource, so it should probably be set to result.db instead of result.db.zip. However when using zipped form, we should probably append ".zip" to the filename of the Content-Disposition header. cc @rouault

@rouault

This comment has been minimized.

Show comment
Hide comment
@rouault

rouault Jun 3, 2014

Contributor

@tbonfort I will take after this bug. My intent is, when FORM=zip, to analyse the filename. If it is of the kind foo.bar.zip, then the OGR datasource will be created with foo.bar as a name, and the result will be zipped in foo.bar.zip. If FILENAME is not specified or just as foo.zip then the OGR datasource will be named result.dat.

Contributor

rouault commented Jun 3, 2014

@tbonfort I will take after this bug. My intent is, when FORM=zip, to analyse the filename. If it is of the kind foo.bar.zip, then the OGR datasource will be created with foo.bar as a name, and the result will be zipped in foo.bar.zip. If FILENAME is not specified or just as foo.zip then the OGR datasource will be named result.dat.

@rouault rouault self-assigned this Jun 3, 2014

rouault added a commit to mapserver/msautotest_DEPRECATED that referenced this issue Jun 11, 2014

rouault added a commit that referenced this issue Jun 11, 2014

OGR output (zip form): when we have FORMATOPTION "FILENAME=basename.e…
…xt.zip", use basename.ext as the name of the OGR datasource (#4933)

rouault added a commit to mapserver/msautotest_DEPRECATED that referenced this issue Jun 11, 2014

@jratike80

This comment has been minimized.

Show comment
Hide comment
@jratike80

jratike80 Nov 2, 2015

I believe that this one can be closed like the referenced #4856.

jratike80 commented Nov 2, 2015

I believe that this one can be closed like the referenced #4856.

@jratike80 jratike80 closed this Nov 2, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment