HTTP Request, delay and retry

Post your questions and help other users.

Moderator: Martin

Post Reply
Mikey
Posts: 9
Joined: 08 Feb 2013 21:25

HTTP Request, delay and retry

Post by Mikey » 24 Nov 2015 17:03

I am trying to make it, so when my phone disconnect from my wifi, it use HTTP Request to tell my homeautomation system I am no longer home. It does trigger correct, but it happens so fast it havent switched to mobile data, and same happens when I get home, where it has just connected to wifi, and still not have the connection fully established. With both timeout set to 5 or 10 seconds, it does not manage to get a connection, and stops with the error "unable to resolve host"

I then also tried to make a loop so it will retry 5 times, but instead it just stops the first time with "unable to resolve host", and then does not try again. Are there a way to make it ignore errors, and continue, so it can move further in the flow, wait the 1s I set, then retry again?

User avatar
MURTUMA
Posts: 697
Joined: 05 Mar 2013 22:43

Re: HTTP Request, delay and retry

Post by MURTUMA » 25 Nov 2015 06:39

After the trigger put "sleep" action, which pauses the flow and allows the connection change before continuing. Try 10 seconds at first an increase or decrease until you find the sweet spot.

Assuming you have the http requests syntax right, the error propably happens due to not having a connection. Tap the outgoing line from the action > edit > change it to exception. That allows continuing the flow in case of an error. Remember to draw another regular line from the action.

Post Reply