Java security exception during code generation with custom cartridges on 3.1.0

1,214 views
Skip to first unread message

Kirill Alexandrovsky

unread,
Apr 12, 2015, 5:09:38 AM4/12/15
to sculptor...@googlegroups.com

Hi

I have a problem with latest 3.1.0 release.

I have two custom cartridges that worked flawlessly on 3.0.6 and on 3.1.0-SNAPSHOT - Optaplanner cartridge and JAX-RS + Swagger integration.
After switching to the latest version I get this error during code generation of main project (Business Tier):
[ERROR] Failed to execute goal org.sculptorgenerator:sculptor-maven-plugin:3.1.0:generate (code-generation) on project helloworld: Execution code-generation of goal org.sculptorgenerator:sculptor-maven-plugin:3.1.0:generate failed: class "org.eclipse.core.runtime.OperationCanceledException"'s signer information does not match signer information of other classes in the same package -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.sculptorgenerator:sculptor-maven-plugin:3.1.0:generate (code-generation) on project helloworld: Execution code-generation of goal org.sculptorgenerator:sculptor-maven-plugin:3.1.0:generate failed: class "org.eclipse.core.runtime.OperationCanceledException"'
s signer information does not match signer information of other classes in the same package
    at org
.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
    at org
.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
    at org
.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
    at org
.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
    at org
.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
    at org
.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
    at org
.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
    at org
.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
    at org
.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
    at org
.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
    at org
.apache.maven.cli.MavenCli.execute(MavenCli.java:862)
    at org
.apache.maven.cli.MavenCli.doMain(MavenCli.java:286)
    at org
.apache.maven.cli.MavenCli.main(MavenCli.java:197)
    at sun
.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun
.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun
.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java
.lang.reflect.Method.invoke(Method.java:497)
    at org
.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
    at org
.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
    at org
.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
    at org
.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution code-generation of goal org.sculptorgenerator:sculptor-maven-plugin:3.1.0:generate failed: class "org.eclipse.core.runtime.OperationCanceledException"'s signer information does not match signer information of other classes in the same package
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:145)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
    ... 20 more
Caused by: java.lang.SecurityException: class "org.eclipse.core.runtime.OperationCanceledException"'
s signer information does not match signer information of other classes in the same package
    at java
.lang.ClassLoader.checkCerts(ClassLoader.java:895)
    at java
.lang.ClassLoader.preDefineClass(ClassLoader.java:665)
    at java
.lang.ClassLoader.defineClass(ClassLoader.java:758)
    at java
.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
    at java
.net.URLClassLoader.defineClass(URLClassLoader.java:467)
    at java
.net.URLClassLoader.access$100(URLClassLoader.java:73)
    at java
.net.URLClassLoader$1.run(URLClassLoader.java:368)
    at java
.net.URLClassLoader$1.run(URLClassLoader.java:362)
    at java
.security.AccessController.doPrivileged(Native Method)
    at java
.net.URLClassLoader.findClass(URLClassLoader.java:361)
    at org
.codehaus.plexus.classworlds.realm.ClassRealm.loadClassFromSelf(ClassRealm.java:401)
    at org
.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:42)
    at org
.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271)
    at org
.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247)
    at org
.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239)
    at java
.lang.Class.getDeclaredConstructors0(Native Method)
    at java
.lang.Class.privateGetDeclaredConstructors(Class.java:2671)
    at java
.lang.Class.getDeclaredConstructors(Class.java:2020)
    at com
.google.inject.spi.InjectionPoint.forConstructorOf(InjectionPoint.java:243)
    at com
.google.inject.internal.ConstructorBindingImpl.create(ConstructorBindingImpl.java:96)
    at com
.google.inject.internal.InjectorImpl.createUninitializedBinding(InjectorImpl.java:629)
    at com
.google.inject.internal.InjectorImpl.createJustInTimeBinding(InjectorImpl.java:845)
    at com
.google.inject.internal.InjectorImpl.createJustInTimeBindingRecursive(InjectorImpl.java:772)
    at com
.google.inject.internal.InjectorImpl.getJustInTimeBinding(InjectorImpl.java:256)
    at com
