Skip to content

SDK is polling feature flags ignores background settings #111

@AdamGrzybkowski

Description

@AdamGrzybkowski

Describe the bug
SDK is polling feature flags with disableBackgroundUpdating set to true and it does ignore backgroundPollingIntervalMillis when in background.
This is how I build the the LDClient currently

return LDConfig.Builder()
            .setMobileKey({{key}})
            .setDisableBackgroundUpdating(true)
            .setBackgroundPollingIntervalMillis(Duration.ofHours(5).toMillis().toInt())
            .setPollingIntervalMillis(Duration.ofMinutes(20).toMillis().toInt())
            .setStream(false)
            .build()

To reproduce
Run the app with the LDClient pasted above.
I was using Charles Proxy to inspect network requests.

Expected behavior
SDK is not polling feature flags when disabled and it respects that background polling interval if enabled

Logs
See the request time. These were done when the app was in the background.

1 2
Zrzut ekranu 2020-10-1 o 09 49 07 Zrzut ekranu 2020-10-1 o 09 50 13

SDK version
2.13.0

OS/platform
Android 10

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions