Skip to content

#235 Add BatchValidator for category sync#568

Closed
salander85 wants to merge 21 commits intomasterfrom
#235_improve-caching-for-category-ref
Closed

#235 Add BatchValidator for category sync#568
salander85 wants to merge 21 commits intomasterfrom
#235_improve-caching-for-category-ref

Conversation

@salander85
Copy link
Copy Markdown
Contributor

@salander85 salander85 commented Sep 14, 2020

Summary

Implement a CategoryBatchValidator to improve caching in category sync

Relevant Issues

#235

Todo

  • Tests
    • Unit
    • Integration
  • Documentation
  • Add Release Notes entry.

Hints for Review

NOTE: CodeCov is failing because exception handling is never reached. As we need to come up with a new solution in the ReferenceResolvers this is ignored for now. Fixing this issue should be part of the second part of the ticket which is generalization of the Validator.

salander85 and others added 17 commits September 8, 2020 12:55
Changes in CategoryBatchProcessor
* Rename to CategoryBatchValidator
* Handle errors inside
* Return a ImmutablePair of valid drafts and valid keys from the validation method
* Pass the batch of categoryDrafts in the validation method
* Change constructor to init syncOptions and statistics fields
…y-ref' into #235_improve-caching-for-category-ref
…y-ref' into #235_improve-caching-for-category-ref

# Conflicts:
#	src/main/java/com/commercetools/sync/categories/CategorySync.java
#	src/main/java/com/commercetools/sync/categories/helpers/CategoryBatchValidator.java
…y-ref' into #235_improve-caching-for-category-ref

# Conflicts:
#	src/main/java/com/commercetools/sync/services/impl/CategoryServiceImpl.java
#	src/test/java/com/commercetools/sync/categories/CategorySyncTest.java
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Sep 15, 2020

Codecov Report

Merging #568 into master will decrease coverage by 0.05%.
The diff coverage is 96.05%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #568      +/-   ##
============================================
- Coverage     99.20%   99.14%   -0.06%     
- Complexity     1871     1881      +10     
============================================
  Files           157      158       +1     
  Lines          4657     4691      +34     
  Branches        280      285       +5     
============================================
+ Hits           4620     4651      +31     
- Misses           19       22       +3     
  Partials         18       18              
Impacted Files Coverage Δ Complexity Δ
.../commercetools/sync/services/impl/BaseService.java 100.00% <ø> (ø) 30.00 <0.00> (ø)
...cetools/sync/services/impl/BaseServiceWithKey.java 100.00% <ø> (ø) 5.00 <0.00> (ø)
...om/commercetools/sync/categories/CategorySync.java 98.27% <89.65%> (-1.29%) 76.00 <3.00> (-1.00)
...ync/categories/helpers/CategoryBatchValidator.java 100.00% <100.00%> (ø) 14.00 <14.00> (?)
...etools/sync/services/impl/CategoryServiceImpl.java 100.00% <100.00%> (ø) 15.00 <4.00> (-3.00)

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 0e01950...7b7b3f7. Read the comment docs.

@salander85 salander85 changed the title WIP - #235 improve caching for category ref #235 Add BatchValidator for category sync Sep 16, 2020
Comment thread src/main/java/com/commercetools/sync/services/impl/BaseService.java
@ahmetoz ahmetoz removed the request for review from lojzatran September 16, 2020 11:49
@ahmetoz
Copy link
Copy Markdown
Contributor

ahmetoz commented Sep 23, 2020

Will be covered by #574

@ahmetoz ahmetoz closed this Sep 23, 2020
@ahmetoz ahmetoz deleted the #235_improve-caching-for-category-ref branch September 28, 2020 12:10
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