.google.inject.internal.InjectorImpl.getBindingOrThrow(InjectorImpl.java:205)
    at com
.google.inject.internal.InjectorImpl.getInternalFactory(InjectorImpl.java:853)
    at com
.google.inject.internal.FactoryProxy.notify(FactoryProxy.java:46)
    at com
.google.inject.internal.ProcessedBindingData.runCreationListeners(ProcessedBindingData.java:50)
    at com
.google.inject.internal.InternalInjectorCreator.initializeStatically(InternalInjectorCreator.java:133)
    at com
.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:106)
    at com
.google.inject.Guice.createInjector(Guice.java:95)
    at com
.google.inject.Guice.createInjector(Guice.java:72)
    at com
.google.inject.Guice.createInjector(Guice.java:62)
    at org
.eclipse.xtext.common.TerminalsStandaloneSetupGenerated.createInjector(TerminalsStandaloneSetupGenerated.java:40)
    at org
.eclipse.xtext.common.TerminalsStandaloneSetupGenerated.createInjectorAndDoEMFRegistration(TerminalsStandaloneSetupGenerated.java:34)
    at org
.eclipse.xtext.common.TerminalsStandaloneSetup.doSetup(TerminalsStandaloneSetup.java:11)
    at org
.sculptor.dsl.SculptordslStandaloneSetupGenerated.createInjectorAndDoEMFRegistration(SculptordslStandaloneSetupGenerated.java:21)
    at org
.sculptor.generator.SculptorGeneratorRunner.run(SculptorGeneratorRunner.java:44)
    at org
.sculptor.maven.plugin.GeneratorMojo.doRunGenerator(GeneratorMojo.java:474)
    at org
.sculptor.maven.plugin.GeneratorMojo.executeGenerator(GeneratorMojo.java:439)
    at org
.sculptor.maven.plugin.GeneratorMojo.execute(GeneratorMojo.java:223)
    at org
.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
   
... 21 more

I have updated project's pom.xml (parent and main project) according to the new projects generated with archetypes. I've cleaned everything sculptor- and eclipse-related from local maven repo, I've also tried to build sculptor itself on the same machine, but none of this helped.

Can you tell what I am missing? And where to start with this problem.

Thank you

Torsten Juergeleit

unread,
Apr 12, 2015, 3:20:04 PM4/12/15
to sculptor...@googlegroups.com
The issue "java.lang.SecurityException: signer information does not match signer information of other classes in the same package" is due to classes from within the same package are loaded from different jars signed with different certificates. The offending package "org.eclipse.core.runtime" is shipped within "sculptor-generator-3.x.y.library.jar" which is signed with my GPG certificate during release build.

It seems that within your projects POM the class path of the Sculptor Maven plugin contains other (transitive) dependencies which are shipping the package "org.eclipse.core.runtime" as well. Please check the dependencies of the Sculptor plugin via "mvn dependency:resolve-plugins -DincludeArtifactIds=sculptor-maven-plugin".

And check your cartridges via "mvn dependency:tree" as well. Make sure that you're using Sculptors generator library and the Xtext/Xtend libraries with the corresponding versions (3.1.0 and 2.8.1), e.g.

<dependencies>

<dependency>

<groupId>org.sculptorgenerator</groupId>

<artifactId>sculptor-generator-library</artifactId>

<version>${sculptor.version}</version>

</dependency>

<dependency>

<groupId>org.eclipse.xtext</groupId>

<artifactId>org.eclipse.xtext.xtext</artifactId>

<version>${xtext.version}</version>

</dependency>

<dependency>

<groupId>org.eclipse.xtend</groupId>

<artifactId>org.eclipse.xtend.lib</artifactId>

<version>${xtext.version}</version>

</dependency>

<dependency>

<groupId>org.sculptorgenerator</groupId>

<artifactId>sculptor-generator-test</artifactId>

<version>${sculptor.version}</version>

<scope>test</scope>

</dependency>

</dependencies>


Btw. the order of the dependencies is important. The Sculptor library has to come first because it's defined this way in the plugins internal classpath. 

/Torsten
...

