Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No flush backoff #796

Open
somehibs opened this issue Mar 12, 2022 · 1 comment
Open

No flush backoff #796

somehibs opened this issue Mar 12, 2022 · 1 comment

Comments

@somehibs
Copy link

DEFAULT_FLUSH_INTERVAL is set to 30s. This is fine for normal network conditions, if somewhat careless with battery usage.

However, under abnormal network conditions and inside an app with a foreground service, the lack of back-off behaviour results in significant wasted modem on time.

This is easily tested by running a DNS blackhole for api.segment.io (return NXDOMAIN, or cause any non-4xx error to be thrown). Instead of slowing requests, Segment wakes up the modem every 30 seconds.

Since there's no back-off functionality available to an SDK consumer, the default interval could probably be increased. This is especially true if the upload exception is caused by network connectivity.

@SiddheshShetye
Copy link

@somehibs correct. we faced this issue. where we were using our server and server went down, when it came up we received swarm of network hits from segment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants