automatilcy Activate geofence

172
2
02-14-2024 08:36 PM
Moi_Nccncc
New Contributor III

Can I activate or deactivate a geofence from inside a service?

0 Kudos
2 Replies
GregoryChristakos
Esri Contributor

Hi @Moi_Nccncc - Yes you can if you're using a geofence synchronization rule on a feature or stream service and you have a string type field in your data whose literal string values are either true or false. Assuming you've met this criteria, you can configure your geofence sync rule to use that said field as the "active field". Feature records whose active field value are "true" will continue to be used as geofences. Those that are "false" will not be used as geofences for further processing. I've included a screenshot below of what I am talking about in the sync rule settings:

GregoryChristakos_0-1707999202208.png

If you have all this in place, you can configure a GeoEvent service to process geofence records and use different logic paths to set the active field value to true or false based on your needs.

It's worth noting that you can also control whether or not a geofence is active based on time extents as well, but the tried and true method is going to be to use the active field property.

0 Kudos
Moi_Nccncc
New Contributor III

Thanks you very much,

    What I am thinking is force geofence active and not active from the service it self without the need to  wait until the geofence synchs again.

0 Kudos