This week's book giveaway is in the Open Source forum.
We're giving away four copies of Programmers Guide to Apache Thrift and have Randy Abernethy on-line!
See this thread for details.
Win a copy of Programmers Guide to Apache Thrift this week in the Open Source forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis

How to make an ear file as a global module in Jboss eap 6.0  RSS feed

 
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I want to make an ear file as a global module in the jboss eap 6.0 , so that the ear file can be access by all other war or ear files .

I have searched in the net and i found few docs on how to make a jar file global but no document on making the ear file global.


My ear file contains:


1)App-inf : which contains a lib folder ,where multiple jar files are placed

2)Meta-inf : which contain menifest file and application.xml file

3)Jar file : containing two packages com and financial package and one jar file






I have created one module.xml along with ear in jboss/module folder. My module.xml is below:


#################################
<?xml version="1.0" encoding="UTF-8"?>

<module xmlns="urn:jboss:module:1.0" name="30_financial">

<resources>

<resource-root path="30_FinancialClaims.ear"/>

</resources>

<dependencies>
<module name="org.aspectj"/>
<module name="org.apache"/>
<module name="com.tiscon"/>
<module name="org.exolab"/>
<module name="com.hp.ce"/>
<module name="org.apache.commons"/>
<module name="com.hp.ews"/>

<module name="com.ibm"/>
<module name="com.jacob"/>
<module name="javax.xml"/>
<module name="org.jdom"/>
<module name="org.apache.log4j"/>
<module name="oracle.jdbc"/>
<module name="org.apache.poi"/>

<module name="javax.xml.soap"/>
<module name="com.hp.eclaims.snt"/>
<module name="com.tiscon.util.timemeasurement"/>
<module name="com.tiscon.util.db"/>
<module name="com.tiscon.util.ejb"/>
<module name="org.apache.tomcat.dbcp"/>
<module name="com.ibm.wsdl"/>

</dependencies>

</module>

#####################

In standalone.xml - I have included below entry in the standalone.xml .

##################
<subsystem xmlns="urn:jboss:domain:ee:1.1">

<global-modules>
<module name="30_financial" slot="main"/>
</global-modules>

<spec-descriptor-property-replacement>false</spec-descriptor-property-replacement>
<jboss-descriptor-property-replacement>true</jboss-descriptor-property-replacement>
</subsystem>

###########################

The error i am getting in jboss console is:



18:27:53,123 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-5) MSC000001: Failed to start service jboss.deployment.unit."FinancialClaimsPaa.war".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.unit."FinancialClaimsPaa.war".INSTALL: JBAS018733: Failed to process phase INSTALL of deployment "FinancialClaimsPaa.war"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:123) [jboss-as-server-7.1.3.Final-redhat-4.jar:7.1.3.Final-redhat-4]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA-redhat-2.jar:1.0.2.GA-redhat-2]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA-redhat-2.jar:1.0.2.GA-redhat-2]
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) [rt.jar:1.6.0_45]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) [rt.jar:1.6.0_45]
at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_45]
Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: JBAS018102: Error loading SCI from module: 30_financial:main
at org.jboss.as.web.deployment.ServletContainerInitializerDeploymentProcessor.deploy(ServletContainerInitializerDeploymentProcessor.java:113)
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:116) [jboss-as-server-7.1.3.Final-redhat-4.jar:7.1.3.Final-redhat-4]
... 5 more
Caused by: org.jboss.modules.ModuleNotFoundException: Module org.aspectj:main is not found in local module loader @7f56b6b9 (roots: C:\HP-jboss-eap-6.0\modules)
at org.jboss.modules.LocalModuleLoader.findModule(LocalModuleLoader.java:126)
at org.jboss.modules.ModuleLoader.loadModuleLocal(ModuleLoader.java:275)
at org.jboss.modules.ModuleLoader.preloadModule(ModuleLoader.java:222)
at org.jboss.modules.LocalModuleLoader.preloadModule(LocalModuleLoader.java:94)
at org.jboss.modules.Module.addPaths(Module.java:851)
at org.jboss.modules.Module.link(Module.java:1206)
at org.jboss.modules.Module.relinkIfNecessary(Module.java:1235)
at org.jboss.modules.ModuleLoader.loadModule(ModuleLoader.java:208)
at org.jboss.as.web.deployment.ServletContainerInitializerDeploymentProcessor.deploy(ServletContainerInitializerDeploymentProcessor.java:106)
... 6 more

18:27:53,170 INFO [org.jboss.as.server] (HttpManagementService-threads - 4) JBAS015870: Deploy of deployment "FinancialClaimsPaa.war" was rolled back with failure message {"JBAS014671: Failed services" => {"jboss.deployment.unit.\"FinancialClaimsPaa.war\".INSTALL" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"FinancialClaimsPaa.war\".INSTALL: JBAS018733: Failed to process phase INSTALL of deployment \"FinancialClaimsPaa.war\"
Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: JBAS018102: Error loading SCI from module: 30_financial:main
Caused by: org.jboss.modules.ModuleNotFoundException: Module org.aspectj:main is not found in local module loader @7f56b6b9 (roots: C:\\HP-jboss-eap-6.0\\modules)"}}
18:27:56,602 INFO [org.jboss.as.server.deployment] (MSC service thread 1-8) JBAS015877: Stopped deployment FinancialClaimsPaa.war in 3427ms




from the above error, i am thinking that the jboss is not able to find out dependency jars like aspectj.jar etc , but the ear file is already having those jars.If the jars are not visible then do we have any other approach to make these above jars visible to jboss.

Can any body suggest me if the above approach is correct or not.

Regards

Sanjeev Kumar
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!