2 Replies Latest reply on Apr 16, 2003 7:09 PM by Sebastian Hauer

    Client side containter logging

    Sebastian Hauer Newbie

      Hi,

      Is there a client side log interceptor available and how if so how can I activate it for certain beans only? I am aware of org.jboss.ejb.plugins.LogInterceptor but this one is as far as I understand only used on the server side. I want to log all bean invocations on the client side, including name of the bean, method begin and method return. Does anyone know how to do this and how to activate it in jboss.xml for certain beans only?

      Regards,
      Sebastian

      PS: This is on JBoss 3.0.x

        • 1. Re: Client side containter logging
          Adrian Brock Master

          It is trivial.

          The config is different between
          jboss3.0 (container invoker) and
          jboss3.2 (invoker proxy binding)

          You write an interceptor like
          org.jboss.proxy.SecurityInterceptor and insert it
          into the client config of the ejb.

          Regards,
          Adrian

          • 2. Re: Client side containter logging
            Sebastian Hauer Newbie

            Thanks Adrian, I got my answer already from the mailing list and while doing some trial and error testing.
            This is the configuration I use to setup a single EJB using my client log interceptor:

            jboss.xml of UserDataReader EJB:


            <enterprise-beans>

            <ejb-name>UserDataReader</ejb-name>
            <jndi-name>UserDataReaderHome</jndi-name>
            <configuration-name>Xenon Clustered Stateless SessionBean</configuration-name>

            true

            </enterprise-beans>

            <container-configurations>
            <container-configuration extends="Clustered Stateless SessionBean">
            <container-name>Xenon Clustered Stateless SessionBean</container-name>
            <client-interceptors>


            org.jboss.proxy.ejb.StatelessSessionInterceptor

            org.jboss.proxy.SecurityInterceptor

            org.jboss.proxy.TransactionInterceptor

            <!-- This is my log interceptor --> com.sknt.proxy.ejb.LogInterceptor

            org.jboss.invocation.InvokerInterceptor

            </client-interceptors>
            </container-configuration>
            </container-configurations>



            This works for me running JBoss 3.0.7. Thought it might be helpful for others trying to set it up, so I post it here as well.

            Sebastian