Network layer not respecting DNS Time to Live value

The app we wrote POSTs data to our server on AWS using api.ourdomain.com. I used CNAME records in DNS to map api.ourdomain.com to the domain name in AWS. I have now set up a new server instance in AWS and I want to shift traffic over to the new instance so I updated the DNS record with the new domain name. The CNAME record has always had a 1 hour time to live so I expected that with a few hours the DNS change would propagate and the traffic would migrate over to the new environment and I can terminate the old one. It's been over 48 hours and when I check the elastic beanstalk logs I see traffic going to the new environment so I know the DNS entry is working correctly but I also see traffic going to the old environment.

Is there reason to believe the Hubitat would not respect the TTL for the DNS entry?

Is there reason to believe that if I tear down the old environment that the Hubitat will realize the DNS entry needs to be updated or will it likely keep sending the data to the wrong IP? We have a lot of Hubitats in the field so I don't want to risk that. A little lost data would be ok so I'm fine if it took a failure or two before they update the DNS.

I've seen other posts indicating that Hubitats may always use 8.8.8.8 for DNS resolution so we checked and 8.8.8.8 does have the new records.

1 Like

Tagging @gopher.ny as he’s probably best able to answer this question.

Long running sessions that are still being used?

It shouldn't be long running. The app code POSTs a bit of JSON to the server every minute or so using httpPost. It doesn't do anything to maintain a connection unless the underlying platform is maintaining it something between httpPost calls.

We figured it out and it was totally my fault. We have multiple subdomains on multiple domains that point to the production server. A consequence of the demo version of the site turning into the production version and older hardware still uses those old domains so I can't get rid of them. My boss reminded me about the subdomains on our other domain and it turns out I hadn't updated them. I updated them this morning and we've seen a rapid decline in traffic to the old site and a corresponding increase in traffic to the new site. Looks like the Hubitat is doing exactly what it should do with a DNS change like that.

2 Likes