[jboss-user] [EJB 3.0] - Interceptors per MDB

bfach do-not-reply at jboss.com
Thu Oct 2 08:44:36 EDT 2008


Hello,

I have setup my interceptor in such a fashion:

@AroundInvoke()
public Object onMessage(InvocationContext invocationContext) throws Exception{

Object result = invocationContext.proceed();
return result;

}

@MessageDriven
class MDBclass {


@Interceptors(RHMDBInterceptor.class)
public void onMessage(Message msg) {

// do something

}

}


This works fine however I want to have a seperate INSTANCE of a interceptor for each separate deployment of the MDB class that is listed in the deployment descriptors. As it is now, the interceptor intercepts all calls to on message for all EJBs.

I want an instance of the same interceptor for each MDB ejb deployment.

I have found a few things but they are all different ways and i haven't figured out how to make them work. Any hints on how i could do this would be greatly appreciated.

Thanks, 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4180012#4180012

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4180012



More information about the jboss-user mailing list