This PR contains all the new code for the provider. The readme describes the usage and configuration requirements. Some general things to bring to your attention for feedback:
I'm using the :host parameter to point to a key in the configuration object. The value of that key holds a serialization object which the provider passes on to S3 so it knows how to convert the file to stringifed JSON. The goal here was to allow a single S3 provider to access files that may have been serialized in various ways.
The :id parameter holds the path to the S3 file (not including the bucket). Any forward slashes need to be replaced with ::(should we include the bucket here instead of setting it in configuration?).
I use schema-matching to determine how to translate the S3 JSON to GeoJSON. Specifically, I check to see if the JSON returned is already a feature collection, a feature array (i.e., has properties and geometry), an array of geometries, or just a simple object array. Then I translate to a GeoJSON feature collection appropriately.
This PR contains all the new code for the provider. The readme describes the usage and configuration requirements. Some general things to bring to your attention for feedback:
:host
parameter to point to a key in the configuration object. The value of that key holds aserialization
object which the provider passes on to S3 so it knows how to convert the file to stringifed JSON. The goal here was to allow a single S3 provider to access files that may have been serialized in various ways.:id
parameter holds the path to the S3 file (not including the bucket). Any forward slashes need to be replaced with::
(should we include the bucket here instead of setting it in configuration?).properties
andgeometry
), an array of geometries, or just a simple object array. Then I translate to a GeoJSON feature collection appropriately.