-
1. Re: Javarebel style redeployment
swd847 Apr 7, 2009 5:10 AM (in response to swd847)I have uploaded it here: EJBTHREE-1096
-
2. Re: Javarebel style redeployment
www.supernovasoftware.com Apr 7, 2009 4:26 PM (in response to swd847)I will definitely try this out. Thanks.
I have tried connecting the debugger to my application server in eclipse, but this is not that stable.
Does this method work better that that?
Also, everyone please vote for EJBTHREE-1096
-
3. Re: Javarebel style redeployment
gonorrhea Apr 7, 2009 6:20 PM (in response to swd847)Me likes :)
I download the zip file. Is this compatible with Seam 2.0 and 2.1?
How about changing the signatures of the business (local and remote interface) methods?
Will it somehow notify if you added a business method and it didn't pick it up for the ant explode?
Good job on this bro! I voted for this JIRA a long time back...
what is the technical limitation that we cannot capture new business methods as well on ant explode with your solution?
-
4. Re: Javarebel style redeployment
gonorrhea Apr 7, 2009 6:24 PM (in response to swd847)and what about adding non-public methods to an EJB? (e.g. private void foo(), protected void bar()) will it pick that up?
I guess I should just try it out...
-
5. Re: Javarebel style redeployment
gonorrhea Apr 7, 2009 6:32 PM (in response to swd847)
This is implemented as a seam filter...So do we need to modify the web.xml for our apps or what? The only src file is this:
public class Agent { static Instrumentation inst; /** * Stores a reference to instrumentation * @param agentArgs * @param i */ public static void premain(String agentArgs, Instrumentation i) { if (!i.isRedefineClassesSupported()) { System.out.println("Class redfinition not supported"); } else { inst = i; } } /** * attempts to replace the specified classes while the jvm is running * @param da * @throws UnmodifiableClassException * @throws ClassNotFoundException */ public static void replaceClass(ClassDefinition[] da) throws UnmodifiableClassException, ClassNotFoundException { if (inst != null) { inst.redefineClasses(da); } else { System.out.println("Class redfinition not supported"); } } }
and it doesn't implement a Filter interface.
???
am I missing something here?
Also recommend using log4j rather than System.out.println...
-
6. Re: Javarebel style redeployment
swd847 Apr 7, 2009 10:12 PM (in response to swd847)There is ClassRedefinitionFilter in the root of the zip, it is the filter and should go in your seam project. Ajent.java is part of hot-deploy.jar, the java agent. When you start jboss start it with the jvm option -javaagent:/path/to/hot-deplloy.jar.
This approach uses the java instrumentation api, so it is not as good as javarebel, in that it does not let you delete methods. It may have other limitations depending on what JVM you are using.
This is just a quick and dirty version that I knocked up, I am going to try and work on this over easter and try and remove some of the limitations.
-
7. Re: Javarebel style redeployment
alefeltes Apr 29, 2009 5:47 PM (in response to swd847)I was also having problem with EJBs and JavaRebel
The context variable was basically used for a different purpose, which is illegal (or you have the hot deployment classloader scenario described above).Stuart's suggestion worked perfect for me.
There is only one typo in jar's name on your post (one extral
).
I placed the ClassRedefinitionFilter.java on its corresponding packagecom.brite.framework
and added the jvm option to my Jboss and hot deploy worked like a charm.
It also advices you (with a stacktrace) for the code that could not be replaced, wich is also very handy.
Thanks for sharing.Ale
-
8. Re: Javarebel style redeployment
ekabanov Nov 25, 2009 4:53 PM (in response to swd847)Hi guys, if you want to help get JRebel and Seam working together please sign off here:
JRebelAndSeamIntegration