Comments (15)
Hello, we are working on a workaround for this. We expect to have it at the end of this week, beginning of next week.
from mongock.
Sorry, we under estimate it, not because it's complex, we know what we need to do, but because we have a lot in our plates. I will notify you when it is ready 😃
from mongock.
We wanted to provide official support in the next major release. However, this is getting more and more attention and we won't be able to contain it much longer. So we have decided to provide a decent workaround to allow you guys to carry on working and add it in the next release as part of the core.
We did a POC to check the work needed and we are confident in releasing the workaround soon.
from mongock.
In the next major release we'll provide official support, but it won't be in this first quarter. Probably, starting Q2
from mongock.
Hello, we need to take a look to this in detail, but I bet is related to the conflict between Mongock using reflection and Graal Naive AOT compilation.
Although that's something will support in the next version, Mongock currently doesn't provide explicit support for AOT.
Anyway, we'll keep you updated as this is something that we need to address soon.
from mongock.
@nhandev552 if you can build a small project to which we can access via github and try ourselves would help a lot. Thanks
from mongock.
Hello @nhandev552 , could you provide that, so we can help you faster?
from mongock.
Hi, @dieppa thanks for supporting.
The simple project to reproduce: https://github.com/nhandev552/mongck-with-aot.
I worked around by clone mongodb-springdata-v4-driver
source code and adding @NestedConfigurationProperty
on the field io.mongock.driver.mongodb.springdata.v4.config.MongoDBConfiguration.WriteConcernLevel
, building AOT works well
from mongock.
Thanks @nhandev552, for the project. We'll let you know soon.
Anyway, If you thing that it's a workaround that is valiable for now, you may want to create a PR and we can take a look.
Thanks!!
from mongock.
I can confirm the issue. The mentioned fix is part of the solution. Second issue is that MongockCommunityProperties
doesn't expose mongock.properties
resource for native processing. As a workaround it is possible to add it into app resources and expose via native hints.
from mongock.
Even after the changes proposed, I still have issues with Mongock. Mongock works fine when the same app runs on JVM, unfortunately, the GraalVM build has the following issues. For some reason MongoSync4ChangeEntryRepository#getEntriesLog doesn't return any result. I've tried registering native hints for MongoDB Document, FindIterable, but it didn't help. The other issue is that MigrateExecutorBase#fetchAndPrepareChangeLogs doesn't return any result, even though I've registered all changelogs in native hints as well.
from mongock.
Hi !
Any news on this subject?
I'm facing same same issue
I added mongock.properties to hints resources but next problem seems related to org.reflections:
org.reflections.ReflectionsException: could not create Vfs.Dir from url, no matching UrlType was found [resource:/] either use fromURL(final URL url, final List<UrlType> urlTypes) or use the static setDefaultURLTypes(final List urlTypes) or addDefaultURLTypes(UrlType urlType) with your specialized UrlType.
at org.reflections.vfs.Vfs.fromURL(Vfs.java:113) at org.reflections.vfs.Vfs.fromURL(Vfs.java:95) at org.reflections.Reflections.lambda$scan$2(Reflections.java:176) at [email protected]/java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183) at [email protected]/java.util.HashMap$KeySpliterator.forEachRemaining(HashMap.java:1707) at [email protected]/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509) at [email protected]/java.util.stream.ForEachOps$ForEachTask.compute(ForEachOps.java:290) at [email protected]/java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:754) at [email protected]/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373) at [email protected]/java.util.concurrent.ForkJoinTask.invoke(ForkJoinTask.java:686) at [email protected]/java.util.stream.ForEachOps$ForEachOp.evaluateParallel(ForEachOps.java:159) at [email protected]/java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateParallel(ForEachOps.java:173) at [email protected]/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:233) at [email protected]/java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:596) at [email protected]/java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:765) at org.reflections.Reflections.scan(Reflections.java:173) at org.reflections.Reflections.<init>(Reflections.java:126) at org.reflections.Reflections.<init>(Reflections.java:159) at io.mongock.runner.core.executor.changelog.ChangeLogServiceBase.mergeChangeLogClassesAndPackages(ChangeLogServiceBase.java:160) at io.mongock.runner.core.executor.changelog.ChangeLogServiceBase.fetchChangeLogs(ChangeLogServiceBase.java:138) at io.mongock.runner.core.executor.operation.migrate.MigrateExecutorBase.fetchAndPrepareChangeLogs(MigrateExecutorBase.java:77) at io.mongock.runner.core.executor.operation.migrate.MigrateExecutorBase.executeMigration(MigrateExecutorBase.java:47) at io.mongock.runner.core.executor.operation.migrate.MigrateExecutorBase.executeMigration(MigrateExecutorBase.java:18) at io.mongock.runner.core.executor.MongockRunnerImpl.execute(MongockRunnerImpl.java:57)
from mongock.
Hello @mathieuales , @Rocker93 and @nhandev552 , sorry for the delay.
As mentioned, we'll provide official support with a proper solution in the next major release, however, as there is a clear demand for this, we have release a workaround with the expectation you can carry on working until the official GraaVM support is released.
We have create an example that you can pull form this repo.
Please let us know if you find anything or you need some help.
Thanks for the patience.
from mongock.
Thanks for example, i'll try this asap
from mongock.
hello,
what is the current state @dieppa ? Is there official support by mongock library or do I have to use that work around?
from mongock.
Related Issues (20)
- Migrations are not applied to DB. Also there is no logs related to mongock while running application HOT 1
- retryable writes error for mongock-examples/mongodb/standalone-reactive/ example HOT 1
- ClassCastException after upgrading from Mongock 4.1.14 to 5.2.4 HOT 6
- Clarify ordering mechanism in docs HOT 5
- upgrade guava to 32.0.0-jre to fix CVE-2020-8908 and CVE-2023-2976 HOT 2
- Support for Elasticsearch with an Elasticsearch driver HOT 1
- Change Unit is not working with spring boots's annotation @CompoundIndex on entity class HOT 5
- default-migration-author not applied in spring context HOT 2
- business related questions HOT 6
- Injecting beans by name HOT 4
- Unable to specify/override ReadConcern for transactional ChangeUnits HOT 1
- 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
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.