Hello James -
I tried the 'Construct Geometry from Fields' option as shown below... ...but when I did, the input connector was no longer streaming any data through. |
I think the reason that the input stopped showing data records being received (when you toggled its 'Construct Geometry from Fields' to 'Yes') is that the GeoEvent structure already has a field named 'Geometry' which is preventing the input's adapter from creating a field it wants to name 'Geometry' into which it can place the value it has created.
Assuming that you have no influence over the data provider's choice of naming the group element, here's something you can do to work around the issue.
- Bring the event data in, as provided, without attempting to build a Geometry
- Use a 'Field Mapper' processor to remap the event structure:
- Geometry.X => Longitude
- Geometry.Y => Latitude
- Geometry.spatialReference.wkid => WKID
- Send the remapped event to a 'Push JSON to an External Website' output
- Configure the rest-json-in-repost input you create to construct a Geometry from the Latitude, Longitude, and WKID field values
When configuring the 'Push JSON to an External Website' output, I elected to clear the parameter field 'Header Parameter Name:Value List' (since I wasn't actually providing a list of name:value pairs...)
What I ended up doing was placing both the rest-json-in and rest-json-in-repost inputs in the same GeoEvent Service. This might lead to some confusion with your event counts on the Monitor page as every event received increments the GeoEvent Service's event count by 2 (since it has two inputs and is essentially sending a copy of the event record to itself).
My solution uses three GeoEvent Definitions ... an original matching the data provider's structure, a remap of that structure, and a copy of the remapped structure with a Geometry field added (used by the rest-json-in-repost input constructing the Geometry, so it has somewhere to place the Geometry it constructs).
Please let me know how this works for you -
RJ