Kirill Alexandrovsky

unread,
Apr 13, 2015, 3:09:56 PM4/13/15
to sculptor...@googlegroups.com
Main project's dependencies seem to be OK
[INFO] --- maven-dependency-plugin:2.8:resolve-plugins (default-cli) @ helloworld ---
[INFO] Plugin Resolved: sculptor-maven-plugin-3.1.0.jar
[INFO]     Plugin Dependency Resolved: sculptor-generator-library-3.1.0.jar
[INFO]     Plugin Dependency Resolved: sculptor-cartridge-builder-3.1.0.jar
[INFO]     Plugin Dependency Resolved: sculptor-cartridge-mongodb-3.1.0.jar
[INFO]     Plugin Dependency Resolved: sculptor-cartridge-springdatajpa-3.1.0.jar
[INFO]     Plugin Dependency Resolved: maven-plugin-api-3.0.3.jar
[INFO]     Plugin Dependency Resolved: maven-core-3.0.3.jar
[INFO]     Plugin Dependency Resolved: maven-compat-3.0.3.jar
[INFO]     Plugin Dependency Resolved: plexus-interpolation-1.16.jar
[INFO]     Plugin Dependency Resolved: plexus-build-api-0.0.7.jar
[INFO]     Plugin Dependency Resolved: commons-exec-1.3.jar
[INFO]     Plugin Dependency Resolved: commons-io-2.4.jar
[INFO]     Plugin Dependency Resolved: commons-codec-1.10.jar

These are the same dependencies that are shown in newly created project.

The strange thing is that this list doesn't include my cartridge. But it is defined as a dependency in pom.xml:
                <groupId>org.sculptorgenerator</groupId>
               
<artifactId>sculptor-maven-plugin</artifactId>
               
<version>${sculptor-version}</version>
                  ...
               
<dependencies>
                   
<dependency>
                       
<groupId>org.sculptorgenerator</groupId>
                       
<artifactId>sculptor-cartridge-optaplanner</artifactId>
                       
<version>1.0-SNAPSHOT</version>
                   
</dependency>
                </dependencies>
     ...

    <dependencies>
        <dependency>
            <groupId>org.sculptorgenerator</groupId>
            <artifactId>sculptor-cartridge-optaplanner</artifactId>
            <version>1.0-SNAPSHOT</version>
            <scope>provided</scope>
        </dependency>  


Cartridge's pom.xml is pretty much the same as ones from other cartridges. Actually it's just a copy-paste of builder cartridge:
<?xml version="1.0" encoding="UTF-8" ?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.sculptorgenerator</groupId>
    <artifactId>sculptor-cartridge-optaplanner</artifactId>
    <version>1.0-SNAPSHOT</version>
    <name>Sculptor :: Cartridges :: Optaplanner</name>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

        <xtext-version>2.8.1</xtext-version>
        <sculptor-version>3.1.0</sculptor-version>
    </properties>

    <build>
        <plugins>
            <plugin>
                <artifactId>maven-clean-plugin</artifactId>
                <version>2.5</version>
                <configuration>
                    <filesets>
                        <fileset>
                            <directory>${basedir}/src/main/xtend-gen</directory>
                            <excludes>
                                <exclude>.gitignore</exclude>
                            </excludes>
                        </fileset>
                        <fileset>
                            <directory>${basedir}/src/test/xtend-gen</directory>
                            <excludes>
                                <exclude>.gitignore</exclude>
                            </excludes>
                        </fileset>
                    </filesets>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.eclipse.xtend</groupId>
                <artifactId>xtend-maven-plugin</artifactId>
                <version>${xtext-version}</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>compile</goal>
                            <goal>testCompile</goal>
                        </goals>
                        <configuration>
                            <outputDirectory>${basedir}/src/main/xtend-gen</outputDirectory>
                            <testOutputDirectory>${basedir}/src/test/xtend-gen</testOutputDirectory>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>2.12.4</version>
                <configuration>
                    <!-- Due to our use of system properties we have to run every test class in a newly forked JVM -->
                    <reuseForks>false</reuseForks>
                </configuration>
            </plugin>
        </plugins>
    </build>


    <dependencies>
        <dependency>
            <groupId>org.sculptorgenerator</groupId>
            <artifactId>sculptor-generator-library</artifactId>
            <version>${sculptor-version}</version>

        </dependency>
        <dependency>
            <groupId>org.eclipse.xtext</groupId>
            <artifactId>org.eclipse.xtext.xtext</artifactId>
            <version>${xtext-version}</version>

        </dependency>
        <dependency>
            <groupId>org.eclipse.xtend</groupId>
            <artifactId>org.eclipse.xtend.lib</artifactId>
            <version>${xtext-version}</version>

        </dependency>
        <dependency>
            <groupId>org.sculptorgenerator</groupId>
            <artifactId>sculptor-generator-test-library</artifactId>
            <version>${sculptor-version}</version>

            <scope>test</scope>
        </dependency>
    </dependencies>

