Skip to content
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

MLIBZ-2636: replacing Realm ThreadSafeReference usage #313

Merged
merged 2 commits into from
Jul 31, 2018

Conversation

heyzooi
Copy link
Contributor

@heyzooi heyzooi commented Jul 31, 2018

Description

Replacing Realm ThreadSafeReference usage since it can't be used inside a transaction

Changes

  • Using the primaryKey as a reference instead of a ThreadSafeReference instance

Tests

  • Unit test added to cover the use case

@heyzooi heyzooi self-assigned this Jul 31, 2018
@heyzooi heyzooi force-pushed the feature/MLIBZ-2636-realm_thread_safe_reference branch from a7d1720 to 53f6a4c Compare July 31, 2018 18:20
@codecov-io
Copy link

codecov-io commented Jul 31, 2018

Codecov Report

Merging #313 into develop will increase coverage by 0.08%.
The diff coverage is 94.64%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #313      +/-   ##
===========================================
+ Coverage    85.87%   85.95%   +0.08%     
===========================================
  Files           70       70              
  Lines         8557     8552       -5     
===========================================
+ Hits          7348     7351       +3     
+ Misses        1209     1201       -8
Flag Coverage Δ
#Mac 83.71% <94.64%> (+0.02%) ⬆️
#iOS 85.88% <94.64%> (+0.08%) ⬆️
Impacted Files Coverage Δ
Kinvey/Kinvey/Operation.swift 87.83% <ø> (+6.75%) ⬆️
Kinvey/Kinvey/PullOperation.swift 100% <ø> (ø) ⬆️
Kinvey/Kinvey/Persistable.swift 85.34% <100%> (+0.38%) ⬆️
Kinvey/Kinvey/Entity.swift 82.83% <100%> (ø) ⬆️
Kinvey/Kinvey/User.swift 90.25% <100%> (-0.19%) ⬇️
Kinvey/Kinvey/Client.swift 85.32% <100%> (-0.17%) ⬇️
Kinvey/Kinvey/FindOperation.swift 96.68% <100%> (ø) ⬆️
Kinvey/Kinvey/Request.swift 98% <100%> (ø) ⬆️
Kinvey/Kinvey/Kinvey.swift 91.32% <100%> (+0.27%) ⬆️
Kinvey/Kinvey/RealmSync.swift 96% <100%> (ø) ⬆️
... and 7 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8d29bf8...4366f0e. Read the comment docs.

Copy link
Contributor

@vinaygahlawat vinaygahlawat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Are there any implications for replacing Realm ThreadSafeReference with data migration?

@heyzooi
Copy link
Contributor Author

heyzooi commented Jul 31, 2018

@vinaygahlawat no, this is not part of the cache schema

@heyzooi heyzooi merged commit 3c60d9b into develop Jul 31, 2018
@heyzooi heyzooi deleted the feature/MLIBZ-2636-realm_thread_safe_reference branch July 31, 2018 20:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants