Re: [aspectwerkz-user] problem adding pointcut/advice

Frederic Simon <[email protected]> Thu, 02 Jun 2005 16:10:05 +0200
Newsgroups gmane.comp.java.aspectwerkz.user
Message-ID <[email protected]>
Just use "java.rmi.AccessException.detail" in a method that should be
weaved and it happens.

Alexandre Vasseur wrote:

Good that you spot it. Can you send a small piece of code that reproduce that ?
Thanks
Alex

On 6/2/05, Frederic Simon <[email protected]> wrote:

I'm having the same problem.
It looks like when there is a constant in an interface (field declared
in Interface) AspectWerkz is building the FieldInfo from
getDeclaredField of the class using the constant (since there is no
superclass just super interfaces), and so it fails (the field is in the
interface).

Anyway, I know that the code is ugly (Accessing constant field from
interface using inheritance -- VERY UGLY ins't it) but I didn't wrote it
and I need to weave it.

Is there a workaround?
Thanks in advance.

Brent Verner wrote:

[2005-03-28 23:35] Alexandru Popescu said:

| > Is there any significance to the "java.rmi.AccessException.detail" bit?
| > -- I know the method that I'm putting an advice on does some RMI at the
| > end of the day.

| The message is saying that the weaver is not able to determine the necessary information about a
| field named detail in the AccessException of type Throwable.

Right, and that field is a public member of AccessException's superclass
(RemoteException). Should the weaver be checking the superclass in this
case? Or does it already do that, implying that there is something weird
about my env. that is causing it to misbehave? If I have time tonight,
I might dig into AW to see if I can get this straightened out.

cheers.
Brent

--
------------------------
Frederic Simon - Technical Expert
AlphaCSP Israel

Phone: +972 9 7442080 * Fax: +972 9 7442082 * Mobile: +972 54 954301
7 Hataasiya St., POBox 2490, Raanana 43100, Israel
http://www.alphacsp.com/
------------------------

--

------------------------

Frederic Simon - Technical Expert

AlphaCSP Israel

Phone: +972 9 7442080 * Fax: +972 9 7442082 * Mobile: +972 54 954301

7 Hataasiya St., POBox 2490, Raanana 43100, Israel

http://www.alphacsp.com/

------------------------