Skip to content

v6.0.0

Compare
Choose a tag to compare
@kp-cat kp-cat released this 27 Feb 16:26
· 13 commits to master since this release
239fd3b

Added

  • set_default_user(user) / clear_default_user methods to set / remove a default user object used when there's no user passed to get_value / get_value_details / get_all_values / get_all_variation_ids methods.
  • set_offline / set_online methods to indicate whether the SDK is allowed to make HTTP calls or not. In 'offline' mode the SDK works from the cache only.
  • on_client_ready / on_config_changed / on_flag_evaluated / on_error hooks. Subscription is possible on client initialization options and with the hooks property on ConfigCatClient.
  • get_value_details method to retrieve evaluation details along with the feature flag / setting value. It returns the same details that is passed to on_flag_evaluated on each evaluation.
  • get_all_value_details method to retrieve evaluation details along with all feature flags/ setting values.

Changed

  • Client initialization options were moved to a ConfigCatOptions object that can be passed to the new configcatclient.get factory method. The create_client* methods are deprecated.
  • In the create_client* methods the following params changed:
    • config_cache_class to config_cache: A subclass of ConfigCache object is expected here (not a class).
    • connect_timeout to connect_timeout_seconds (to indicate the unit of measure).
    • read_timeout to read_timeout_seconds (to indicate the unit of measure).
    • flag_overrides expects a new FlagOverrides object (not an OverrideDataSource object).
  • ConfigCatClient's stop method is renamed to close.
  • ConfigCatClient can be explicitly closed via client.close and configcatclient.close_all methods.
  • force_refresh now returns with a result object that indicates whether the refresh succeeded or not.
  • The TTL of lazy_load and interval of auto_poll is compared against a cached fetch_time, which allows the SDK not necessarily download a new config.json at each application restart.
  • Fetch logic handles 403 response status and updates cached fetch_time in case of 304 403 and 404 response status.