We've got a project migrating from websphere to jboss. In the websphere deployment document, there's a step specifying war class loader policy: single class loader for application. Just wondering, what's the jboss equivalence for this step?
Thanks in advance.
Should check this out:
http://community.jboss.org/wiki/ClassLoadingConfiguration
IIRC, JBoss already uses a unified class loader by default (well at least the last time I used it which was 2 years ago). You actually have to disable it in your configuration.
Related
I have a JBoss EAP 6.4 implementation which runs a bunch of separate applications within it. All living in the same WAR file.
For one of those applications I want to modify the class-path. Specifically I want it to exchange two jars for two others.
Is that possible?
I am currently in the process of rearranging application jars so that my application can run smoothly on Websphere as well as JBoss with minimal changes.
With Webshpere's hierarchical class loading, everything works fine. But JBoss is creating lots of issues with its modular loading, with exceptions like -
java.lang.ClassNotFoundException: "javax.management.DynamicMBean" from [Module from local module loader
Since this class is part of JDK 6, should JBoss not pick it up automatically? Does anyone know any solution to this?
I am using JBoss AS 7.3 with JDK 6
Solved this by adding a dependency on javax.api in module.xml for one of my custom jboss modules.
I know its a very high level question, but it will be very much help full if somebody can help me to kick start the migration.
So please provide some links or use full hints to start with it.
Also if somebody knows about delta changes between JBOSS AS 6 to Wild fly.
Major change which i know that our application uses-
JBOSS AOP
JBOSS Interceptors
and binds it in jboss-aop.xml
like below
<bind pointcut="execution(public * *.DBDAO >updateBO(com.test.model.TestClass, com.test.model.TestClass2))">
<interceptor-ref name="TestInterceptor"/>
</bind>
which is not supported by wild fly now.
And so there must be other thing s which might not be supported by wild fly.
Thanks.
According documentation:
Replace JBoss AOP Interceptors
JBoss AOP (Aspect Oriented Programming) is no longer included in JBoss AS 7. In previous releases, JBoss AOP was used by the EJB container. However, in AS 7, the EJB container uses a new mechanism. If your application uses JBoss AOP, you need modify your application code as follows.
Standard EJB3 configurations that were made in the ejb3-interceptors-aop.xml file are now done in the server configuration file. For a standalone server, this is the standalone/configuration/standalone.xml file. If you are running your server in a managed domain, this is the domain/configuration/domain.xml file.
Applications that integrate AOP interceptors into the EJB layer must be redesigned to use EJB3 interceptors and CDI. Server side interceptors can be changed to EJB3 interceptors, but there is no client side interceptor in AS 7.
Like AOP exist other changes you can see in: How do I migrate my application from AS5 or AS6 to WildFly and Experiences with migrating from JBoss AS 7 to WildFly 8.1
The last link refers to some changes that are not in the official documentation.
Here is whole migration guide from Red Hat. JBoss EAP 6.2 has similar architecture to WildFly so you can use it:
https://access.redhat.com/documentation/en-US/JBoss_Enterprise_Application_Platform/6.2/html-single/Migration_Guide/index.html
I just downloaded some days ago the last versions of Eclipse and JBoss, created a SessionBean (EJB3.x) project and now I'm trying to create an Singleton EJB, but eclipse is not allowing me to do it and gives me the folowing warning message " The 'Singleton' state type is allowed only for EJB projects with version 3.1 or later". Unhappily, when I create the project, the hihgst version possible is 3.0.
What am I doing wrong? I need a singleton Ejb now!!!
Thanks in advance,
Saul
Problem solved!
Indeed Jboss 5.1 didn't support EJB 3.1, but JBoss 6.0 does!
Just an observation to those are facing this same problem. Eclipse doesn't have the adapter for JBoss 6.0, but if you use the one provided for JBoss 5.0 it works just fine (I read somewhere there might be some problems, but at least till now, it's ok).
Also, if you try to create an singleton EJB through Eclipse, it'll not work, but you can create another type of EJB and then change the annotation to #Singleton and it'll work.
Best Regards,
Saul
Seam 2.1 and JBoss 4.2.2
I have set up the first App to have the EJB in the EAR with a local interface.
the 2nd app can look up JDNI name "ear-name/ejbname/local" but fails with "NoClassDefFound".
Does the EJB .jar need to be outside of the EAR?
Is this a classloader visibility issue or Is this a JBoss version issue? or something else?
Thank you for your thoughts..
I cannot answer if it will work or not. However, I can tell you how we do this.
We have created a #Webservice component that uses this EJB. And then we connect to the Webservice from our other application.
I blogged about this a while back. You can have a read if you are interested.