[
https://issues.apache.org/jira/browse/MEAR-70?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17958963#comment-17958963
]
Matthias Bünger commented on MEAR-70:
-------------------------------------
This project has moved from Jira to GitHub Issues. This issue was migrated to
[apache/maven-ear-plugin#272|https://github.com/apache/maven-ear-plugin/issues/272].
> loader-repository node for jboss configuration
> ----------------------------------------------
>
> Key: MEAR-70
> URL: https://issues.apache.org/jira/browse/MEAR-70
> Project: Maven EAR Plugin (Moved to GitHub Issues)
> Issue Type: Bug
> Affects Versions: 2.3
> Reporter: Mark Kettner
> Assignee: Stephane Nicoll
> Priority: Major
>
> I added the patch MEAR-50.patch to the 2.3 version of the maven-ear-plugin.
> However, after the patch I still couldn't generate a correct jboss-app.xml
> file when the pom.xml contained the following definition:
> <build>
> <plugins>
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-ear-plugin</artifactId>
> <version>2.3.1</version>
> <configuration>
> <jboss>
> <version>4</version>
> <loader-repository>
> nl.ictu.spg.bsn:loader=afslagbsn
>
> <loader-repository-config>java2ParentDelegation=false</loader-repository-config>
> </loader-repository>
> </jboss>
> </configuration>
> </plugin>
> </plugins>
> </build>
> This is because in the file AbstractEarMojo the
> final String loaderRepository = jboss.getChild(
> JbossConfiguration.LOADER_REPOSITORY ).getValue();
> is null when a subtag is added to the loaderRepository tag.
> This can be solved by changing the definition in the pom.xml file to the
> following:
> <build>
> <plugins>
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-ear-plugin</artifactId>
> <version>2.3.1</version>
> <configuration>
> <jboss>
> <version>4</version>
> <loader-repository><![CDATA[
> nl.ictu.spg.bsn:loader=afslagbsn
>
> <loader-repository-config>java2ParentDelegation=false</loader-repository-config>]]>
> </loader-repository>
> </jboss>
> </configuration>
> </plugin>
> </plugins>
> </build>
> and change the "write" method in the JbossAppXmlWriter class to the following:
> // classloader repository
> if ( jbossConfiguration.getLoaderRepository() != null )
> {
> writer.startElement( JbossConfiguration.LOADER_REPOSITORY );
> writer.writeMarkup( jbossConfiguration.getLoaderRepository() );
> writer.endElement();
> }
--
This message was sent by Atlassian Jira
(v8.20.10#820010)