I've run into a situation in which ConnMan's online check often fails
due to a temporary HTTP 404 error. ConnMan remains in ready state and
never repeats the online check. The connection, however, is actually
correctly set up and works.
As I've found out, the 404 error is actually a DNS timeout that is
reported as 404 by resolv_result(). It happens right after
establishing a WLAN connection to a slow access point using manual
IPv4 configuration (no DHCP involved here). Successive DNS queries are
answered more or less immediately, it's just the first one that is
always slow, often taking longer than the timeout of 5 seconds. Even
worse: sometimes the first DNS query is simply dropped by that
particular access point, so there will never be an answer, no matter
how long the timeout would be set.
While I think this problem is clearly caused by the access point and
ConnMan is not to blame here, repeating the online check would help a
lot. After all, the connection works well after the initial hiccups. I
can also dream up dozens of different scenarios that would lead to
similar temporary failure, and repeating the online check after
failure would fix these scenarios as well.
Note that there seems to be no way to fix this situation from external
applications as there is no way to request to restart the online
check. It is only possible to disconnect from the service and connect
again, but it doesn't help here because the DNS timeout problem
potentially occurs again on each connect.
Is there a reason to avoid repeating the online check after failure?
Are there any plans for improving the online check?