I recently set up JBoss 4.2 on a Staging environment. The Production environment uses JBoss 4.0.3 SP1 and there was a hanging question of whether the application could be transferred to the newer series or not. The obvious advantage of the migration would be to move EJB3.
Well it took a lot of work but I am happy to say that if you have a J2EE 1.4 application you can move it to JBoss 4.2 and EJB 2 and 3 deployments all live together happily in the container.
However there is an important bit of behaviour that has changed and that is that JBoss no longer binds to all adaptors automatically. Instead it binds to localhost by default (I think). My deployment machine was a virtual server with a NAT internal IP and an external IP linked to its DNS alias. Therefore I knew I had issues with binding as in addition to the different IPs I also do not actually have any physical network I’m binding too.
However despite noting the issue in the JBoss wiki documentation I then proceeded to fluff the configuration. Despite having the web containers up and running, along with the JMX Beans I could not get my web tier to talk to my service tier. Instead I was getting obscure messages like Object not in table or a connection timeout.
What I had failed to realise from the documentation is that specifying the --host
parameter to the run.sh script is not like defining the system property jboss.bind.address. Superficially they may seem the same, indeed they are so similar that you can in fact stop and start JBoss quite happily using this parameter. However your RMI connector will have be been bound to something else and therefore all RMI calls from outside the server will get routed to /dev/null (geek joke; I have no idea what happens to them but judging from the error message the JNDI lookup fails to connect to any object in the pool capable of servicing the request, the handle lookup probably returns null).
Essentially on a non-production machine you always want to pass
--host=0.0.0.0
to the start script otherwise the services will bind to different addresses and you will have erratic behaviour where connecting to your host by it’s DNS name, the localhost alias and by 127.0.0.1 will all have different results (normally only one of them will actually have the service).
The only other issue is that the AS Log4J configuration has been renamed to jboss-log4j.xml. While this causes some short term pain it was only when I read the release note that I thought: “hey it is weird that we configure all our logging via the container’s configuration file”.
Sir
How to install jboss4.2.2 they say to run InstallJBoss.bat file from javaservice.zip
provided by forge.objectweb.org/projects/javaservice
I am not able to run InstallJBoss.bat file provided
pl guide me
Hi,
Thanks…nice post…Currently if I bind it to 0.0.0.0 it opens up all and gets resolved to a host name. If I want to bind my AS only to an IP Address instead of all available interfaces, what should I have to do?
Thanks
Shankar
Pass the IP of the network adaptor instead of zeros in the host parameter. E.g. –host=213.43.2.1.
Hi,
I am working on jdk1.4,ejb2.1,jboss3.0.8.On my client I would like to migrate jdk1.5 and jboss4.2.2.When I was trying to deploy me ear file on jboss4.2.2.I got following error.Please help.Thanks in advance
18:00:12,490 ERROR [MainDeployer] Could not create deployment: file:/E:/jboss-4.2.2.GA/jboss-4.2.2.GA/server/default/deploy/PartnerAccessEJB_JAR.jar
org.jboss.deployment.DeploymentException: Verification of Enterprise Beans failed, see above for error messages.