-
Notifications
You must be signed in to change notification settings - Fork 42
Increase ClientOptions mutability safety by cloning objects #827
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Increase ClientOptions mutability safety by cloning objects #827
Conversation
…y with config files
Fix TokenDetails equals() method by checking instance before casting
Fix ClientOptions copy method
…lity-safety-by-cloning-objects # Conflicts: # core/src/main/java/io/ably/lib/util/ObjectCopyUtil.java
KacperKluka
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few questions and suggestions 😉
core/src/test/java/io/ably/lib/test/realtime/RealtimeAuthTest.java
Outdated
Show resolved
Hide resolved
Remove comment about deep copy as we do not need it
ikbalkaya
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have made some suggestions
core/src/test/java/io/ably/lib/test/realtime/RealtimeAuthTest.java
Outdated
Show resolved
Hide resolved
core/src/test/java/io/ably/lib/test/realtime/RealtimeAuthTest.java
Outdated
Show resolved
Hide resolved
core/src/test/java/io/ably/lib/test/realtime/RealtimeAuthTest.java
Outdated
Show resolved
Hide resolved
Co-authored-by: Ikbal Kaya <ceikbal@gmail.com>
Co-authored-by: Ikbal Kaya <ceikbal@gmail.com>
KacperKluka
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
Added ObjectCopyUtil with copy method for ClientOptions. Changing fields in options after it is passed to AblyRealtime will no longer change options in the AblyRealtime instance.