Hello,

I'm currently facing an issue with attempting to PUT a spatialite DB file to geoserver data dir using the REST API (Geoserver 2.10.0)

I've a file of about 9.9Mb, when i try to upload it, i got the file uploaded but its size is ~ 0.7Mb (and for sure nothing can be published through Geoserver). Response of http call is 202 instead of 201 (what i receive if i try, succesfully, to publish a zip shapefile). The geoserver in question is running on https.

curl -v -u admin:geoserver -XPUT -H "Content-type: application/x-sqlite3" --data-binary @test.spatialite "https://<myhost>/geoserver/rest/workspaces/aaps/datastores/test/file.spatialite <https://%3Cmyhost%3E/geoserver/rest/workspaces/aaps/datastores/test/file.spatialite>"

The result is the same when trying with a zip file.

curl -v -u admin:geoserver -XPUT -H "Content-type: application/zip" --data-binary @test.zip "https://<myhost>/geoserver/rest/workspaces/aaps/datastores/test/file.spatialite <https://%3Cmyhost%3E/geoserver/rest/workspaces/aaps/datastores/test/file.spatialite>"

Output:

* successfully set certificate verify locations:
*   CAfile: C:\Program Files\cURL\bin\curl-ca-bundle.crt
  CApath: none
* TLSv1.2, TLS handshake, Client hello (1):
* TLSv1.2, TLS handshake, Server hello (2):
* TLSv1.2, TLS handshake, CERT (11):
* TLSv1.2, TLS handshake, Server key exchange (12):
* TLSv1.2, TLS handshake, Server finished (14):
* TLSv1.2, TLS handshake, Client key exchange (16):
* TLSv1.2, TLS change cipher, Client hello (1):
* TLSv1.2, TLS handshake, Finished (20):
* TLSv1.2, TLS change cipher, Client hello (1):
* TLSv1.2, TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-ECDSA-AES128-GCM-SHA256
* Server certificate:
*        subject: CN=<myhost>
*        start date: 2016-11-23 16:31:00 GMT
*        expire date: 2017-02-21 16:31:00 GMT
*        subjectAltName: <myhost> matched
*        issuer: C=US; O=Let's Encrypt; CN=Let's Encrypt Authority X3
*        SSL certificate verify ok.
* Server auth using Basic with user 'admin'
> PUT /geoserver/rest/workspaces/aaps/datastores/test2/file.spatialite HTTP/1.1
> Authorization: Basic YWRtaW46Z2Vvc2VydmVy
> User-Agent: curl/7.40.0
> Host: <myhost>
> Accept: */*
> Content-type: application/x-sqlite3
> Content-Length: 10195968
> Expect: 100-continue
>
< HTTP/1.1 100 Continue
< HTTP/1.1 202 Accepted
< Server: nginx
< Date: Wed, 30 Nov 2016 11:46:54 GMT
< Transfer-Encoding: chunked
< Connection: keep-alive
<

Do you have any idea what would be the cause of this truncation of spatialite file?

I've seen some similar thread at https://sourceforge.net/p/geoserver/mailman/message/31104434/ mentioning similar issue with H2https://osgeo-org.atlassian.net/browse/GEOS-5869 <https://osgeo-org.atlassian.net/browse/GEOS-5869> If it appears to be the same bug, could you provide some hints about the problem, and if/where a patch should be done.

Thanks in advance for your assistance

Best,
Emmanuel
------------------------------------------------------------------------------
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to