commercetools / commercetools-sync-java

Java library for importing and syncing (taking care of changes) data into one or more commercetools projects from external data files or from another commercetools project.
https://commercetools.github.io/commercetools-sync-java
Apache License 2.0
32 stars 37 forks source link

Add class name to sync statistics classes #1105

Closed lojzatran closed 1 year ago

lojzatran commented 1 year ago

Summary

I added a method that returns the class name of the current class. This could be serialized to JSON and saved in custom object so that we could use this name to correctly deserialized into a subclass.

Relevant Issues

JIRA: https://commercetools.atlassian.net/browse/DEVX-272

codecov-commenter commented 1 year ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (f7ff693) 97.63% compared to head (f834428) 97.63%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #1105 +/- ## ========================================= Coverage 97.63% 97.63% - Complexity 2662 2674 +12 ========================================= Files 229 229 Lines 8459 8471 +12 Branches 513 513 ========================================= + Hits 8259 8271 +12 Misses 128 128 Partials 72 72 ``` | [Files](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools) | Coverage Δ | | |---|---|---| | [...tdiscounts/helpers/CartDiscountSyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL2NhcnRkaXNjb3VudHMvaGVscGVycy9DYXJ0RGlzY291bnRTeW5jU3RhdGlzdGljcy5qYXZh) | `100.00% <100.00%> (ø)` | | | [...ync/categories/helpers/CategorySyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL2NhdGVnb3JpZXMvaGVscGVycy9DYXRlZ29yeVN5bmNTdGF0aXN0aWNzLmphdmE=) | `100.00% <100.00%> (ø)` | | | [.../java/com/commercetools/sync/commons/BaseSync.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL2NvbW1vbnMvQmFzZVN5bmMuamF2YQ==) | `100.00% <ø> (ø)` | | | [...tools/sync/commons/helpers/BaseSyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL2NvbW1vbnMvaGVscGVycy9CYXNlU3luY1N0YXRpc3RpY3MuamF2YQ==) | `100.00% <100.00%> (ø)` | | | [...sync/customers/helpers/CustomerSyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL2N1c3RvbWVycy9oZWxwZXJzL0N1c3RvbWVyU3luY1N0YXRpc3RpY3MuamF2YQ==) | `100.00% <100.00%> (ø)` | | | [...tomobjects/helpers/CustomObjectSyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL2N1c3RvbW9iamVjdHMvaGVscGVycy9DdXN0b21PYmplY3RTeW5jU3RhdGlzdGljcy5qYXZh) | `100.00% <100.00%> (ø)` | | | [...c/inventories/helpers/InventorySyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL2ludmVudG9yaWVzL2hlbHBlcnMvSW52ZW50b3J5U3luY1N0YXRpc3RpY3MuamF2YQ==) | `100.00% <100.00%> (ø)` | | | [...s/sync/products/helpers/ProductSyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL3Byb2R1Y3RzL2hlbHBlcnMvUHJvZHVjdFN5bmNTdGF0aXN0aWNzLmphdmE=) | `100.00% <100.00%> (ø)` | | | [...roducttypes/helpers/ProductTypeSyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL3Byb2R1Y3R0eXBlcy9oZWxwZXJzL1Byb2R1Y3RUeXBlU3luY1N0YXRpc3RpY3MuamF2YQ==) | `100.00% <100.00%> (ø)` | | | [...ppinglists/helpers/ShoppingListSyncStatistics.java](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools#diff-c3JjL21haW4vamF2YS9jb20vY29tbWVyY2V0b29scy9zeW5jL3Nob3BwaW5nbGlzdHMvaGVscGVycy9TaG9wcGluZ0xpc3RTeW5jU3RhdGlzdGljcy5qYXZh) | `100.00% <100.00%> (ø)` | | | ... and [3 more](https://app.codecov.io/gh/commercetools/commercetools-sync-java/pull/1105?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=commercetools) | |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.