Hi, after some more investigation, I skipped hope for a quick fix... :-(
Changing e.g. the SpringStepsFactory fixes only the step creation, but NOT the handling/matching logic. So this would need even more stuff to be fixed/changed. And thinking of unspecified behaviour when overriding method based annotations, I guess this needs more conceptual work to be done, before implementing some quick hacks... :-( I guess I'll give the AspectJ code weaving a try, instead of using Spring-AOP proxies... Mit freundlichen Grüßen Christian Zulehner Im Auftrag der Porsche Informatik GmbH [email protected] Porsche Informatik Gesellschaft m.b.H. | A – 5101 Bergheim | Handelszentrum 7 Sitz: Salzburg | FN 72830 d / Landesgericht Salzburg | DVR 88439 | UID ATU 36773309 http://www.porscheinformatik.at/ Von: Mauro Talevi <[email protected]> An: [email protected] Datum: 21.11.2011 14:36 Betreff: Re: [jbehave-user] Annotated methods and aspect orientation... Hi Christian, aop has not been a use case considered so far, so it may well be that it requires some updates to get it working. A Jira issue detailing the problem and a patch for it would be most welcome. Ideally, you should add both a unit test that reproduces the problem (in core if it affects AbstractStepsFactory) and an example (e.g. in trader-spring) that we can use as integration test. Cheers On Mon Nov 21 14:32:03 2011, Christian Zulehner wrote: > Hi all, > > currently I'm struggling to get JBehave to work together with aspect > orientated programming (AspectJ) and Spring. > > The problem seems to be, that the hasAnnotatedMethodsin > AbstractStepsFactoryis not able to discover methods, which are already > wrapped into an aspect proxy, e.g. logging, exception handling.. > > IIRC @Inherited only works for annotated types, adding this to the > @Give, @When, ... won't change anything. > So, my guess is to update the implementaiton of hasAnnotatedMethodsto > take super-methods into account... > > Did anyone had a similar problem? > Is this a known issue? > If so, should I file a Jira entry? (Together with a fix?) > > > > Mit freundlichen Grüßen > > Christian Zulehner > Im Auftrag der Porsche Informatik GmbH > > Porsche Informatik Gesellschaft m.b.H. | A – 5101 Bergheim | > Handelszentrum 7 > Sitz: Salzburg | FN 72830 d / Landesgericht Salzburg | DVR 88439 | UID > ATU 36773309 > _http://www.porscheinformatik.at/_ --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email
