Overwrite of Feature Layer destroys WebHooks

325
5
05-21-2021 09:58 AM
PhilLarkin1
Regular Contributor

 

When Overwriting a Feature Layer on ArcGIS Online via Pro the corresponding WebHooks become unusable. 

I published a hosted feature layer on AGOL using a fGDB as the source. Some WebHooks were created off the AGOL service. They functioned as expected. Later, I user ArcGIS Pro to Overwrite this service (Share Tab -> Web Layer -> Overwrite Web Layer). The Map I used held the same file geodatabase used to initially publish the service. The WebHook then stopped sending payloads. When I attempted to edit them, I received this error: 'Object reference not set to an instance of an object'. I am also unable to delete. 

PhilLarkin1_0-1621616059298.png

Pro Version: 2.6.0

fGDB version: 10.0

Tags (1)
0 Kudos
5 Replies
JRiggsbee
New Contributor III

Did you every find a work around for this?

0 Kudos
PhilLarkin1
Regular Contributor

No, this is an undocumented bug. I believe I was able to delete the WebHook and create a new one. An unfortunate outcome.

0 Kudos
JRiggsbee
New Contributor III

Thanks for the quick reply. I am trying to automate the update of a hosted feature service with a webhook. It seems like when I overwrite the SD file, it turns off  "Keep track of created and updated features." And the webhook is deleted, or at least no longer accessible, because if I create another webhook. It's ID is the next sequential number.

In the script I am overwriting the sd draft. There is not a parameter in the CreateWebLayerSDDraft tool to turn tracking on like editing and syncing. I thought I had a work around by creating a view. This post mentioned views when having editing issues on layers with webhooks. Now my script is failing when "keep track" is enabled on the view, when it is disabled, the script runs fine. I am going to escalate this with ESRI, and see if they are aware of the bug. If I get anywhere I will send an update.

0 Kudos
PhilLarkin1
Regular Contributor

I opted to Truncate/Append in code. This might help overcome the issue you describe. What version of Pro are you running.

Beware of BUG-000145215. In either update method (Pro/Python), your first edit on the layer will be reported in the webhook as an empty array.

0 Kudos
JRiggsbee
New Contributor III

Thanks. I thought of that, but I am trying to update the domain for a few fields and I haven't found viable method yet. This post seems to have a work around I need to try.

 

Edit: I am running Pro 2.9

0 Kudos