Hi Gurkan,

I see your note on dev@ that mentions you were able to get an interceptor-based OpenWebBeans integration working. Going to assume you found and fixed the interceptor issue you were having. Definitely let us know if you still need help.

-David

On Jul 15, 2009, at 9:10 AM, Gurkan Erdogdu wrote:

Hi;

I am trying to getting work of interceptors in Tomcat installation.

I have a simple stateless Bean

@Stateless
@Interceptors(value={MyInterceptor.class})
public class HelloBean implements Hello
{
   public String sayHello()
   {
       return "Hello";
   }
}

This is MyInterceptor

public class MyInterceptor
{
   @PostConstruct
public void afterConstruct(InvocationContext context) throws Exception
   {
       Object object = context.getTarget();

       System.out.println(object);

   }

   @AroundInvoke
public Object arounfInvoke(InvocationContext context) throws Exception
   {
       return context.proceed();
   }
}

But interceptors are not called. If I debug, in DeploymentInfo instance, InterceptorData exist with class MyInterceptor, but its post construct and
around invoke method lists are empty.

Is there anything that I missed?

Thanks;

--Gurkan

Reply via email to