gost / server

GOST - Go implementation of OGC SensorThings API
MIT License
61 stars 19 forks source link

support 3D geometry #144

Closed bertt closed 5 years ago

bertt commented 6 years ago

Got an server error (500) on creating 3D geometry:

request:

http post https://localhost:8080/v1.0/Locations

{ "name": "First place", "description": "First place", "encodingType": "application/vnd.geo+json", "location": { "type": "Point", "coordinates": [-117.123, 54.123,10] } }

response:

{ "error": { "status": "Internal Server Error", "code": 500, "message": [ "pq: Geometry has Z dimension but column does not" ] } }

Expected behaviour: GOST server should accept 3D geometries

bertt commented 6 years ago

Same error when posting FeatureOfInterest with 3D geometry

bertt commented 6 years ago

changing the database geometry type columns to geography results in 7/23 failing tests in ets-sta-10

bertt commented 6 years ago

looks like supporting 3D vertices will have huge impact. proposed workaround: use Location.Name or Location.Description to add altitude. Or use Thing.properties for not moving Things.

bertt commented 6 years ago

I think the best way to move this forward is to switch the geometry type from geometry to geography and fix the ETS-STA-10 tests.

bertt commented 6 years ago

workaround: use geojson attributes

bertt commented 5 years ago

closing, will not add real 3d support now