Skip To Content

GeoEvent Sampler

What is GeoEvent Sampler?

Real-time data can be received in any number of data formats (text, JSON, GeoJSON, and more) over many types of protocols (HTTP, WebSocket, TCP, and more). Being able to validate and explore event data (or GeoEvents) directly in GeoEvent Manager, prior to say writing those GeoEvents to a feature layer for viewing in a web map, can be especially useful. GeoEvent Sampler is a utility in the service designer of GeoEvent Manager that samples a fixed number of GeoEvents as they are routed through elements (inputs, outputs, filters, and processors) of a published GeoEvent Service. The sampled GeoEvents can be viewed as prettified JSON or delimited text in the sampler window. Sampling GeoEvents can provide greater insight, earlier, into your real-time event data and can assist in designing, validating, and troubleshooting different routes in a GeoEvent Service.

Unlike GeoEvent Logger and GeoEvent Simulator, which are separate Windows applications installed with GeoEvent Server, GeoEvent Sampler is a utility in the service designer in GeoEvent Manager. Access GeoEvent Sampler from any new or existing GeoEvent Service by toggling the utility at the bottom of the service designer. Below is a description of the key functionality provided by GeoEvent Sampler.

GeoEvent Sampler utility in the service designer

Property or FunctionDescription

1 - Enable / Disable

Enable and Disable starts and stops GeoEvent Sampler on a selected route between two elements of a published GeoEvent Service. GeoEvent Sampler is disabled by default and must be enabled to sample GeoEvents on a selected route.

  • Enable - GeoEvent Sampler will be enabled. GeoEvents streaming through a GeoEvent Service will display in the sampler window upon selecting a route between elements in a published GeoEvent Service.
  • Disable - GeoEvent Sampler will be disabled. GeoEvents streaming through a published GeoEvent Service will not be displayed in the sampler window. Any existing event records will remain in the window until they are manually cleared, or the GeoEvent Services page is refreshed. If sampling is disabled, clicking a route in a GeoEvent Service will not display any event data.

For details on enabling GeoEvent Sampler, see Enable GeoEvent Sampler below.

2 - Select Route

The name of the selected route in a GeoEvent Service. Event data will be displayed in the sampler window for the selected route only. Any route between an input, output, filter, or processor element can be selected in a published GeoEvent Service.

The name of the selected route is displayed as the concatenation of the connected element names. Several examples of route names include:

  • Input Connector TO Output Connector
  • Field Mapper TO Bearing Calculator
  • Filter “Speed > 80” TO Change_Status_Speeding_Field_Calculator
  • Hurricane_Warning TO Email_FieldCrewA
Remarque :

The name of the selected route is displayed when GeoEvent Sampler is enabled and a route between two elements in a GeoEvent Service is selected.

3 - GeoEvent Sampler Utility

Click the toggle to show or hide GeoEvent Sampler in the service designer.

For details on enabling GeoEvent Sampler, see Enable GeoEvent Sampler below.

4 - Refresh

Use Refresh to clear the currently sampled GeoEvents and sample another set from the selected route.

After a refresh, another set of GeoEvents will be sampled up to the value specified in the Sample Size setting. For example, if the Sample Size is set to 10 and a refresh occurs, the current GeoEvents will be cleared and another sample of 10 will appear in the sampler window.

If two routes are being compared, Refresh will clear the GeoEvents for each route and each route will be sampled again. For details on comparing two routes, see Compare GeoEvents from two routes below.

5 - Clear

Use Clear to remove sampled GeoEvents from the sampler window.

After a clear, GeoEvents will continue to be sampled from the selected route up to the value specified in the Sample Size setting. For example, if the Sample Size is set to 10 and a clear occurred after 3 GeoEvents were sampled, the sampler will clear out the 3 GeoEvents and continue to sample for the remaining 7 GeoEvents.

If two routes are being compared, Clear is available for each route. For details on comparing two routes, see Compare GeoEvents from two routes below.

Remarque :

The ability to clear the sampler window(s) is only available after at least one GeoEvent is sampled.

6 - View in Event Viewer

Use View in Event Viewer to visualize the geometry of the sampled GeoEvents in a web map viewer.

The Event Viewer only displays the geometry of sampled GeoEvents currently displayed in the sampler window. When the Event Viewer is open, any newly sampled GeoEvents will not be displayed. Open the Event Viewer after the desired number of GeoEvents are sampled and available in the sampler window.

Remarque :

Viewing sampled GeoEvents in the Event Viewer is only possible if the GeoEvents have a geometry whose field is tagged GEOMETRY in its GeoEvent Definition. Additionally, sampled GeoEvents must be in the JSON data type format, viewing as text is not supported.

7 - Copy to Clipboard

