Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] Weaving already loaded classes

back 2 years ago I had implemented a "remote hotswap" feature to
enable AspectWerkz weaving remotely after startup
(http://aspectwerkz.codehaus.org/weaving.html#Remote_HotSwap)

that is fun, but in absolute not that usefull, as when you have done
that it becomes unclear what aspect will be weaved in where -
My use case for that was:
- start app as usual, with a bunch of troubleshooting aspect ready
around (but not weaved in)
- let it run
- enable weaver remotely with remote hotswap
- redeploy some sub apps so that the troubleshooting aspects get deployed

I think late binding of agent makes total sense for non instrumenting
ones, but that is more debatable for instrumenting ones (as you still
need a redeploy and the actual scope of the so simulated hot
deployment of your aspect becomes unclear).
IMHO it's a try to match what a true dynamic weaver can do.

Alex



On 12/23/05, mohan.radhakrishnan@xxxxxxxxxxxxx
<mohan.radhakrishnan@xxxxxxxxxxxxx> wrote:
>
> Hi,
>      Yes. It seems that this API was designed for profiling. Actually I
> started poking around this when I found there is a way to use Mustang
> jconsole to an already running VM and monitor using JMX/AOP(GlassBox
> Inspector) even if you don't start the JSE 5.0 VM with
> -Dcom.sun.management.jmxremote.
>
> So when I read that a java agent can be loaded on an already running VM
> using the Attach API in mustang, I though it could be of use to AOP.
>
> Thanks,
> Mohan
>
> -----Original Message-----
> From: aspectj-users-bounces@xxxxxxxxxxx
> [mailto:aspectj-users-bounces@xxxxxxxxxxx] On Behalf Of Alexandre
> Vasseur
> Sent: Friday, December 23, 2005 4:01 AM
> To: aspectj-users@xxxxxxxxxxx
> Subject: Re: [aspectj-users] Weaving already loaded classes
>
> Mohan
>
> My personnal opinion:
> This is actually an attempt from the JSR-163 folks to solve the complex
> problem of multiple weaving that I and others had raised 2 years ago.
> Retransform is aiming at handling the non retransform capable agents
> (see the agent manifest doc)
>
> Sadly, this is really going into hell (see also the tricks to rename
> native method and making sure native pointer to the native impl.
> beehind are kept in sync by the VM - needed f.e. to do an around like
> advice on a native method execution - required by some profiling tool
> vendor out there) while we have demonstrated what could be done by
> forgetting about bytecode and moving things into the VM directly.
> See our standpoint on that f.e. in
> http://dev2dev.bea.com/pub/a/2005/08/jvm_aop_1.html (shameless plug)
>
> Alex
>
>
>
>
> On 12/22/05, mohan.radhakrishnan@xxxxxxxxxxxxx
> <mohan.radhakrishnan@xxxxxxxxxxxxx> wrote:
> > Hi,
> >        Any idea if this is useful
> > http://download.java.net/jdk6/docs/api/java/lang/instrument/Instrument
> > ation.html#retransformClasses(java.lang.Class...)
> > ?
> > This is a mustang feature called late-binding agent support.
> >
> > Thanks,
> > Mohan
> >
> >
> >
> >
> > This message is for the designated recipient only and may contain
> > privileged, proprietary, or otherwise private information. If you have
>
> > received it in error, please notify the sender immediately and delete
> > the original. Any other use of the email by you is prohibited.
> > _______________________________________________
> > aspectj-users mailing list
> > aspectj-users@xxxxxxxxxxx
> > https://dev.eclipse.org/mailman/listinfo/aspectj-users
> >
> >
> >
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/aspectj-users
>
>
> This message is for the designated recipient only and may contain privileged, proprietary, or otherwise private information.  If you have received it in error, please notify the sender immediately and delete the original.  Any other use of the email by you is prohibited.
> _______________________________________________
> aspectj-users mailing list
> aspectj-users@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/aspectj-users
>


Back to the top