Return-Path: X-Original-To: apmail-cxf-issues-archive@www.apache.org Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E4FF2D58D for ; Mon, 23 Jul 2012 13:06:35 +0000 (UTC) Received: (qmail 95984 invoked by uid 500); 23 Jul 2012 13:06:35 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 95936 invoked by uid 500); 23 Jul 2012 13:06:35 -0000 Mailing-List: contact issues-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list issues@cxf.apache.org Received: (qmail 95916 invoked by uid 99); 23 Jul 2012 13:06:35 -0000 Received: from issues-vm.apache.org (HELO issues-vm) (140.211.11.160) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 Jul 2012 13:06:35 +0000 Received: from isssues-vm.apache.org (localhost [127.0.0.1]) by issues-vm (Postfix) with ESMTP id 09AEA142823 for ; Mon, 23 Jul 2012 13:06:35 +0000 (UTC) Date: Mon, 23 Jul 2012 13:06:35 +0000 (UTC) From: "David J. M. Karlsen (JIRA)" To: issues@cxf.apache.org Message-ID: <310771353.90819.1343048795043.JavaMail.jiratomcat@issues-vm> In-Reply-To: <961044236.57221.1342436614803.JavaMail.jiratomcat@issues-vm> Subject: [jira] [Comment Edited] (CXF-4424) Option for codegen plugin to fork in order to support endorsed libs MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CXF-4424?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13420623#comment-13420623 ] David J. M. Karlsen edited comment on CXF-4424 at 7/23/12 1:05 PM: ------------------------------------------------------------------- In my top pom I declare in the properties section: {noformat} ... 2.2 2.2 2.2 ${project.build.directory}/endorsed {noformat} as well as manage surefire/compiler plugin to use endorsed: {noformat} org.apache.maven.plugins maven-compiler-plugin ${endorsed.dir} org.apache.maven.plugins maven-surefire-plugin once -Djava.endorsed.dirs=${endorsed.dir} {noformat} Thirdly in the topmost pom I configure the dependency plugin to copy the jaxws-api and jaxb-api to target/endorsed for all modules: {noformat} org.apache.maven.plugins maven-dependency-plugin generate-sources copy javax.xml.bind jaxb-api ${jaxb.api.version} javax.xml.ws jaxws-api ${jaxws.api.version} ${endorsed.dir} {noformat} in the child projects which generates code, I unpack a dependency containing wsdls and fork with the endorsed libs: {noformat} org.apache.maven.plugins maven-dependency-plugin unpack-cpl-server-schemas generate-sources unpack **/*.wsdl com.edb.fs.cashpool.srv cp-server-schemas ${cp.srv.version} org.apache.cxf cxf-codegen-plugin ${cxf.version} once -Djava.endorsed.dirs=${endorsed.dir} ${basedir}/src/main/resources/wsdl/catalog.xml ${basedir}/src/main/resources/wsdl/jaxbbindings.xml -fe jaxws21 -xjc-Xts -xjc-Xfluent-api -xjc-mark-generated -verbose true ${basedir}/src/main/resources/wsdl generate-sources-embedded generate-sources ${basedir}/src/main/resources/wsdl wsdl2java generate-sources-cp-srv generate-sources ${project.build.directory}/dependency/wsdl wsdl2java org.apache.cxf.xjcplugins cxf-xjc-ts ${cxf.ts.plugin.version} net.java.dev.jaxb2-commons jaxb-fluent-api 2.1.8 com.sun.xml.bind jaxb-impl ${jaxb.impl.version} com.sun.xml.bind jaxb-xjc ${jaxb.impl.version} {noformat} And for good measure some additional WebSphere info (v8 fixpack 3), was is jax-ws 2.2 and jaxb2.2: To avoid too big impact I leave my classloader to parent_first, but I add a shared library (set to use "isolated classloader") where I chuck in xmlschema-core-2.0.2. This will override xmlschema core which would otherwise be attempted loaded from ./plugins/org.apache.axis2.jar and be old (1.4.x) - but have minimal impact on classloading to avoid a lot of potential problems. Thanks for all help! was (Author: davidkarlsen@gmail.com): In my top pom I declare in the properties section: {noformat} ... 2.2 2.2 2.2 ${project.build.directory}/endorsed {noformat} as well as manage surefire/compiler plugin to use endorsed: {noformat} org.apache.maven.plugins maven-compiler-plugin ${endorsed.dir} org.apache.maven.plugins maven-surefire-plugin once -Djava.endorsed.dirs=${endorsed.dir} {noformat} in the child projects which generates code, I unpack a dependency containing wsdls and fork with the endorsed libs: {noformat} org.apache.maven.plugins maven-dependency-plugin unpack-cpl-server-schemas generate-sources unpack **/*.wsdl com.edb.fs.cashpool.srv cp-server-schemas ${cp.srv.version} org.apache.cxf cxf-codegen-plugin ${cxf.version} once -Djava.endorsed.dirs=${endorsed.dir} ${basedir}/src/main/resources/wsdl/catalog.xml ${basedir}/src/main/resources/wsdl/jaxbbindings.xml -fe jaxws21 -xjc-Xts -xjc-Xfluent-api -xjc-mark-generated -verbose true ${basedir}/src/main/resources/wsdl generate-sources-embedded generate-sources ${basedir}/src/main/resources/wsdl wsdl2java generate-sources-cp-srv generate-sources ${project.build.directory}/dependency/wsdl wsdl2java org.apache.cxf.xjcplugins cxf-xjc-ts ${cxf.ts.plugin.version} net.java.dev.jaxb2-commons jaxb-fluent-api 2.1.8 com.sun.xml.bind jaxb-impl ${jaxb.impl.version} com.sun.xml.bind jaxb-xjc ${jaxb.impl.version} {noformat} And for good measure some additional WebSphere info (v8 fixpack 3), was is jax-ws 2.2 and jaxb2.2: To avoid too big impact I leave my classloader to parent_first, but I add a shared library (set to use "isolated classloader") where I chuck in xmlschema-core-2.0.2. This will override xmlschema core which would otherwise be attempted loaded from ./plugins/org.apache.axis2.jar and be old (1.4.x) - but have minimal impact on classloading to avoid a lot of potential problems. Thanks for all help! > Option for codegen plugin to fork in order to support endorsed libs > ------------------------------------------------------------------- > > Key: CXF-4424 > URL: https://issues.apache.org/jira/browse/CXF-4424 > Project: CXF > Issue Type: Improvement > Components: Tooling > Affects Versions: 2.5.4 > Environment: java 6 > Reporter: David J. M. Karlsen > Labels: codegen, endorsed, fork > > In order to support endorsed libs it would be preferable to have the codegen plugin fork (and support setting of java.endorsed.dirs). > I wish to do so because my build uses a vanilla JDK6 which is JAXB 2.1 and JAX-WS 2.1, but the target env is JDK6, JEE6 on WAS8 with JAXB 2.2 and JAX-WS 2.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira