Fix warning on instantiate object on Android N+ #514
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
objenesis in the version 2.3 (https://github.com/easymock/objenesis/releases/tag/2.3) fixed important warning caused by using private ObjectStream api on Android N+.
I'm a developer of Paper DB lib (https://github.com/pilgr/Paper) and happy to use Kryo serialization!
But I noticed users started to failing issues with a warning happening on read data on Android N and above
ObjectStreamClass.newInstance(Class<?>, long) is private API and will be removed in a future Android release
.I realized Objenesis fixed it, but Kryo 4.0 unfortunately uses outdated version. I temporary fixed this warning in the lib by forcing use of Objenesis 2.3. But would be awesome to have a new version of Kryo to include such dependency update.
Thanks!