Skip to content
This repository was archived by the owner on Oct 29, 2024. It is now read-only.

Commit a16d260

Browse files
author
LaunchDarklyReleaseBot
committed
Releasing version 5.0.0
1 parent 9b38765 commit a16d260

File tree

4 files changed

+5635
-638
lines changed

4 files changed

+5635
-638
lines changed

CHANGELOG.md

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,59 @@
22

33
All notable changes to the LaunchDarkly React Native SDK will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org).
44

5+
## [5.0.0] - 2021-08-20
6+
### Added:
7+
- The SDK now supports the ability to control the proportion of traffic allocation to an experiment. This works in conjunction with a new platform feature now available to early access customers.
8+
- Added `numberVariation` and `numberVariationDetail` to LDClient.
9+
- Added the `alias` method to LDClient. This can be used to associate two user objects for analytics purposes with an alias event.
10+
- Added the `autoAliasingOptOut` configuration option. This can be used to control the new automatic aliasing behavior of the `identify` method; by setting `autoAliasingOptOut` to true, `identify` will not automatically generate alias events.
11+
- Improved testing of JavaScript wrapper using mock native modules.
12+
13+
### Changed (requirements/dependencies/build):
14+
- iOS: The underlying SDK version has been updated from 5.4.1 to 5.4.3. See the [release notes](https://github.com/launchdarkly/ios-client-sdk/releases) for details.
15+
- Android: The underlying SDK version has been updated from 2.14.1 to 3.1.0. See the [release notes](https://github.com/launchdarkly/android-client-sdk/releases) for details.
16+
- Android: Migrated from using the Android Support Libraries to using AndroidX from Jetpack.
17+
- Android: The minimum API version has been raised from API level 16 (Android 4.1 Jelly Bean) to API level 21 (Android 5.0 Lollipop).
18+
- Android: The SDK no longer has a dependency on Google Play Services. This dependency was only used on pre-21 Android API levels to improve TLS 1.2 compatibility, as the minimum Android version has been raised to 21, the dependency is no longer necessary.
19+
- Android: The SDK is now built with modern Gradle (6.7, Android plugin 4.1.3) and uses Java 8.
20+
21+
### Changed (API/behavioral):
22+
- The `LDClient.identify` method will now automatically generate an alias event when switching from an anonymous to a known user. This event associates the two users for analytics purposes as they most likely represent a single person. This behavior can be disabled with the `autoAliasingOptOut` configuration option.
23+
- The `LDClient` `<type>Variation` and `<type>VariationDetail` methods (e.g. `boolVariation`) now validate that default values are the correct type. If the default value fails validation the `Promise` will be rejected.
24+
- The primitive variation methods, `LDClient.boolVariation`, `LDClient.boolVariationDetail`, `LDClient.numberVariation`, and `LDClient.numberVariationDetail`, now require a default value parameter (rather than being optional). If missing, the `Promise` will be rejected.
25+
- Android: `LDClient.allFlags` will no longer convert `String` flags into JSON `Array`s or `Object`s when the value can be parsed into JSON `Array`s or `Object`s.
26+
- Android: For compatibility with older SDK behavior, the `LDClient.stringVariation` method could be used to retrieve JSON flags in a serialized representation. This compatibility behavior has been removed, and attempts to request a JSON valued flag using stringVariation will behave the same as other mismatched type variation calls.
27+
- Android: All log messages are now tagged `LaunchDarklySdk` for easier filtering. Thanks to @valeriyo for the suggestion ([#113](https://github.com/launchdarkly/android-client-sdk/issues/113)).
28+
- Android: The when the `country` user is set, the SDK will no longer attempt to look up the country from the provided `String` (attempting to match it as an ISO-3166-1 alpha-2, alpha-3 code; or a country name) and set the country to the resultant IOS-3166-1 alpha-2 only if successful. The SDK no longer gives this attribute special behavior, and sets the user's country attribute directly as the provided `String`.
29+
- Android: If the `debugMode` configuration option is set to `true`, the SDK will now enable detailed timber logging.
30+
- Android: Custom user attributes that are `Object`s will no longer be ignored.
31+
- Android: Elements of `Array` custom user attributes will no longer be ignored if they are not `String`s or `Number`s.
32+
- Android: `Array` custom user attributes with mixed types will no longer ignore non-`String` elements.
33+
34+
### Fixed (Android):
35+
- Catch `SecurityException` when thrown on call to `getNetworkCapabilities` used to detect current network availability. ([#129](https://github.com/launchdarkly/android-client-sdk/issues/129))
36+
- Explicitly flag `PendingIntent`s as `FLAG_IMMUTABLE` on Android SDK versions that support doing so. Explicitly specifying mutability is required when targeting Android S+. ([#133](https://github.com/launchdarkly/android-client-sdk/issues/133))
37+
- Increased the compile-time dependency on `jackson-databind` to 2.10.5.1, due to [CVE-2020-25649](https://nvd.nist.gov/vuln/detail/CVE-2020-25649).
38+
- Update the dependency on the shared [launchdarkly/java-sdk-common](https://github.com/launchdarkly/java-sdk-common) to 1.1.2 to prevent Jackson from showing up as a transitive dependency in tools that inspect module metadata.
39+
- The Android manifest has been updated to explicitly specify the `android:exported` attribute on declared `receiver` elements. This is to meet [new requirements](https://developer.android.com/about/versions/12/behavior-changes-12#exported) in the upcoming Android 12 release.
40+
- Fixed an issue where the SDK could log error level messages when attempting to send diagnostic events without an internet connection. The SDK will no longer attempt to send diagnostic events when an internet connection is known to be unavailable, and will not log an error level message if the connection fails. Thanks to @valeriyo for reporting ([#107](https://github.com/launchdarkly/android-client-sdk/issues/107)).
41+
- Fixed an issue where flags listeners would be informed of changes to unchanged flags whenever the SDK receives an entire flag set (on a new stream connection, a poll request, or any stream updates behind a relay proxy).
42+
- Fixed an issue where a `NullPointerException` is thrown if `LDClient.close()` is called multiple times.
43+
- Improved the proguard/R8 configuration to allow more optimization. Thanks to @valeriyo for requesting ([#106](https://github.com/launchdarkly/android-client-sdk/issues/106))
44+
- Fixed a potential issue where the SDK could cause additional throttling on requests to the backend service when previously throttled requests had been cancelled before completion.
45+
46+
### Fixed (iOS):
47+
- Fixed an issue where `304 NOT_MODIFIED` responses to SDK polling mode requests would be considered error responses. This could cause the completion on a `identify` request to not complete, and gave erroneous connection information data and logging output.
48+
- Fixed a crash when attempting to cache flag data containing variation JSON values containing a JSON `null` value nested within a JSON array.
49+
- Avoid crash when timeout/interval configuration options are set to sufficiently large values. This was caused when converting these values to an `Int` value of milliseconds. (Thanks, [@delannoyk](https://github.com/launchdarkly/ios-client-sdk/pull/246)!)
50+
- Update `Quick` test dependency to 3.1.2 to avoid build warnings and adopt security fixes. ([#243](https://github.com/launchdarkly/ios-client-sdk/issues/243))
51+
- Use `AnyObject` over `class` in protocol inheritance to avoid compiler warnings. ([#247](https://github.com/launchdarkly/ios-client-sdk/issues/247))
52+
53+
### Removed:
54+
- `LDClient.intVariation` and `LDClient.floatVariation`. Please use `LDClient.numberVariation` instead.
55+
- `LDClient.intVariationDetail` and `LDClient.floatVariationDetail`. Please use `LDClient.numberVariationDetail` instead.
56+
57+
558
## [4.2.2] - 2021-06-15
659
### Fixed:
760
- Correct usages of undeclared variables when registering or un-registering connection mode or all flags listeners. ([#82](https://github.com/launchdarkly/react-native-client-sdk/issues/82))

ios/LaunchdarklyReactNativeClient.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Pod::Spec.new do |s|
33
s.name = "LaunchdarklyReactNativeClient"
4-
s.version = "4.2.2"
4+
s.version = "5.0.0"
55
s.summary = "LaunchdarklyReactNativeClient"
66
s.description = <<-DESC
77
LaunchdarklyReactNativeClient

0 commit comments

Comments
 (0)