This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

failed to initialize bean container with "Null beannMetaData" error

 
Ananth Vasudevan
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm trying to deploy an EAR file in JBOSS 5.1GA with "all" configuration and getting a DeploymentException
with message "failed to initialize bean container" and "Null beannMetaData". JBOSS is not started.
I saw there is a similar post with the same exception : http://community.jboss.org/thread/65998?tstart=0#4267965.
I do not have any Jboss libraries inside the lib directory inside the xxx.ear file. I have only some libraries
that are needed for our custom application. The EJB's inside the ejb-jar.xml seems to get loaded/registered. But when the
SAR file is getting deployed, it throws exceptions.
Could somebody point me as to what could be wrong?


My EAR file is organized as follows:

EAR
|
|
---META-INF
| |
| ---application.xml
| ---jboss-app.xml
| ---MANIFEST.MF
|
---ejb-module.jar
| |
| META-INF
| |
| ---ejb-jar.xml
| ---jboss.xml
|
---xxx.war
| |
| xxx-applet.jar
---xxx.sar
| |
| ---META-INF
| |
| ---jboss-service.xml
| ---manifest.mf
|
|
---lib
|
---xxx-lib.jar


application.xml



jboss-app.xml



Any help is greatly appreciated! Please let me know, if you need any other configuration info.


JBOSS Start up logs:

 
Francesco Marchioni
author
Ranch Hand
Posts: 194
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
It might be a problem in packaging your archives. Have a look here:
https://jira.jboss.org/browse/EJBTHREE-1969

regards
Francesco
 
Ananth Vasudevan
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Francesco,

Thanks for the response. All the EJB's ejb-module.jar gets deployed and my problem seems to be only with the SAR file deployment.
The workaround in the JIRA bug report says to move ejb1.jar out of lib to the root of the ear
and list it in the application.xml. But I do not have any EJB's inside the "lib" directory.

I tried some options and still not able to get the SAR file deployed.

1. I added the SAR file deployment to the ear/META-INF/application.xml and removed the jboss-app.xml.

2. I removed the SAR file out of the EAR file and deployed it independently and got the same error
as mentioned above in my original post. The EJB's got deployed and the deployment failed because of the SAR file.

Any other options that I should try out?

 
Jaikiran Pai
Marshal
Pie
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why are you deploying EJBs in a .sar file? I don't think we have ever tested deploying EJBs in .sar files on JBoss AS5 or JBoss AS6.
 
Ananth Vasudevan
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Jaikiran,

I'm not deploying EJB's in the SAR file.

The SAR file contains custom MBean code in a jar file and jboss-service.xml & manifest.mf inside the META-INF directory.

jboss-service.xml



manifest.mf


 
Jaikiran Pai
Marshal
Pie
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We have already had some issues with ClassPath processing with MANIFEST.MF files. So even if your jar is outside the .sar, it still is referenced via the MANIFEST.MF of the .sar. It's better to just get rid of the .sar and then place the bean deployment jar in the deploy folder. The EJB jar can then additionally contain the jboss-service.xml in it's META-INF folder with the following contents:

 
Ananth Vasudevan
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, Jaikiran.

Getting rid of the SAR file and adding the jboss-service.xml to the META-INF directory of the ejb's jar file seems to deploy the services.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic