Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Generate Websphere 6.1 compatible EAR file using Maven

I've been looking around for some time and couldn't find a clear explanation for this.

We're using a Websphere server to run a Web application developed using Rational Software Architect 7. This application is composed of a war project and 4 jar projects. To make the final ear file there is a sixth project which contains the additional files needed by IBM to deploy it.

Currently we have to use RSA to genereate the ear file. I would like to use Maven to do that.

Apparently previous tries to use maven-ear plugin generated corrupted ears. It would appear thet they are missing the extra xml files needed by IBM.

I found a maven was-6 plugin, but it doesn't seem able to generate the file, only to install it on websphere. I couldn't find a clear description of what it does.

Does someone have any advice ? A link to some article ?

Thank you very much !

like image 951
IceGras Avatar asked Aug 24 '10 13:08

IceGras


People also ask

How to create EAR module in Maven?

Maven - Create an EAR module (ear file) – mtitek.com. In the folder « application », you can add the folder « META-INF ». In the folder « application », you can also add other configuration files specific to the application server where the EAR will be deployed.

How to create EAR file in eclipse using Maven?

You can create an EAR project using File > New > Enterprise Application Project. Change the JavaEE version to JavaEE 6 for deployment to JBoss 7. x, enable the 'Add maven support' and in the next page, select the already created maven project as module to add to the EAR project.

How to Add Maven dependency in rad?

1) Open the Window Preferences dialog. Navigate to Window -> Preferences -> Java EE -> Maven -> Maven Project Settings. Set the Dynamic Web Project -> Content Directory value to src/main/webapp by pressing the 'Set Maven value' button to the right of the value. Click OK.


1 Answers

Use the maven-ear-plugin to generate your ear, but include the extra ibm specific config files as part of the earSourceDirectory property of that plugin.

The plugin will generate the generic application.xml file and the ibm specific file ibm-application-bnd.xmi and the contents of the ibmconfig directory can be rolled in by the plugin as well, just not generated.

like image 54
Robin Avatar answered Oct 16 '22 21:10

Robin