</project>

dependency:tree for the cartridge looks the same as for builder cartridge.

The only thing I don't get is why everything worked for 3.0.6. Is there some additional rules for cartridge buiding? (apart from source code requirements - correct pacakage for classes, naming convention, etc)

Thank you

Torsten Juergeleit

unread,
Apr 13, 2015, 4:25:10 PM4/13/15
to sculptor...@googlegroups.com
Ok, I'm able to reproduce this issue by using the same dependencies (as within the cartridges) in the mongoDb shipping example (the module "sculptor-shipping-generator").
Here with "mvn install -X" (unluckily "mvn dependency:resolve-plugins" only lists the dependencies specified in the plugins POM - without any transitive dependencies) shows the following dependency hierarchy of Sculptors Maven plugin:

[DEBUG] org.sculptorgenerator:sculptor-maven-plugin:jar:3.1.1-SNAPSHOT:
[DEBUG]    org.sculptorgenerator.examples.mongodb-samples:sculptor-shipping-generator:jar:3.1.1-SNAPSHOT:runtime
[DEBUG]       org.eclipse.xtext:org.eclipse.xtext.xtext:jar:2.8.1:compile
[DEBUG]          org.eclipse.xtext:org.eclipse.xtext.util:jar:2.8.1:compile
[DEBUG]             com.google.guava:guava:jar:14.0:compile
[DEBUG]             org.eclipse.xtext:org.eclipse.xtext.dependencies:pom:2.8.1:compile
[DEBUG]                org.eclipse.tycho:org.eclipse.jdt.core:jar:3.10.0.v20140604-1726:compile
[DEBUG]          org.eclipse.xtext:org.eclipse.xtext:jar:2.8.1:compile
[DEBUG]             org.antlr:antlr-runtime:jar:3.2:compile
[DEBUG]          org.eclipse.xtext:org.eclipse.xtext.common.types:jar:2.8.1:compile
[DEBUG]             org.eclipse.emf:org.eclipse.emf.codegen:jar:2.10.0-v20150123-0452:runtime
[DEBUG]             org.ow2.asm:asm-commons:jar:5.0.1:compile
[DEBUG]                org.ow2.asm:asm-tree:jar:5.0.1:compile
[DEBUG]                   org.ow2.asm:asm:jar:5.0.1:compile
[DEBUG]          org.eclipse.emf:org.eclipse.emf.ecore:jar:2.11.0-v20150123-0347:compile
[DEBUG]          org.eclipse.emf:org.eclipse.emf.common:jar:2.11.0-v20150123-0347:compile
[DEBUG]          org.eclipse.emf:org.eclipse.emf.ecore.xmi:jar:2.11.0-v20150123-0347:compile
[DEBUG]          org.eclipse.emf:org.eclipse.emf.codegen.ecore:jar:2.11.0-v20150123-0357:compile
[DEBUG]          com.ibm.icu:icu4j:jar:52.1:compile
[DEBUG]          com.google.inject:guice:jar:3.0:compile
[DEBUG]             javax.inject:javax.inject:jar:1:compile
[DEBUG]             aopalliance:aopalliance:jar:1.0:compile
[DEBUG]          commons-cli:commons-cli:jar:1.2:compile
[DEBUG]          org.eclipse.xtext:xtext-antlr-generator:jar:2.1.1:compile
[DEBUG]             org.xtext:antlr-generator:jar:3.2.1:compile
[DEBUG]          org.eclipse.equinox:org.eclipse.equinox.common:jar:3.6.0.v20100503:compile
[DEBUG]             org.eclipse.osgi:org.eclipse.osgi:jar:3.6.0.v20100517:compile
[DEBUG]       org.eclipse.xtend:org.eclipse.xtend.lib:jar:2.8.1:compile
[DEBUG]          org.eclipse.xtext:org.eclipse.xtext.xbase.lib:jar:2.8.1:compile
[DEBUG]          org.eclipse.xtend:org.eclipse.xtend.lib.macro:jar:2.8.1:compile
[DEBUG]    org.sculptorgenerator:sculptor-generator-library:jar:3.1.1-SNAPSHOT:compile
[DEBUG]       ch.qos.logback:logback-classic:jar:1.1.3:compile
[DEBUG]          ch.qos.logback:logback-core:jar:1.1.3:compile
[DEBUG]          org.slf4j:slf4j-api:jar:1.7.12:compile
[DEBUG]       org.slf4j:log4j-over-slf4j:jar:1.7.12:compile
[DEBUG]       org.slf4j:jcl-over-slf4j:jar:1.7.12:compile
[DEBUG]    org.sculptorgenerator:sculptor-cartridge-builder:jar:3.1.1-SNAPSHOT:compile
[DEBUG]    org.sculptorgenerator:sculptor-cartridge-mongodb:jar:3.1.1-SNAPSHOT:compile
[DEBUG]    org.sculptorgenerator:sculptor-cartridge-springdatajpa:jar:3.1.1-SNAPSHOT:compile
[DEBUG]    org.apache.maven:maven-plugin-api:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-model:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-artifact:jar:3.0.3:compile
[DEBUG]       org.sonatype.sisu:sisu-inject-plexus:jar:2.1.1:compile
[DEBUG]          org.sonatype.sisu:sisu-inject-bean:jar:2.1.1:compile
[DEBUG]             org.sonatype.sisu:sisu-guice:jar:no_aop:2.9.4:compile
[DEBUG]    org.apache.maven:maven-core:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-settings:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-settings-builder:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-repository-metadata:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-model-builder:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-aether-provider:jar:3.0.3:compile
[DEBUG]          org.sonatype.aether:aether-spi:jar:1.11:compile
[DEBUG]       org.sonatype.aether:aether-impl:jar:1.11:compile
[DEBUG]       org.sonatype.aether:aether-api:jar:1.11:compile
[DEBUG]       org.sonatype.aether:aether-util:jar:1.11:compile
[DEBUG]       org.codehaus.plexus:plexus-utils:jar:2.0.6:compile
[DEBUG]       org.codehaus.plexus:plexus-classworlds:jar:2.4:compile
[DEBUG]       org.codehaus.plexus:plexus-component-annotations:jar:1.5.5:compile
[DEBUG]       org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3:compile
[DEBUG]          org.sonatype.plexus:plexus-cipher:jar:1.4:compile
[DEBUG]    org.apache.maven:maven-compat:jar:3.0.3:compile
[DEBUG]       org.apache.maven.wagon:wagon-provider-api:jar:1.0-beta-7:compile
[DEBUG]    org.codehaus.plexus:plexus-interpolation:jar:1.16:compile
[DEBUG]    org.sonatype.plexus:plexus-build-api:jar:0.0.7:compile
[DEBUG]    org.apache.commons:commons-exec:jar:1.3:compile
[DEBUG]    commons-io:commons-io:jar:2.4:compile
[DEBUG]    commons-codec:commons-codec:jar:1.10:compile

