Hi there, I thought I should share some advice after something happened to my webhooks, it might help someone.
I set up 5 webhooks in 2015, 1 was working for a long time, the other 4 were created in July reaching out to two different domains. I have a Photon which constantly monitors the one webhook and makes use of the other four many times a month to control a boiler.
In December, my monitor webhook stopped functioning. I simply dropped and recreated it in December and thought no more about it.
In February, my 4 control webhooks stopped working! I had come to think of them as totally reliable and it was not inconceivable that both target systems were down at the same time so I initially started debugging there. Needless to say, everything checked out and only my webhooks could have been at fault. I could see no other option than to drop and recreate them. Which worked perfectly.
So, do webhooks somehow expire after a certain amount of time? In my case, 7 months and one week. Somehow the webhooks were there, listed in the system but they no longer did anything. My advice for now is to drop and recreate your webhooks regularly, 3x a year in my case.
Good question! I’ve recently received more reports that some long-running hooks might occasionally jam-up. I’m considering this a bug and looking into the best way to fix it.
Hey there!
I have a webhook created a little more than a month ago and it stopped working today. I did not access it constantly, just created it to test things out.
Now, I created another webhook with the exact same name and the same old code started to work again. The two have the exact same name but different hook_ids…how does that work? When I publish a hook_name how does the server recognize which one is called?
Hi I have just had the same issue. The webhook was created 2015-07-27T15:25:55.263Z and has been working ever since but stopped sometime after the device went offline on Sat 12 Mar. The photon needs to be able to go offline to log data and then reconnect.
The strange thing is that photon data was visible in the dashboard and I could list the webhook via cli.
Re-creating the webhook solved the issue. Also deleted the old webhook ID.
@Dave The original webhook ID was: 55b64d8329ccf09d148dbf87
We’re investigating reports of this, but it’s also possible for your webhook to be automatically disabled if the target server is consistently returning error response codes (status code over 400). Please watch your event stream for error responses, and you’ll see the reason if your hook is disabled.
Our application (Particle device to Particle cloud to our cloud) utilizes a few webhooks. That’s how the Photons talk to our cloud.
We noticed that we weren’t getting one of the events so we investigated. As it turns out, the devices were sending publishing the event so setting the webhook – its used once a day maybe so not often – because we could see it using the monitor. However, the URI for the webhook was not being called. We could call the URI using a browser and it worked. So for some reason the webhook just stopped working! Note that it had been working just fine but then just stopped working. I deleted the webhook and then readded it and it’s working again.
This is disturbing that the system would just stop working. This is a commercial application and not a personal one so if this keeps happening, we’ve got a serious issue.
I have a couple of Photons installed at different locations. They’ve been pushing data very reliably for a couple of months. However, at 1:32 AM (EDT) on 3/29, they both stopped pushing data via the same webhooks. I have implemented a function to allow me to remotely do a resetI() via a cloud function, but that didn’t help. I had to delete and re-create the webhooks. I’ve had to do this in the past a few times which makes me worry about the stability of webhooks. Are these common problems and can I expect this situation to occur going forward? Fortunately, my cloud system tells me when data has not been received for a period of time, so I made aware of this type of failure.
Also, is there a native means to reset a Photon other than creating a cloud function and using up one of those limited resources?
[quote=“ctmorrison, post:1, topic:21657”]
Also, is there a native means to reset a Photon other than creating a cloud function and using up one of those limited resources?
[/quote] By creating a generic Particle.function() that can parse various commands allows you to leverage a single Particle.function() more effectively. At present, there is no other method of causing a device reset (except for an OTA!).
As for webhooks going down, I know @Dave has been working on improvements but I’m not sure they have been deployed yet.