Skip to content

v8.0.0

Compare
Choose a tag to compare
@novalisdenahi novalisdenahi released this 30 Dec 16:15
· 47 commits to master since this release

Added

  • ConfigCatClient.get() factory method that produces a single instance / SDK key.
  • setOffline() / setOnline() methods to indicate whether the SDK is allowed to make HTTP calls or not. In 'offline' mode the SDK works from the cache only.
  • getValueDetails() / getValueDetailsAsync() methods to retrieve evaluation details along with the feature flag / setting value.
  • getAllValueDetails() / getAllValueDetailsAsync() methods to retrieve the detailed values of all feature flags or settings.
  • onCleintReady() / onBeforeClientClose() / onConfigChanged(Map<String, Setting>) / onFlagEvaluated(EvaluationDetails) / onError(String) hooks. Subscription is possible on client initialization options and on the hooks property of ConfigCatClient.
  • setDefaultUser(user) / clearDefaultUser() methods to set / remove a default user object used when there's no user passed to getValue[Async]() / getValueDetails[Async]() / getAllValues[Async]() / getAllValueDetails[Async]() methods.

Changed

  • Client initialization options were moved to a Options object that can be passed with a Consumer to the new ConfigCatClient.get() factory method.
  • ConfigCatClient can be explicitly closed via client.close() and ConfigCatClient.closeAll() methods.
  • forceRefresh() method now returns with a result object to indicate whether the refresh succeeded or not.
  • autoPollRateInSeconds lower limit changed to 1 second.
  • The TTL of lazyLoad and interval of autoPoll is compared against a cached fetchTime, which allows the SDK not necessarily download a new config.json at each application restart.
  • Fetch logic handles 403 response status and update cached fetchTime in case of 304 403 and 404 response status.

Removed

  • ConfigCatClient(String sdkKey) public constructor.
  • asyncRefresh parameter of PollingModes.lazyLoad().
  • getVariationId(), getVariationIdAsync(), getAllVariationIds(), getAllVariationIdsAsync() removed in favour of getValueDetails(), getAllValueDetails()
  • configurationChangeListener parameter of PollingModes.autoPoll(). It was replaced by the onConfigChanged() hook.