Here the Xtext/Xtend dependencies (which are signed with a different certificate) are placed in front of the Sculptor library.
So the culprit are the redundant Xtext/Xtend dependencies in the cartridges:

<dependency>

<groupId>org.eclipse.xtext</groupId>

<artifactId>org.eclipse.xtext.xtext</artifactId>

</dependency>

<dependency>

<groupId>org.eclipse.xtend</groupId>

<artifactId>org.eclipse.xtend.lib</artifactId>

</dependency>


These must be removed from with the cartridges list of dependencies because they're transitive dependencies of Sculptors generator library.

The dependency hierarchy of Sculptors Maven plugin in original mongoDb shipping example (without the redundant Xtext/Xtend dependencies) looks as follows:

[DEBUG] org.sculptorgenerator:sculptor-maven-plugin:jar:3.1.1-SNAPSHOT:
[DEBUG]    org.sculptorgenerator.examples.mongodb-samples:sculptor-shipping-generator:jar:3.1.1-SNAPSHOT:runtime
[DEBUG]    org.sculptorgenerator:sculptor-generator-library:jar:3.1.1-SNAPSHOT:compile
[DEBUG]       org.eclipse.xtext:org.eclipse.xtext.xtext:jar:2.8.1:compile
[DEBUG]          org.eclipse.xtext:org.eclipse.xtext.util:jar:2.8.1:compile
[DEBUG]             com.google.guava:guava:jar:14.0:compile
[DEBUG]             org.eclipse.xtext:org.eclipse.xtext.dependencies:pom:2.8.1:compile
[DEBUG]                org.eclipse.tycho:org.eclipse.jdt.core:jar:3.10.0.v20140604-1726:compile
[DEBUG]          org.eclipse.xtext:org.eclipse.xtext:jar:2.8.1:compile
[DEBUG]             org.antlr:antlr-runtime:jar:3.2:compile
[DEBUG]          org.eclipse.xtext:org.eclipse.xtext.common.types:jar:2.8.1:compile
[DEBUG]             org.eclipse.emf:org.eclipse.emf.codegen:jar:2.10.0-v20150123-0452:runtime
[DEBUG]             org.ow2.asm:asm-commons:jar:5.0.1:compile
[DEBUG]                org.ow2.asm:asm-tree:jar:5.0.1:compile
[DEBUG]                   org.ow2.asm:asm:jar:5.0.1:compile
[DEBUG]          org.eclipse.emf:org.eclipse.emf.ecore:jar:2.11.0-v20150123-0347:compile
[DEBUG]          org.eclipse.emf:org.eclipse.emf.common:jar:2.11.0-v20150123-0347:compile
[DEBUG]          org.eclipse.emf:org.eclipse.emf.ecore.xmi:jar:2.11.0-v20150123-0347:compile
[DEBUG]          org.eclipse.emf:org.eclipse.emf.codegen.ecore:jar:2.11.0-v20150123-0357:compile
[DEBUG]          com.ibm.icu:icu4j:jar:52.1:compile
[DEBUG]          com.google.inject:guice:jar:3.0:compile
[DEBUG]             javax.inject:javax.inject:jar:1:compile
[DEBUG]             aopalliance:aopalliance:jar:1.0:compile
[DEBUG]          commons-cli:commons-cli:jar:1.2:compile
[DEBUG]          org.eclipse.xtext:xtext-antlr-generator:jar:2.1.1:compile
[DEBUG]             org.xtext:antlr-generator:jar:3.2.1:compile
[DEBUG]          org.eclipse.equinox:org.eclipse.equinox.common:jar:3.6.0.v20100503:compile
[DEBUG]             org.eclipse.osgi:org.eclipse.osgi:jar:3.6.0.v20100517:compile
[DEBUG]       org.eclipse.xtend:org.eclipse.xtend.lib:jar:2.8.1:compile
[DEBUG]          org.eclipse.xtext:org.eclipse.xtext.xbase.lib:jar:2.8.1:compile
[DEBUG]          org.eclipse.xtend:org.eclipse.xtend.lib.macro:jar:2.8.1:compile
[DEBUG]       ch.qos.logback:logback-classic:jar:1.1.3:compile
[DEBUG]          ch.qos.logback:logback-core:jar:1.1.3:compile
[DEBUG]          org.slf4j:slf4j-api:jar:1.7.12:compile
[DEBUG]       org.slf4j:log4j-over-slf4j:jar:1.7.12:compile
[DEBUG]       org.slf4j:jcl-over-slf4j:jar:1.7.12:compile
[DEBUG]    org.sculptorgenerator:sculptor-cartridge-builder:jar:3.1.1-SNAPSHOT:compile
[DEBUG]    org.sculptorgenerator:sculptor-cartridge-mongodb:jar:3.1.1-SNAPSHOT:compile
[DEBUG]    org.sculptorgenerator:sculptor-cartridge-springdatajpa:jar:3.1.1-SNAPSHOT:compile
[DEBUG]    org.apache.maven:maven-plugin-api:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-model:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-artifact:jar:3.0.3:compile
[DEBUG]       org.sonatype.sisu:sisu-inject-plexus:jar:2.1.1:compile
[DEBUG]          org.sonatype.sisu:sisu-inject-bean:jar:2.1.1:compile
[DEBUG]             org.sonatype.sisu:sisu-guice:jar:no_aop:2.9.4:compile
[DEBUG]    org.apache.maven:maven-core:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-settings:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-settings-builder:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-repository-metadata:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-model-builder:jar:3.0.3:compile
[DEBUG]       org.apache.maven:maven-aether-provider:jar:3.0.3:compile
[DEBUG]          org.sonatype.aether:aether-spi:jar:1.11:compile
[DEBUG]       org.sonatype.aether:aether-impl:jar:1.11:compile
[DEBUG]       org.sonatype.aether:aether-api:jar:1.11:compile
[DEBUG]       org.sonatype.aether:aether-util:jar:1.11:compile
[DEBUG]       org.codehaus.plexus:plexus-utils:jar:2.0.6:compile
[DEBUG]       org.codehaus.plexus:plexus-classworlds:jar:2.4:compile
[DEBUG]       org.codehaus.plexus:plexus-component-annotations:jar:1.5.5:compile
[DEBUG]       org.sonatype.plexus:plexus-sec-dispatcher:jar:1.3:compile
[DEBUG]          org.sonatype.plexus:plexus-cipher:jar:1.4:compile
[DEBUG]    org.apache.maven:maven-compat:jar:3.0.3:compile
[DEBUG]       org.apache.maven.wagon:wagon-provider-api:jar:1.0-beta-7:compile
[DEBUG]    org.codehaus.plexus:plexus-interpolation:jar:1.16:compile
[DEBUG]    org.sonatype.plexus:plexus-build-api:jar:0.0.7:compile
[DEBUG]    org.apache.commons:commons-exec:jar:1.3:compile
[DEBUG]    commons-io:commons-io:jar:2.4:compile
[DEBUG]    commons-codec:commons-codec:jar:1.10:compile


With Sculptor 3.0.6 this issue didn't appear because these Xtext/Xtend had a different scope ("runtime" instead of "compile") in Sculptors generator library. Due to the runtime scope these dependencies have been placed on the plugins class path after Sculptors generator library.

/Torsten

Kirill Alexandrovsky

unread,
Apr 13, 2015, 5:27:26 PM4/13/15
to sculptor...@googlegroups.com
Great, after removing dependencies everything is working like a charm.

I guess everything is okay for built-in cartridges because correct dependency order is already defined by parent projects.

So my problem resolved, thank you a lot. Sculptor rocks.

P.S. I've got the last question about cartridges themselves. They should be shared with community, but what is the procedure to do so (maybe github pull request or just making separate repositories)?
Although right now they are not ready for production, not covered with tests, and maybe messing with internal code that is not intended to be messed with. Maybe you can make some list of requirements for them?

Torsten Juergeleit

unread,
Apr 14, 2015, 6:14:18 AM4/14/15
to sculptor...@googlegroups.com
Glad this issue is solved. The redundant dependencies are removed from the cartridges POMs beginning with Sculptor 3.1.1.

Yes, for the internal cartridges the class path is defined within the Sculptor Maven plugins POM (generator library first and then the cartridges).

Your question regarding a way to share Sculptor cartridges is a good one. We should discuss this in a separate thread.
May I ask you to start a new thread with this question?

/Torsten
Reply all
Reply to author
Forward
0 new messages