Re: Dynamic configuration
Jonas Bonér <[email protected]> Wed, 07 May 2003 15:41:36 +0200
| Newsgroups | gmane.comp.java.aspectwerkz |
|---|---|
| Message-ID | <[email protected]> |
Hi again.
I forgot to tell you that you can retrieve the pointcuts for a certain
method/field like this:
// first create a MethodMetaData object holding info. about the method
(similar usage with fields)
// retrieve all the pointcuts for the method specified
MethodPointcut[] pointcuts = AspectWerkz.getAspect("test.MyClass").
getMethodPointcut(MethodMetaData metaData);
// do stuff...
Vincent Tencé wrote:
> Thats' great!
>
> I am looking forward to that release. In the meantime, could you give me
> some details of how the new dynamic feature work?
>
> Thanks,
> -- Vincent
>
>
>>-----Original Message-----
>>From: Jonas Bonér [mailto:[email protected]]
>>Sent: Wednesday, May 07, 2003 07:27
>>To: Vincent Tencé
>>Cc: [email protected]
>>Subject: Re: [aspectwerkz-developer] Dynamic configuration
>>
>>
>>Hi Vincent.
>>
>>Today I implemented the feature of being able to add completely new
>>advices at runtime. This will be included in the next official release
>>(this or next week).
>>
>>If you (after a while) are feeling constraint in what you want to be
>>able to do, just drop me an email telling me know what you need and we
>>can have a talk about it.
>>
>>It is in my highest interest to make AspectWerkz a *very*
>>dynamic framework.
>>
>>Sincerely, Jonas.
>>
>>
>>Vincent Tencé wrote:
>>
>>>Jonas Bonér wrote:
>>>
>>>
>>>>The advices can be dynamically be added, rearranged and removed at
>>>>runtime without reloading your classes. (See the docs:
>>>>[http://aspectwerkz.sourceforge.net/documentation.html#Hot%20d
>>>>eployment].)
>>>>
>>>>The limitation is that you can only do this at pointcuts that has
>>>>already been advised. I.e. you have to know the places where
>>>>you want to
>>>>be able to handle the advices dynamically. (Either you know
>>>>these points
>>>>or you have to be *very* generous when defining your pointcuts.)
>>>>
>>>>If you reload your classes at runtime then you should as well
>>>>be able to
>>>>change the pointcuts, e.g. transform your classes according to a
>>>>modified XML defininition. This since the framework reloads the
>>>>definition file as soon as it has been updated (or the
>>>>attributes if you
>>>>are using runtime attributes). This feature I have not had
>>>>the time to
>>>>test thoroughly.
>>>
>>>
>>>Thanks for the pointer.
>>>
>>>I guess I can get around this in a first phase by generating the
>>>config file on the fly then loading/reloading the framework.
>>>
>>>
>>>
>>>>I don't know if this is sufficient for you.
>>>
>>>
>>>At some point, I will look into adding the ability to specify
>>>aspects using the API. Any thoughts/issues on/with that?
>>>
>>>Thanks,
>>>-- Vincent
>>>
>>>
>>>
>>>-------------------------------------------------------
>>>Enterprise Linux Forum Conference & Expo, June 4-6, 2003,
>>
>>Santa Clara
>>
>>>The only event dedicated to issues related to Linux
>>
>>enterprise solutions
>>
>>>www.enterpriselinuxforum.com
>>>
>>>_______________________________________________
>>>aspectwerkz-developer mailing list
>>>[email protected]
>>>https://lists.sourceforge.net/lists/listinfo/aspectwerkz-developer
>>>
>>>
>>
>>
>>--
>>Jonas
>>http://freeroller.net/page/jboner
>>
>>
>>
>>
>>
>
>
>
>
> -------------------------------------------------------
> Enterprise Linux Forum Conference & Expo, June 4-6, 2003, Santa Clara
> The only event dedicated to issues related to Linux enterprise solutions
> www.enterpriselinuxforum.com
>
> _______________________________________________
> aspectwerkz-developer mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/aspectwerkz-developer
>
>
--
Jonas
http://freeroller.net/page/jboner
-------------------------------------------------------
Enterprise Linux Forum Conference & Expo, June 4-6, 2003, Santa Clara
The only event dedicated to issues related to Linux enterprise solutions
www.enterpriselinuxforum.com