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

Add CodecXXX capable of updating map, list, set types in statement instead of replacing it #263

Merged
merged 2 commits into from
Sep 9, 2024

Conversation

dfakhritdinov
Copy link
Contributor

Motivation

Using currently available EncodeXXX one cannot add/update one value in fields of type Map, List or Set, only option is override the field. CodecXXX provides access to the field value while encoding thus makes possible updating fiend based on its current value.

@coveralls
Copy link

coveralls commented Sep 5, 2024

Pull Request Test Coverage Report for Build 10741738528

Details

  • 17 of 22 (77.27%) changed or added relevant lines in 4 files are covered.
  • 2 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.4%) to 88.083%

Changes Missing Coverage Covered Lines Changed/Added Lines %
scassandra/src/main/scala/com/evolutiongaming/scassandra/UpdateByIdx.scala 3 4 75.0%
scassandra/src/main/scala/com/evolutiongaming/scassandra/UpdateByName.scala 3 4 75.0%
scassandra/src/main/scala/com/evolutiongaming/scassandra/syntax.scala 11 12 91.67%
scassandra/src/main/scala/com/evolutiongaming/scassandra/UpdateRow.scala 0 2 0.0%
Files with Coverage Reduction New Missed Lines %
scassandra/src/main/scala/com/evolutiongaming/scassandra/syntax.scala 1 78.79%
scassandra/src/main/scala/com/evolutiongaming/scassandra/CreateClusterJ.scala 1 78.13%
Totals Coverage Status
Change from base Build 10452624162: -0.4%
Covered Lines: 680
Relevant Lines: 772

💛 - Coveralls

@dfakhritdinov
Copy link
Contributor Author

I will reconsider having decoding part in new Codec API:

def decode[D <: GettableByIndexData] ...

because its almost same as in existing Decode trait. Also name codec should be reconsidered as well

Copy link
Contributor

@mr-git mr-git left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@mr-git mr-git left a comment

Choose a reason for hiding this comment

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

LGTM

@dfakhritdinov dfakhritdinov merged commit aa8356b into master Sep 9, 2024
7 checks passed
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.

4 participants