Use Copy to Clipboard to copy the GeoEvents currently displayed in the sampler window to the system clipboard. The copied GeoEvents can then be pasted to a separate text file or text editor for storage or further review.

If two routes are being compared, Copy to Clipboard is available for each route. For details on comparing two routes, see Compare GeoEvents from two routes below.

Remarque :

GeoEvents are copied in the data type format defined in the Data Type setting (either Text or JSON). The data type format can be changed in Settings.

8 - Settings

Access the settings available for sampling GeoEvents, including Data Type and Sample Size.

  • Data Type - Specifies how sampled GeoEvents are formatted, either as prettified JSON or delimited Text. The default is JSON.
  • Sample Size - Specifies the number of GeoEvents to sample from a selected route. The sample size can be set to 1, 10, or 100 GeoEvents. The default is 10.

9 - Sampler Window

The GeoEvents sampled from a selected route will appear in the sampler window.

Sampled GeoEvents will display as either JSON or text depending on the data type format specified in the Data Type setting.

10 - Event Counter

The event counter displays the number of GeoEvents sampled on a selected route. The number of GeoEvents sampled will never exceed the value specified in the Sample Size setting. For example, a count of 3/10 means 3 GeoEvents, out of a maximum of 10, have been sampled.

Remarque :

The event counter will reset to 0 if a new route is selected or if sampling is refreshed.

Enable GeoEvent Sampler

GeoEvents can be sampled and displayed, in real-time, from a route (or connection) between an input, output, filter, or processor element in a published GeoEvent Service. To get started with GeoEvent Sampler, open GeoEvent Manager and either create a new GeoEvent Service or open an existing GeoEvent Service. For details on creating a new GeoEvent Service, see Creating a GeoEvent Service.

Refer to the steps below to access and enable GeoEvent Sampler in the service designer.

  1. Open a published GeoEvent Service and ensure it is receiving GeoEvents.
  2. Click GeoEvent Sampler toggle on the bottom of the service designer to open GeoEvent Sampler.
  3. Click GeoEvent Sampler settings to open the Settings for GeoEvent Sampler and specify the desired Data Type and Sample Size. The default data type is JSON and default sample size is 10 GeoEvents.
  4. Click Enable GeoEvent Sampler to start GeoEvent Sampler.
Remarque :

GeoEvent Sampler can also be started by right-clicking a route between two elements in a published GeoEvent Service and choosing Sample Route. GeoEvent Sampler will open and sampling of GeoEvents will begin on the selected route.

Start sampling GeoEvents

To start sampling GeoEvents, select a route between an input, output, filter, or processor element while GeoEvent Sampler is open and enabled.

To sample GeoEvents from a route in a GeoEvent Service, create a new or open an existing published GeoEvent Service, ensure it is actively receiving GeoEvents, and follow the steps below.

  1. Ensure GeoEvent Sampler is open in the service designer and is enabled.
  2. Left-click a route in the published GeoEvent Service to begin sampling GeoEvents on that route. Example selected route in a GeoEvent Service
  3. Remarque :

    GeoEvent Sampler can also be started by right-clicking a route and selecting Sample Route from the menu. GeoEvent Sampler will open, enable, and instantly begin sampling GeoEvents from the selected route if GeoEvent Sampler is not already opened and enabled.

    As real-time data flows through a GeoEvent Service, the sampler window will display a sample of the GeoEvents from the selected route as they are processed. The sampled GeoEvents will be displayed as Text or JSON depending on the data format type specified in the Data Type setting. The total number of sampled GeoEvents displayed depends on the Sample Size setting. The number of GeoEvents sampled can be seen in the events sampled counter.
  4. (Optional) The current sample of GeoEvents can be copied from the sampler window by clicking Copy to Clipboard Copy to Clipboard.
  5. (Optional) The current sample of GeoEvents can be cleared from the sampler window by clicking Clear Clear.
  6. (Optional) The selected route can be sampled again by clicking Refresh Refresh.

Visualize sampled GeoEvents

The primary purpose of GeoEvent Sampler is to provide a sample of GeoEvents as text or JSON, in real-time, as they are processed in a published GeoEvent Service. GeoEvent Sampler also includes an Event Viewer which is a web map viewer that can be used to visualize and verify the geometry of processed GeoEvents.

