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

prepare 1.1.0 release #3

Merged
merged 55 commits into from
Apr 22, 2021
Merged

prepare 1.1.0 release #3

merged 55 commits into from
Apr 22, 2021

Conversation

LaunchDarklyCI
Copy link
Contributor

[1.1.0] - 2021-04-22

This release makes improvements to the helper methods for using Gson and Jackson for JSON conversion.

Added:

  • LDGson.valueToJsonElement and LDGson.valueMapToJsonElementMap: convenience methods for applications that use Gson types.
  • LDValue.arrayOf()

Changed:

  • In com.launchdarkly.sdk.json, the implementations of LDGson.typeAdapters and LDJackson.module have been changed for better efficiency in deserialization. Instead of creating an intermediate string representation and re-parsing that, they now have a more direct way for the internal deserialization logic to interact with the streaming parser in the application's Gson or Jackson instance.

Fixed:

  • Gson.toJsonTree now works with LaunchDarkly types, as long as you have configured it as described in com.launchdarkly.sdk.json.LDGson. Previously, Gson was able to convert these types to and from JSON string data, but toJsonTree did not work due to a known issue with the JsonWriter.jsonValue method; the SDK code no longer uses that method.
  • LDValue.parse() now returns LDValue.ofNull() instead of an actual null reference if the JSON string is null.
  • Similarly, when deserializing an EvaluationDetail<LDValue> from JSON, if the value property is null, it will now translate this into LDValue.ofNull() rather than an actual null reference.

…sses

add getters to EvaluationReason and hide its subclasses
…lasses

completely remove EvaluationReason subclasses
# Conflicts:
#	src/main/java/com/launchdarkly/sdk/EvaluationReason.java
#	src/main/java/com/launchdarkly/sdk/LDValue.java
remove @SInCE tags, misc doc fixes, add note about changelogging
make EvaluationDetail non-nullable + use boolean singletons
add JSON helpers, better serialization logic, and Gson adapter
# Conflicts:
#	src/main/java/com/launchdarkly/sdk/EvaluationDetail.java
#	src/test/java/com/launchdarkly/sdk/EvaluationReasonTest.java
#	src/test/java/com/launchdarkly/sdk/LDUserTest.java
improve and rigorously test equals() for all immutable types
more predictable exception behavior for LDValue.parse()
eli-darkly and others added 25 commits April 29, 2020 11:40
# Conflicts:
#	CHANGELOG.md
#	gradle.properties
ensure real nulls can't be stored in an LDValue
And update Android system image for testing to 21 (5.0 Lollipop).
add LDValue.arrayOf() + misc javadoc fixes
partially revert ch103941 fix that doesn't work in the Java SDK
…evert

unrevert some JSON improvements from previous revert
improve Gson integration using reader/writer delegation - take 2
@eli-darkly eli-darkly requested a review from bwoskow-ld April 22, 2021 19:21
@LaunchDarklyCI LaunchDarklyCI merged commit ffa134a into master Apr 22, 2021
@LaunchDarklyCI LaunchDarklyCI deleted the release-1.1.0 branch April 22, 2021 19:27
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants