Hi,
Thanks for the quick responses! I've tried some of the things you suggested.
1. Tried the example, and got a successful build. However, still get the,
apparently , message "Cannot find CatalogManager.properties"
2. I've found that my problem is not having the xsd in place
src/main/resources. However, the result of not having the xsd in place is
the original error which seems to result in a bad Java command line. Perhaps
the plugin should report that it couldn't find any xsd to compile?
Here is the result of having a missing xsd in the example application:
+ Error stacktraces are turned on.
Maven version: 2.0.9
Java version: 1.5.0_19
OS name: "mac os x" version: "10.5.7" arch: "i386" Family: "unix"
[DEBUG] Building Maven user-level plugin registry from:
'/Users/ben/.m2/plugin-registry.xml'
[DEBUG] Building Maven global-level plugin registry from:
'/Users/ben/tools/apache-maven-2.0.9/conf/plugin-registry.xml'
[INFO] Scanning for projects...
[INFO]
------------------------------------------------------------------------
[INFO] Building Maven JAXB 2.x Plugin Sample [po|maven]
[INFO] task-segment: [clean, install]
[INFO]
------------------------------------------------------------------------
[DEBUG] Retrieving parent-POM: org.apache.maven.plugins:maven-plugins::10
for project: null:maven-clean-plugin:maven-plugin:2.2 from the repository.
[DEBUG] Retrieving parent-POM: org.apache.maven:maven-parent::7 for project:
org.apache.maven.plugins:maven-plugins:pom:10 from the repository.
[DEBUG] Retrieving parent-POM: org.apache:apache::4 for project:
org.apache.maven:maven-parent:pom:7 from the repository.
[DEBUG] Retrieving parent-POM:
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-project::0.7.1 for project:
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin:maven-plugin:null from the
repository.
[DEBUG] Adding managed dependencies for
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin
[DEBUG] org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-raw:jar:0.7.1
[DEBUG] org.jvnet.jaxb2.maven2:maven-jaxb2-plugin:jar:0.7.1
[DEBUG] org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-testing:jar:0.7.1
[DEBUG] org.jfrog.maven.annomojo:maven-plugin-anno:jar:1.3.1
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.0.4
[DEBUG] org.apache.maven:maven-project:jar:2.0.4
[DEBUG] org.apache.maven.shared:maven-plugin-testing-harness:jar:1.1
[DEBUG] com.sun.xml.bind:jaxb-impl:jar:2.1.10
[DEBUG] javax.xml.bind:jaxb-api:jar:2.1
[DEBUG] org.jvnet.jaxb2_commons:jaxb-xjc:jar:2.1.10
[DEBUG] junit:junit:jar:3.8.1
[DEBUG] commons-logging:commons-logging:jar:1.1.1
[DEBUG] log4j:log4j:jar:1.2.13
[DEBUG] Retrieving parent-POM: org.apache.maven.plugins:maven-plugins::8 for
project: null:maven-compiler-plugin:maven-plugin:2.0.2 from the repository.
[DEBUG] Retrieving parent-POM: org.apache.maven:maven-parent::5 for project:
org.apache.maven.plugins:maven-plugins:pom:8 from the repository.
[DEBUG] Retrieving parent-POM: org.apache:apache::3 for project:
org.apache.maven:maven-parent:pom:5 from the repository.
[DEBUG] Plugin dependencies for:
org.apache.maven.plugins:maven-clean-plugin:2.2
are:
org.apache.maven:maven-project:jar:2.0:runtime
org.apache.maven:maven-plugin-api:jar:2.0:runtime
org.apache.maven.shared:file-management:jar:1.2:runtime
org.codehaus.plexus:plexus-utils:jar:1.1:runtime
[DEBUG] org.apache.maven.plugins:maven-clean-plugin:maven-plugin:2.2:runtime
(selected for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0 for project:
null:maven-project:jar:2.0 from the repository.
[DEBUG] Adding managed dependencies for unknown:maven-project
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5
[DEBUG] org.apache.maven:maven-project:jar:2.0:runtime (selected for
runtime)
[DEBUG] Adding managed dependencies for unknown:maven-profile
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5
[DEBUG] org.apache.maven:maven-profile:jar:2.0:runtime (selected for
runtime)
[DEBUG] Adding managed dependencies for org.apache.maven:maven-model
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5
[DEBUG] org.apache.maven:maven-model:jar:2.0:runtime (selected for
runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime (selected
for runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime (selected
for runtime)
[DEBUG]
org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8:runtime
(selected for runtime)
[DEBUG] junit:junit:jar:3.8.1:runtime (selected for runtime)
[DEBUG] classworlds:classworlds:jar:1.1-alpha-2:runtime (selected
for runtime)
[DEBUG] org.apache.maven:maven-model:jar:2.0:runtime (selected for
runtime)
[DEBUG] Adding managed dependencies for
org.apache.maven:maven-artifact-manager
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5
[DEBUG] org.apache.maven:maven-artifact-manager:jar:2.0:runtime
(selected for runtime)
[DEBUG] Adding managed dependencies for
org.apache.maven:maven-repository-metadata
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5
[DEBUG] org.apache.maven:maven-repository-metadata:jar:2.0:runtime
(selected for runtime)
[DEBUG] Adding managed dependencies for org.apache.maven:maven-artifact
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5
[DEBUG] org.apache.maven:maven-artifact:jar:2.0:runtime (selected for
runtime)
[DEBUG]
org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5:runtime (selected
for runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime (selected for
runtime)
[DEBUG] org.apache.maven:maven-artifact:jar:2.0:runtime (selected for
runtime)
[DEBUG]
org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8:runtime
(selected for runtime)
[DEBUG] junit:junit:jar:3.8.1:runtime (selected for runtime)
[DEBUG] classworlds:classworlds:jar:1.1-alpha-2:runtime (selected for
runtime)
[DEBUG] Adding managed dependencies for org.apache.maven:maven-plugin-api
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-5
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-5
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.0:runtime (selected for
runtime)
[DEBUG] Retrieving parent-POM:
org.apache.maven.shared:maven-shared-components::8 for project:
null:file-management:jar:1.2 from the repository.
[DEBUG] org.apache.maven.shared:file-management:jar:1.2:runtime (selected
for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0.6 for project:
null:maven-plugin-api:jar:null from the repository.
[DEBUG] Adding managed dependencies for unknown:maven-plugin-api
[DEBUG] org.apache.maven:maven-model:jar:2.0.6
[DEBUG] org.apache.maven:maven-project:jar:2.0.6
[DEBUG] org.apache.maven.reporting:maven-reporting-api:jar:2.0.6
[DEBUG] org.apache.maven:maven-repository-metadata:jar:2.0.6
[DEBUG] org.apache.maven:maven-artifact:jar:2.0.6
[DEBUG] org.apache.maven:maven-artifact-manager:jar:2.0.6
[DEBUG] org.apache.maven:maven-artifact-test:jar:2.0.6
[DEBUG] org.apache.maven:maven-settings:jar:2.0.6
[DEBUG] org.apache.maven:maven-plugin-parameter-documenter:jar:2.0.6
[DEBUG] org.apache.maven:maven-profile:jar:2.0.6
[DEBUG] org.apache.maven:maven-plugin-registry:jar:2.0.6
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.0.6
[DEBUG] org.apache.maven:maven-monitor:jar:2.0.6
[DEBUG]
org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9-stable-1
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.4.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-beta-2
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-beta-2
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-beta-2
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-beta-2
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-beta-2
[DEBUG] easymock:easymock:jar:1.2_Java1.3:test
[DEBUG] classworlds:classworlds:jar:1.1
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.0.6:runtime (removed -
nearer found: 2.0)
[DEBUG] org.apache.maven.shared:maven-shared-io:jar:1.1:runtime
(selected for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0.2 for project:
org.apache.maven:maven-artifact:jar:2.0.2 from the repository.
[DEBUG] Adding managed dependencies for org.apache.maven:maven-artifact
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-artifact:jar:2.0.2:runtime (removed -
nearer found: 2.0)
[DEBUG] Adding managed dependencies for
org.apache.maven:maven-artifact-manager
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-artifact-manager:jar:2.0.2:runtime
(removed - nearer found: 2.0)
[DEBUG] Retrieving parent-POM: org.apache.maven.wagon:wagon::1.0-alpha-6 for
project: null:wagon-provider-api:jar:1.0-alpha-6 from the repository.
[DEBUG] Adding managed dependencies for unknown:wagon-provider-api
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-provider-test:jar:1.0-alpha-6
[DEBUG] junit:junit:jar:3.8.1
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-8
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4
[DEBUG]
org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6:runtime (removed -
nearer found: 1.0-alpha-5)
[DEBUG] Retrieving parent-POM: org.codehaus.plexus:plexus::1.0.11 for
project: null:plexus-utils:jar:1.4.6 from the repository.
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.4.6:runtime (removed -
nearer found: 1.0.4)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.4.6:runtime (removed -
nearer found: 1.0.4)
[DEBUG] Retrieving parent-POM: org.codehaus.plexus:plexus-containers::1.0.3
for project: null:plexus-container-default:jar:1.0-alpha-9 from the
repository.
[DEBUG] Retrieving parent-POM: org.codehaus.plexus:plexus::1.0.4 for
project: org.codehaus.plexus:plexus-containers:pom:1.0.3 from the
repository.
[DEBUG]
org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9:runtime
(removed - nearer found: 1.0-alpha-8)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime (removed -
nearer found: 1.1)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1:runtime (selected for
runtime)
[DEBUG] The following artifacts were filtered out for plugin:
org.apache.maven.plugins:maven-clean-plugin:2.2 because they're already in
the core of Maven:
org.apache.maven:maven-project:jar:2.0:runtime
org.apache.maven:maven-plugin-api:jar:2.0:runtime
These will use the artifact files already in the core ClassRealm instead, to
allow them to be included in PluginDescriptor.getArtifacts().
[DEBUG] Configuring mojo
'org.apache.maven.plugins:maven-clean-plugin:2.2:clean' -->
[DEBUG] (f) directory = /code/maven-jaxb2-plugin-sample-po-0.7.1/target
[DEBUG] (f) failOnError = true
[DEBUG] (f) followSymLinks = false
[DEBUG] (f) outputDirectory =
/code/maven-jaxb2-plugin-sample-po-0.7.1/target/classes
[DEBUG] (f) project = MavenProject:
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-sample-po-maven:0.7.1 @
/code/maven-jaxb2-plugin-sample-po-0.7.1/pom.xml
[DEBUG] (f) reportDirectory =
/code/maven-jaxb2-plugin-sample-po-0.7.1/target/site
[DEBUG] (f) skip = false
[DEBUG] (f) testOutputDirectory =
/code/maven-jaxb2-plugin-sample-po-0.7.1/target/test-classes
[DEBUG] (f) verbose = false
[DEBUG] -- end configuration --
[INFO] [clean:clean]
[INFO] Deleting directory /code/maven-jaxb2-plugin-sample-po-0.7.1/target
[DEBUG] Retrieving parent-POM: org.apache.maven.plugins:maven-plugins::1 for
project: null:maven-resources-plugin:maven-plugin:2.2 from the repository.
[DEBUG] Retrieving parent-POM: org.apache.maven:maven-parent::1 for project:
org.apache.maven.plugins:maven-plugins:pom:1 from the repository.
[DEBUG] Retrieving parent-POM: org.apache:apache::1 for project:
org.apache.maven:maven-parent:pom:1 from the repository.
[DEBUG] Retrieving parent-POM: org.apache.maven.surefire:surefire::2.4.2 for
project: org.apache.maven.plugins:maven-surefire-plugin:maven-plugin:null
from the repository.
[DEBUG] Adding managed dependencies for
org.apache.maven.plugins:maven-surefire-plugin
[DEBUG] org.apache.maven.surefire:surefire-api:jar:2.4.2
[DEBUG] org.apache.maven.surefire:surefire-booter:jar:2.4.2
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.4.9
[DEBUG] Plugin dependencies for:
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin:0.7.1
are:
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-raw:jar:0.7.1:runtime
com.sun.xml.bind:jaxb-impl:jar:2.1.10:runtime
org.jvnet.jaxb2_commons:jaxb-xjc:jar:2.1.10:runtime
org.codehaus.plexus:plexus-utils:jar:1.1:runtime
[DEBUG] org.jvnet.jaxb2.maven2:maven-jaxb2-plugin:maven-plugin:0.7.1:runtime
(selected for runtime)
[DEBUG] Adding managed dependencies for
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-raw
[DEBUG] org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-raw:jar:0.7.1
[DEBUG] org.jvnet.jaxb2.maven2:maven-jaxb2-plugin:jar:0.7.1
[DEBUG] org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-testing:jar:0.7.1
[DEBUG] org.jfrog.maven.annomojo:maven-plugin-anno:jar:1.3.1
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.0.4
[DEBUG] org.apache.maven:maven-project:jar:2.0.4
[DEBUG] org.apache.maven.shared:maven-plugin-testing-harness:jar:1.1
[DEBUG] com.sun.xml.bind:jaxb-impl:jar:2.1.10
[DEBUG] javax.xml.bind:jaxb-api:jar:2.1
[DEBUG] org.jvnet.jaxb2_commons:jaxb-xjc:jar:2.1.10
[DEBUG] junit:junit:jar:3.8.1
[DEBUG] commons-logging:commons-logging:jar:1.1.1
[DEBUG] log4j:log4j:jar:1.2.13
[DEBUG] org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-raw:jar:0.7.1:runtime
(selected for runtime)
[DEBUG] Retrieving parent-POM: org.apache.maven:maven::2.0.4 for project:
org.apache.maven:maven-plugin-api:jar:2.0.4 from the repository.
[DEBUG] Adding managed dependencies for org.apache.maven:maven-plugin-api
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-plugin-api:jar:2.0.4:runtime (selected
for runtime)
[DEBUG] Adding managed dependencies for unknown:maven-project
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-project:jar:2.0.4:runtime (selected for
runtime)
[DEBUG] Adding managed dependencies for unknown:maven-settings
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-settings:jar:2.0.4:runtime (selected
for runtime)
[DEBUG] Adding managed dependencies for org.apache.maven:maven-model
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-model:jar:2.0.4:runtime (selected for
runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1:runtime (selected
for runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1:runtime (selected
for runtime)
[DEBUG]
org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9:runtime
(selected for runtime)
[DEBUG] junit:junit:jar:3.8.1:runtime (selected for runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime
(removed - nearer found: 1.1)
[DEBUG] classworlds:classworlds:jar:1.1-alpha-2:runtime (selected
for runtime)
[DEBUG] Adding managed dependencies for unknown:maven-profile
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-profile:jar:2.0.4:runtime (selected for
runtime)
[DEBUG] org.apache.maven:maven-model:jar:2.0.4:runtime (selected for
runtime)
[DEBUG] Adding managed dependencies for
org.apache.maven:maven-artifact-manager
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-artifact-manager:jar:2.0.4:runtime
(selected for runtime)
[DEBUG] Adding managed dependencies for
org.apache.maven:maven-repository-metadata
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-repository-metadata:jar:2.0.4:runtime
(selected for runtime)
[DEBUG] Adding managed dependencies for org.apache.maven:maven-artifact
[DEBUG] org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1
[DEBUG] org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-ssh:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-ssh-external:jar:1.0-alpha-6
[DEBUG] org.apache.maven.wagon:wagon-file:jar:1.0-alpha-7
[DEBUG] org.apache.maven.wagon:wagon-http-lightweight:jar:1.0-alpha-6
[DEBUG] org.apache.maven:maven-artifact:jar:2.0.4:runtime (selected
for runtime)
[DEBUG]
org.apache.maven.wagon:wagon-provider-api:jar:1.0-alpha-6:runtime (selected
for runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime
(removed - nearer found: 1.1)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1:runtime (selected for
runtime)
[DEBUG] org.apache.maven:maven-artifact:jar:2.0.4:runtime (selected
for runtime)
[DEBUG]
org.codehaus.plexus:plexus-container-default:jar:1.0-alpha-9:runtime
(selected for runtime)
[DEBUG] junit:junit:jar:3.8.1:runtime (selected for runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.0.4:runtime (removed
- nearer found: 1.1)
[DEBUG] classworlds:classworlds:jar:1.1-alpha-2:runtime (selected
for runtime)
[DEBUG] Retrieving parent-POM:
org.jfrog.maven.annomojo:maven-plugin-anno-parent::1.3.1 for project:
null:maven-plugin-anno:jar:null from the repository.
[DEBUG] Adding managed dependencies for unknown:maven-plugin-anno
[DEBUG] org.jfrog.maven.annomojo:maven-plugin-anno:jar:1.3.1
[DEBUG] org.jfrog.maven.annomojo:maven-plugin-anno:jar:1.3.1:runtime
(selected for runtime)
[DEBUG] com.sun.xml.bind:jaxb-impl:jar:2.1.10:runtime (selected for
runtime)
[DEBUG] javax.xml.bind:jaxb-api:jar:2.1:runtime (selected for runtime)
[DEBUG] javax.xml.stream:stax-api:jar:1.0-2:runtime (selected for
runtime)
[DEBUG] javax.activation:activation:jar:1.1:runtime (selected for
runtime)
[DEBUG] Retrieving parent-POM: org.jvnet.jaxb2_commons:jaxb::2.1.10 for
project: org.jvnet.jaxb2_commons:jaxb-xjc:jar:2.1.10 from the repository.
[DEBUG] org.jvnet.jaxb2_commons:jaxb-xjc:jar:2.1.10:runtime (selected for
runtime)
[DEBUG] Retrieving parent-POM: com.sun:codemodel::2.1 for project:
com.sun.codemodel:codemodel:jar:null from the repository.
[DEBUG] com.sun.codemodel:codemodel:jar:2.1:runtime (selected for
runtime)
[DEBUG] com.sun.xml.dtd-parser:dtd-parser:jar:1.0:runtime (selected for
runtime)
[DEBUG] com.sun.istack:istack-commons-tools:jar:1.1:runtime (selected
for runtime)
[DEBUG] relaxngDatatype:relaxngDatatype:jar:20020414:runtime (selected
for runtime)
[DEBUG] com.sun.org.apache.xml.internal:resolver:jar:20050927:runtime
(selected for runtime)
[DEBUG] org.kohsuke.rngom:rngom:jar:20061207:runtime (selected for
runtime)
[DEBUG] com.sun.xsom:xsom:jar:20081112:runtime (selected for runtime)
[DEBUG] org.codehaus.plexus:plexus-utils:jar:1.1:runtime (selected for
runtime)
[DEBUG] The following artifacts were filtered out for plugin:
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin:0.7.1 because they're already in
the core of Maven:
These will use the artifact files already in the core ClassRealm instead, to
allow them to be included in PluginDescriptor.getArtifacts().
[DEBUG] Configuring mojo
'org.jvnet.jaxb2.maven2:maven-jaxb2-plugin:0.7.1:generate' -->
[DEBUG] (s) schemaDirectory =
/code/maven-jaxb2-plugin-sample-po-0.7.1/src/main/resources
[DEBUG] (s) disableDefaultExcludes = false
[DEBUG] (s) generateDirectory =
/code/maven-jaxb2-plugin-sample-po-0.7.1/target/generated-sources/xjc
[DEBUG] (s) readOnly = false
[DEBUG] (s) extension = false
[DEBUG] (s) strict = true
[DEBUG] (s) writeCode = true
[DEBUG] (s) verbose = false
[DEBUG] (s) debug = false
[DEBUG] (s) forceRegenerate = false
[DEBUG] (s) removeOldOutput = false
[DEBUG] (s) episodeFile =
/code/maven-jaxb2-plugin-sample-po-0.7.1/target/generated-sources/xjc/META-INF/sun-jaxb.episode
[DEBUG] (s) episode = true
[DEBUG] (s) classpathElements =
[/code/maven-jaxb2-plugin-sample-po-0.7.1/target/classes]
[DEBUG] (s) specVersion = 2.1
[DEBUG] (s) project = MavenProject:
org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-sample-po-maven:0.7.1 @
/code/maven-jaxb2-plugin-sample-po-0.7.1/pom.xml
[DEBUG] (s) localRepository = [local] -> file:///Users/ben/.m2/repository
[DEBUG] (s) pluginArtifacts =
[org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-raw:jar:0.7.1:runtime,
org.codehaus.plexus:plexus-utils:jar:1.1:runtime,
org.jfrog.maven.annomojo:maven-plugin-anno:jar:1.3.1:runtime,
com.sun.xml.bind:jaxb-impl:jar:2.1.10:runtime,
javax.xml.bind:jaxb-api:jar:2.1:runtime,
javax.xml.stream:stax-api:jar:1.0-2:runtime,
javax.activation:activation:jar:1.1:runtime,
org.jvnet.jaxb2_commons:jaxb-xjc:jar:2.1.10:runtime,
com.sun.codemodel:codemodel:jar:2.1:runtime,
com.sun.xml.dtd-parser:dtd-parser:jar:1.0:runtime,
com.sun.istack:istack-commons-tools:jar:1.1:runtime,
relaxngDatatype:relaxngDatatype:jar:20020414:runtime,
com.sun.org.apache.xml.internal:resolver:jar:20050927:runtime,
org.kohsuke.rngom:rngom:jar:20061207:runtime,
com.sun.xsom:xsom:jar:20081112:runtime]
[DEBUG] -- end configuration --
[INFO] [jaxb2:generate {execution: default}]
[INFO] Started execution.
[INFO] JAXB API is loaded from the
[jar:file:/Users/ben/.m2/repository/javax/xml/bind/jaxb-api/2.1/jaxb-api-2.1.jar!].
[INFO] Detected JAXB API version [2.1].
[INFO]
pluginArtifacts:[org.jvnet.jaxb2.maven2:maven-jaxb2-plugin-raw:jar:0.7.1:runtime,
org.codehaus.plexus:plexus-utils:jar:1.1:runtime,
org.jfrog.maven.annomojo:maven-plugin-anno:jar:1.3.1:runtime,
com.sun.xml.bind:jaxb-impl:jar:2.1.10:runtime,
javax.xml.bind:jaxb-api:jar:2.1:runtime,
javax.xml.stream:stax-api:jar:1.0-2:runtime,
javax.activation:activation:jar:1.1:runtime,
org.jvnet.jaxb2_commons:jaxb-xjc:jar:2.1.10:runtime,
com.sun.codemodel:codemodel:jar:2.1:runtime,
com.sun.xml.dtd-parser:dtd-parser:jar:1.0:runtime,
com.sun.istack:istack-commons-tools:jar:1.1:runtime,
relaxngDatatype:relaxngDatatype:jar:20020414:runtime,
com.sun.org.apache.xml.internal:resolver:jar:20050927:runtime,
org.kohsuke.rngom:rngom:jar:20061207:runtime,
com.sun.xsom:xsom:jar:20081112:runtime]
[INFO] schemaLanguage:null
[INFO]
schemaDirectory:/code/maven-jaxb2-plugin-sample-po-0.7.1/src/main/resources
[INFO] schemaIncludes:[Ljava.lang.String;@7544a6
[INFO] schemaExcludes:null
[INFO]
bindingDirectory:/code/maven-jaxb2-plugin-sample-po-0.7.1/src/main/resources
[INFO] bindingIncludes:[Ljava.lang.String;@ee1aa2
[INFO] bindingExcludes:null
[INFO] disableDefaultExcludes:false
[INFO] catalog:null
[INFO]
catalogResolver:com.sun.org.apache.xml.internal.resolver.tools.CatalogResolver
[INFO] generatePackage:null
[INFO]
generateDirectory:/code/maven-jaxb2-plugin-sample-po-0.7.1/target/generated-sources/xjc
[INFO] readOnly:false
[INFO] extension:false
[INFO] strict:true
[INFO] writeCode:true
[INFO] verbose:true
[INFO] debug:false
[INFO] args:[]
[INFO] forceRegenerate:false
[INFO] removeOldOutput:false
[INFO] otherDepends:null
[INFO]
episodeFile:/code/maven-jaxb2-plugin-sample-po-0.7.1/target/generated-sources/xjc/META-INF/sun-jaxb.episode
[INFO] episode:true
[INFO]
classpathElements:[/code/maven-jaxb2-plugin-sample-po-0.7.1/target/classes]
[INFO] plugins:null
[INFO] episodes:null
[INFO] xjcPlugins:null
[INFO] episodes:null
[INFO] specVersion:2.1
[INFO] schemaFiles (calculated):[]
[INFO] bindingFiles (calculated):[]
[INFO] xjcPluginArtifacts (resolved):[]
[INFO] xjcPluginFiles (resolved):[]
[INFO] xjcPluginURLs (resolved):[]
[INFO] episodeArtifacts (resolved):[]
[INFO] episodeFiles (resolved):[]
[INFO] The schemaLanguage setting was not defined, assuming 'AUTODETECT'.
Looking for META-INF/services/com.sun.tools.xjc.Plugin for add-ons
Checking
jar:file:/Users/ben/.m2/repository/org/jvnet/jaxb2_commons/jaxb-xjc/2.1.10/jaxb-xjc-2.1.10.jar!/META-INF/services/com.sun.tools.xjc.Plugin
for an add-on
Attempting to instanciate
com.sun.tools.xjc.addon.locator.SourceLocationAddOn
Attempting to instanciate
com.sun.tools.xjc.addon.sync.SynchronizedMethodAddOn
Attempting to instanciate com.sun.tools.xjc.addon.at_generated.PluginImpl
Attempting to instanciate com.sun.tools.xjc.addon.episode.PluginImpl
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Error parsing the command line [[Ljava.lang.String;@5730f8]
Embedded error: grammar is not specified
[INFO]
------------------------------------------------------------------------
[DEBUG] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Error parsing the
command line [[Ljava.lang.String;@5730f8]
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:583)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:499)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:478)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:330)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:291)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:287)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error parsing the
command line [[Ljava.lang.String;@5730f8]
at org.jvnet.jaxb2.maven2.RawXJC2Mojo.setupOptions(RawXJC2Mojo.java:481)
at org.jvnet.jaxb2.maven2.RawXJC2Mojo.doExecute(RawXJC2Mojo.java:249)
at org.jvnet.jaxb2.maven2.RawXJC2Mojo.execute(RawXJC2Mojo.java:134)
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:451)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:558)
... 16 more
Caused by: com.sun.tools.xjc.BadCommandLineException: grammar is not
specified
at com.sun.tools.xjc.Options.parseArguments(Options.java:795)
at org.jvnet.jaxb2.maven2.RawXJC2Mojo.setupOptions(RawXJC2Mojo.java:477)
... 20 more
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 2 seconds
[INFO] Finished at: Tue Jun 23 14:33:57 MDT 2009
[INFO] Final Memory: 6M/12M
[INFO]
------------------------------------------------------------------------
So now that I have the plugin working, I have another question. Is there a
use case for generating java objects from an XSD that is external from the
current project? Perhaps via a dependency, included within a jar file?
Thanks,
Ben.
On Tue, Jun 23, 2009 at 1:51 PM, Aleksei Valikov <valikov_at_gmx.net> wrote:
> Hi,
>
> > I'm attempting to generate pojos from an XML schema. Haven't gotten very
> far.
> >
> > Maven configuration:
> >
> > <plugin>
> > <groupId>org.jvnet.jaxb2.
> > maven2</groupId>
> > <artifactId>maven-jaxb2-plugin</artifactId>
> > <version>0.7.1</version>
> > <executions>
> > <execution>
> > <goals>
> > <goal>generate</goal>
> > </goals>
> > </execution>
> > </executions>
> > </plugin>
> >
> > Running 'mvn clean install' on my project with this configuration yields
> the following errors:
>
> Please post the mvn -X -e clean install report. Where are the schema
> files placed? Have you tried any of the samples?
>
>
> http://download.java.net/maven/2/org/jvnet/jaxb2/maven2/maven-jaxb2-plugin-sample-po/0.7.1/
>
> > In hopes that building my own plugin locally might yield better results I
> downloaded the source
> > code for the plugin and attempted to build (I had to do this to get a
> schemagen plugin).
>
> Here's continuous integration for maven-jaxb2-plugin:
>
> http://hudson.highsource.org/view/maven-jaxb2-plugin/
>
> This Hudson continuously builds maven-jaxb2-plugin (as well as tests
> and samples) with both JDK 1.5 and 1.6. Deployed releases are built
> with JDK 1.5.
>
> > Perhaps this is due to the fact that I'm running Mac OS X + JDK 1.5 that
> does not have a tools.jar?
>
> Is your JAVA_HOME maybe pointing to JRE instead of JDK?
>
> > Has anyone had success running the JAXB maven plugins? Thus far it's been
> very difficult to get thesse plugins to work. Any help would be much
> appreciated.
>
> I'm successfully running maven-jaxb2-plugin in many projects without
> any problems.
>
> Bye.
> /lexi
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jaxb.dev.java.net
> For additional commands, e-mail: users-help_at_jaxb.dev.java.net
>
>