To visualize sampled GeoEvents in the Event Viewer, create a new or open an existing published GeoEvent Service, ensure it is actively receiving GeoEvents, and follow the steps below.

  1. Ensure GeoEvent Sampler is open in the service designer and enabled.
  2. Click GeoEvent Sampler settings and confirm the Data Type is set to JSON.
  3. Left-click a route in the published GeoEvent Service to begin sampling GeoEvents on the selected route.
  4. Remarque :

    Optionally, right-click a route and from the menu and choose Sample Route to begin sampling GeoEvents.

  5. After a sample of GeoEvents is displayed as JSON in the sampler window, click View in Event Viewer to view the GeoEvents in the Event Viewer.
  6. Remarque :

    The Event Viewer only supports sampling JSON formatted GeoEvents that contain a geometry field tagged as GEOMETRY in the corresponding GeoEvent Definition. If the sampled GeoEvents are formatted as Text and do not have a geometry field tagged GEOMETRY, the View in Event Viewer will be disabled.

  7. Explore the sampled GeoEvents in the Event Viewer. GeoEvents viewed in the Event Viewer
  8. The Event Viewer only displays the current set of sampled GeoEvents. To display another set of sampled GeoEvents, close the Event Viewer, click Refresh, and then click View in Event Viewer again to view another set of sampled GeoEvents.
  9. In the Event Viewer, left-click a GeoEvent, a popup appears with the attribute information. GeoEvent attribute data viewed in a popup in the Event Viewer

Compare GeoEvents from two routes

GeoEvent sampling can be performed on two different routes at the same time. Sampling two routes can be useful to compare and validate changes on related rea-time data. For example, a GeoEvent emitted by a Buffer Creator Processor should be expected to have a different geometry (polygon) from its original source geometry (point). By sampling GeoEvents from the routes going to and from the processor, you can confirm GeoEvents are not only received by the Buffer Creator Processor, but those same GeoEvents are buffered by the processor.

To compare sampled GeoEvents from two routes, create a new or open an existing published GeoEvent Service, ensure it is actively receiving GeoEvents, and follow the steps below.

  1. Ensure GeoEvent Sampler is open in the service designer and enabled.
  2. Left-click a route in a GeoEvent Service to begin sampling GeoEvents on the first selected route. First route selected in an example GeoEvent Service
  3. Remarque :

    Optionally, right-click a route and from the menu choose Sample Route to start sampling the first route.

  4. With the first route selected, right-click a second route and choose Compare Route. Second route selected in an example GeoEvent Service
  5. Remarque :

    Compare Route is only available once the first route is selected, otherwise it will be disabled. Routes sharing the same source element, whether an input, output, filter, or processor cannot be compared.

    Notice the second selected route is a different color (orange), indicating GeoEvent sampling will be performed on these two selected routes.

    Example of two selected routes in a GeoEvent Service

    With the two routes selected, two sampler windows will display in GeoEvent Sampler allowing you to compare the two routes. The left sampler window (blue) returns the sampled GeoEvents from the first selected route while the right window (orange) returns the sampled GeoEvents from the second selected route.

    Sampler window comparing two selected routes

    GeoEvent sampling can only be performed on up to two routes. When comparing two routes, changing the settings, refreshing, and opening the event viewer will apply to both sampler windows. Clearing and copying the data to the clipboard can be used independently and applies to the sampler window in which the tool is used.

  6. Click to view the GeoEvents from each route in the Event Viewer. Viewing two compared routes in the Event Viewer
  7. Notice the Event Viewer opens a viewer for each of the selected routes. This can be useful to validate geometry changes when performing event processing. For example, a GeoEvents original point geometry can be visualized in the first viewer while the same GeoEvent emitted from say a Buffer Creator Processor can be visualized in the second viewer. Allowing you to confirm the original point geometry was buffered successfully and is now a polygon.

GeoEvent sampling considerations and limitations

  • GeoEvents are only sampled when a GeoEvent Service is published, started, and is actively receiving real-time event data. Nothing will appear in the sampler window if the GeoEvent Service is not published, stopped, or event data is not being received.
  • GeoEvent Sampler can be used to perform sampling on the routes connecting inputs, outputs, processors, and filters only. Sampling inputs, outputs, processors, and filters elements is not supported.
  • Consider your real-time data and service design when sampling GeoEvents.
  • GeoEvent Sampler automatically disconnects and is disabled after 10 minutes of inactivity.
  • GeoEvent Sampler only supports the comparison of up to two routes between elements of a GeoEvent Service.
  • The order of GeoEvents sampled is not guaranteed. The order GeoEvents are ingested into GeoEvent Server may not be the same order they appear in the sampler window.
  • Sampled GeoEvents are not persisted or cached. Refreshing the sampler window or the browser session will remove any currently sampled GeoEvents.
  • Changing the GeoEvent Sampler settings requires a refresh. If the settings are changed during an active sampling of GeoEvents, the new settings will not take effect until refreshing GeoEvent Sampler.
  • When comparing two routes, it is plausible for the first sampler window to reach its sample size before the second sampler window displays any GeoEvents. Consider that data in route may not have met a filter or processing condition and is not being received.
  • The sampler window will display a progress bar when waiting to receive the first GeoEvent.
  • Viewing GeoEvents in the Event Viewer is not supported in offline environments.