Closed m4ttek closed 9 months ago
Thank you @m4ttek we the new release that is the goal of this version.
@m4ttek we refactored the code. Could you check it?
@otaviojava I still get an error while packaging my app using modules:
Caused by: jdk.jpackage.internal.ConfigException: java.lang.module.FindException: Unable to derive module descriptor for /home/mkaminski/work/fuel-resolver/target/dependency/jnosql-mapping-core-1.0.4-SNAPSHOT.jar
at jdk.jpackage/jdk.jpackage.internal.AppImageBundler.validate(AppImageBundler.java:78)
at jdk.jpackage/jdk.jpackage.internal.Arguments.generateBundle(Arguments.java:689)
... 31 more
Caused by: java.lang.module.FindException: Unable to derive module descriptor for /home/mkaminski/work/fuel-resolver/target/dependency/jnosql-mapping-core-1.0.4-SNAPSHOT.jar
at java.base/jdk.internal.module.ModulePath.readJar(ModulePath.java:648)
at java.base/jdk.internal.module.ModulePath.readModule(ModulePath.java:332)
at java.base/jdk.internal.module.ModulePath.scanDirectory(ModulePath.java:285)
at java.base/jdk.internal.module.ModulePath.scan(ModulePath.java:233)
at java.base/jdk.internal.module.ModulePath.scanNextEntry(ModulePath.java:191)
at java.base/jdk.internal.module.ModulePath.find(ModulePath.java:155)
at java.base/java.lang.module.ModuleFinder$2.lambda$find$0(ModuleFinder.java:351)
at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197)
at java.base/java.util.AbstractList$RandomAccessSpliterator.tryAdvance(AbstractList.java:708)
at java.base/java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:129)
at java.base/java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:527)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:513)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
at java.base/java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:150)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:647)
at java.base/java.lang.module.ModuleFinder$2.find(ModuleFinder.java:353)
at jdk.jpackage/jdk.jpackage.internal.LauncherData.createModular(LauncherData.java:145)
at jdk.jpackage/jdk.jpackage.internal.LauncherData.create(LauncherData.java:121)
at jdk.jpackage/jdk.jpackage.internal.StandardBundlerParam.lambda$static$0(StandardBundlerParam.java:86)
at jdk.jpackage/jdk.jpackage.internal.BundlerParamInfo.fetchFrom(BundlerParamInfo.java:114)
at jdk.jpackage/jdk.jpackage.internal.BundlerParamInfo.fetchFrom(BundlerParamInfo.java:88)
at jdk.jpackage/jdk.jpackage.internal.AppImageBundler.validate(AppImageBundler.java:68)
... 32 more
Caused by: java.lang.module.InvalidModuleDescriptorException: Provider class org.eclipse.jnosql.mapping.reflection.collection.DequeSupplier not in JAR file jnosql-mapping-core-1.0.4-SNAPSHOT.jar
at java.base/jdk.internal.module.ModulePath.deriveModuleDescriptor(ModulePath.java:555)
at java.base/jdk.internal.module.ModulePath.readJar(ModulePath.java:644)
... 54 more
In addition, to run it in Intellij I need to add run options:
--add-reads
org.eclipse.jnosql.communication.document=weld.core.impl
--add-reads
org.eclipse.jnosql.communication.document=weld.api
I will check it, but it is not in the core, but in the reflection module.
Caused by: java.lang.module.InvalidModuleDescriptorException: Provider class org.eclipse.jnosql.mapping.reflection.collection.DequeSupplier not in JAR file jnosql-mapping-core-1.0.4-SNAPSHOT.jar
at java.base/jdk.internal.module.ModulePath.deriveModuleDescriptor(ModulePath.java:555)
at java.base/jdk.internal.module.ModulePath.readJar(ModulePath.java:644)
... 54 more
@m4ttek could you check it in the newest version, 1.1.0 I believe that we fixed this point on this version.
@otaviojava ok, I'll try to check it, but I'll need to refactor some code as I resigned from JPMS due to these problems
I've checked bumping jnosql-arangodb
to 1.1.0 in one of my projects and it work great, but I had to change imports for Page
and Pageable
interfaces ;)
I've checked bumping
jnosql-arangodb
to 1.1.0 in one of my projects and it work great, but I had to change imports forPage
andPageable
interfaces ;)
It happens because Jakarta Data broke the contract. Thanks. I will update this ticket to close.
Which JNoSQL project the issue refers to?
JNoSQL (Core)
Bug description
It seems like the problem is caused by packages that are not unique in libraries dedicated to mapping. Automatic modules should be working without any hassle, but conflicts in packages create problems.
What may fix it is that you should either add module-info to your libraries or restructure packages to be consistent with JPMS requirements. For example mapping-api-core should have classes within
org.eclipse.jnosql.mapping.api
package.JNoSQL Version
1.0.2
Steps To Reproduce
Expected Results
No response
Code example, screenshot, or link to a repository
No response