Comments (6)
Hello @rgruber1 , thanks for raising the issue. We'll take a look to reproduce it and let you know.
However, even though the unique key is composed of the ChangeUnit id + author, the best practice (and the recommended one) is to have unique ChangeUnit ids.
In a future major version the way to go will be to have unique ids (the author will be optional and won't be part of the key).
As a workaround, can you refactor your ChangeUnits to prevent duplicated ids?
from mongock.
@rgruber1 can you update us on this, so we can close it and move it to an internal ticket to address it?
from mongock.
As a workaround, we simplified the annotation definitions and only specify the mandatory attributes (id + order), so that mongock uses the id and the default author for the uniqueness check across change units (this effectively makes change units unique based on id only as you know).
from mongock.
Thanks, we'll fix this in the next major release. This workaround should be fine for the time being.
from mongock.
Mongock change unit documentation could possibly mention this defect in https://docs.mongock.io/v5/migration/index.html
from mongock.
you are totally right! Will do!
from mongock.
Related Issues (20)
- Mongock migration for MongoDB on CosmosDB fails HOT 2
- @ChangeSet executed before @ChangeUnit, ignoring order HOT 3
- MongoCK ChangeUnit doesn't auto wire other spring beans as dependency HOT 3
- Not supporting @ConditionalOnExpression or @ConditionalOnProperty HOT 2
- ChangeUnits containing Unnamed Variables (JEP443) are not found by Mongock. HOT 7
- Configuration error when using multiple transaction managers HOT 1
- BOM not published for version 5.3.5 HOT 2
- State that the order of a ChangeUnit is alphabetically (documentation/website issue) HOT 1
- Overwriting index of a collection fails HOT 6
- Error Creating bean getBuilder when deploying on docker HOT 5
- When using @ChangeUnit, if @Execution fails, and then @RollbackExecution fails, the original execution failure is not logged anywhere HOT 8
- Proxies are not created in GraalVM HOT 5
- Mongock use the wrong class loader when used with Quarkus HOT 10
- MongoCK 5.4.0 does not execute change sets by order HOT 1
- Exception com.mongodb.MongoCommandException: Command failed with error 26 (NamespaceNotFound) thrown sometimes. HOT 1
- OffsetDateTime support on DateUtils class HOT 7
- Feature request: Skipping particular changeunit
- Feature request: Provide more Metadata on particular change unit run
- Mongock, when configured with Spring Data, does not respect configured transaction manager HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mongock.