[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [equinox-dev] Equinox aspects: Several problems for Load-Time-Weaving in a eclipse product!
- From: "Andrew Eisenberg" <andrew@xxxxxxxxxxxx>
- Date: Mon, 1 Dec 2008 08:40:55 -0800
- Delivered-to: firstname.lastname@example.org
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:reply-to:sender:to:subject:in-reply-to :mime-version:content-type:content-transfer-encoding :content-disposition:references:x-google-sender-auth; b=UXQN8bc4Erq5TIKd7JcnUCxSrqmdEnNfdmUYaQwrCt1mMOsrhcZw6+Zzwd2dgORPHG ERa2KoLufuZD7i09ZmVwaLHunLKGaezuTw1/wU4dAAALYvItNjQ+qQOG8Wt4FdSqYuIG dJEG34Q+Ih6hGsqY6KTIseMSo2mH8mvN2B2Fc=
I have an update site for equinox aspects here:
You can try to install from there. The installation will
automatically update your config.ini for you. Should work, but you
need to have AspectJ pre-installed.
If Martin's suggestions don't work for you, you can try installing
from the update site.
On Mon, Dec 1, 2008 at 8:01 AM, Martin Lippert <lippert@xxxxxxx> wrote:
> Hi Jens!
> I am sure we can get your setting to work well with equinox aspects.
> Firstofall, I see that you are using an old version of equinox aspects. You
> should definitely download and use M3 of equinox aspects, this is much more
> stable, especially in the case of dynamics.
> Your config.ini looks good, I would just add a start level of 4 to the
> o.e.e.weaving.aspectj bundle. You definitely don't need to start your system
> with the osgi.clean option=true. The latest versions of equinox aspects work
> with and without cleaning the configuration area.
> If you would like to use dynamics for aspects, the best way to go is to
> install and uninstall aspect bundles. Every time an aspect bundle is
> installed and got resolved, the aspect is woven into the system, including a
> refresh of already running bundles. Telling you that you need to know that
> some Eclipse bundles do not behave well within an dynamic environment. For
> example refreshing swt or the workbench at runtime does not work. So if you
> would like to dynamically install and uninstall aspects you should take care
> that the effected bundles behave nicely within a dynamic environment.
> Jens Goldhammer wrote:
>> I have downloaded the equinox aspectj extension and integrated into
>> how it is mentioned in the user guide.
>> The hello world aspectj example works great for me. I can dynamically
>> and stop the aspectj service and the classes seam to be reloading at
>> I have zipped the folders org.aspectj.runtime_126.96.36.19980703120000 and
>> org.aspectj.weaver_188.8.131.5280703120000 (project
>> org.eclipse.equinox.weaving.demo.target) from the example to two jar files
>> and copied it to the eclipse plugins directory. I reloaded the target
>> platform, so the plugins are considered.
>> After playing with some examples, I tried to integrate aspects into our
>> eclipse product which is based on 3.4.1. I have created a config.ini
>> (modified the prebaked config.ini of eclipse export mechanism) which looks
>> like this one:
>> # default start level for the bundles
>> org.eclipse.update.configurator@3\:start, org.eclipse.core.runtime@start,
>> org.eclipse.equinox.weaving.caching@2\:start, com.ibm.icu, [our bundles],
>> # AOSGi
>> After configuring it there are two problems:
>> 1. If I start the product configuration via eclipse, I can see following
>> the osgi console after running ss:
>> 4 <<LAZY>> org.eclipse.equinox.weaving.aspectj_184.108.40.206808061839
>> 5 <<LAZY>> org.eclipse.equinox.weaving.caching.j9_220.127.116.11808061839
>> The two bundles for aspectj are not active after starting the osgi
>> I don´t know why! Something prevents loading the aspectj bundles. My
>> presumption is that the required bundles
>> org.aspectj.runtime_18.104.22.16880703120000.jar and
>> org.aspectj.weaver_22.214.171.12480703120000.jar are loaded to late from the
>> org.eclipse.update.configurator which loads all bundles from the plugins
>> directory. Or anyboday think there is another problem?
>> After starting the two bundles manually with start [bundle-ids], my trace
>> aspect which traces method calls is working for this session. But how I
>> deactivate it during runtime? I made a stop for the bundle 4
>> (org.eclipse.equinox.weaving.aspectj_126.96.36.199808061839) and the main
>> Activator of our application will be stopped!!! I thought I can
>> start and stop the aspect bundle?
>> Another approach was to stop the bundle with the compiled aspect inside.
>> it does not work, too. The tracing still is working. I think, the aspect
>> cached... Can I prevent this?
>> 2. I made a shutdown of the ogsi plattform and there are two different
>> 2.1 If I restart the product WITHOUT the parameter osgi.clean=true, the
>> needed bundles are started:
>> 4 ACTIVE org.eclipse.equinox.weaving.aspectj_188.8.131.52808061839
>> 5 ACTIVE org.eclipse.equinox.weaving.caching.j9_184.108.40.206808061839
>> 6 ACTIVE org.eclipse.equinox.weaving.caching_220.127.116.11808061839
>> My bundle with the aspect is also active. But I get severeal messages on
>> console which are like this one: "Info no configuration found. Disabling
>> weaver for bundler [...]".
>> I think, the aspect in one of my bundles cannot be found. At all, the
>> aspect does not work!
>> 2.2 If I restart the product WITH the parameter osgi.clean=true, I have
>> same situation as mentioned under point 1! The required bundles are not
>> What does it mean to me? I have always to start the osgi platform with
>> osgi.clean=true, so in this case I cannot have the advantage of osgi
>> caching. At all, we cannot rely on the equinox aspects. Maybe somebody can
>> help me to fix the problem.
>> Jens Goldhammer
>> fme AG
> equinox-dev mailing list