camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <claus.ib...@gmail.com>
Subject Re: Giving anonymous processors an identity - is there an annoation for that?
Date Fri, 08 Oct 2010 11:45:00 GMT
Hi

Maybe we should make sure you can use .id("xxx") as the rest of the
DSL with an inlined anonym as well.
I actually don't know if you can do that. But I can check it out :)



On Fri, Oct 8, 2010 at 12:31 PM, Ade <adrian.trenaman@googlemail.com> wrote:
>
> Is it possible to give an anonymous inline Processor an identity using a Java
> annotation? Am thinking that this would be great for trace or audit
> purposes, where you want a tracer or interceptor to log/audit that a
> particular processor on the route has been invoked.
>
> I'm not sure if you can put an annotation on an inline anonymous class;
> however, we could perhaps simply annotate the process() method. Something
> like this:
>
>
> from("...")
>  .process(new Processor() {
>    @Processor(label = "doImportantStuff")
>    public void process(Exchange ex) throws Exception {
>    }
>  });
>
>
> Does such an annotation exist in Camel? If not, then do you think this is a
> good idea?
> --
> View this message in context: http://camel.465427.n5.nabble.com/Giving-anonymous-processors-an-identity-is-there-an-annoation-for-that-tp3204380p3204380.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>



-- 
Claus Ibsen
Apache Camel Committer

Author of Camel in Action: http://www.manning.com/ibsen/
Open Source Integration: http://fusesource.com
Blog: http://davsclaus.blogspot.com/
Twitter: http://twitter.com/davsclaus

Mime
View raw message