5 Replies Latest reply on Jun 21, 2013 8:06 PM by ron_sigal

    JBoss 4.2.1 EJB 3.0 compression marshalling

    marcanthony

      Hi All

      I found thread 111378 and tried to enable compression marshalling but it doesn't seem to work. I have extended org.jboss.remoting.marshal.compress.CompressingUnMarshaller and org.jboss.remoting.marshal.compress.CompressingMarshaller with my own classes that have overridden implementations that print the size of the objects that are passed in to be serialized but for some reason the execution never reaches my code.

       

      this is my config,

       

      
      socket://${jboss.bind.address}:3873/?marshaller=MYCompressingMarshaller&unmarshaller=MYCompressingUnMarshaller
      
      

       

      my classes are packaged in a jar and made available to client and server

       

      thanks

       

      Marc

        • 1. Re: JBoss 4.2.1 EJB 3.0 compression marshalling
          ron_sigal

          Hi Marc,

           

          Which version of Remoting 2 are you using?  IIRC, there were problems in the compression marshaller/unmarshaller that eventually got straightened out.  New versions of Remoting 2 are meant to be compatible with older versions, so upgrading shouldn't be a problem.

           

          -Ron

          • 2. Re: JBoss 4.2.1 EJB 3.0 compression marshalling
            marcanthony

            Hi Ron

             

            thanks for getting back to me, eventually I got it working with jboss-remoting-2_5_4_SP4, less data is sent across the network, but when i shutdown the server I get a warning followed by an exception:

             

            WARN  [ServiceController] Problem stopping service jboss.remoting:type=Connector,name=DefaultEjb3Connector,handler=ejb3

            java.lang.NoSuchFieldError: m_map

                at org.jboss.remoting.transport.socket.LRUPool.getContents(LRUPool.java:81)

                at org.jboss.remoting.transport.socket.SocketServerInvoker.cleanup(SocketServerInvoker.java:460)

             

            ERROR [Connector] invalid Object Name

            javax.management.InstanceNotFoundException: jboss.remoting:service=invoker,transport=socket,host=MYMACHINE,port=3873,marshaller=org.jboss.remoting.marshal.compress.CompressingMarshaller

             

            I dont thinks it is a problem but was curious, I tried to debug but the field m_map exists...

             

            A quick question , how do I achieve compression for ejb 3.0 in jboss 7.1.1

             

            thanks

             

            Marc

            • 3. Re: JBoss 4.2.1 EJB 3.0 compression marshalling
              ron_sigal

              Hi Marc,

               

              I'm glad you solved the problem.

               

              As for the m_map field, I don't know what that's about.  org.jboss.remoting.transport.socket.LRUPool is derived from a class, org.jboss.util.LRUCachePolicy, that comes from an external jar, jboss-common-core.jar.  Remoting 2.5.4.SP4 is built against version 2.2.16.GA of jboss-common-core.jar.  Maybe there's incompatibility with the version you're using. 

               

              -Ron

              • 4. Re: JBoss 4.2.1 EJB 3.0 compression marshalling
                marcanthony

                Hi Ron

                 

                I will check out jboss-common-core.jar and see what I find, thanks for pointing me in the right direction.

                 

                Any advice for ejb 3 compression on JBoss 7.1.1 ?

                 

                thanks

                 

                Marc

                • 5. Re: JBoss 4.2.1 EJB 3.0 compression marshalling
                  ron_sigal

                  Hi Marc,

                   

                  JBoss AS 7.x uses Remoting 3, which is a whole separate code base.  I don't know much about it, to tell the truth.  Don't think there's much documentation, yet, either.'

                   

                  You could try posting the question on the EJB3 forum (https://community.jboss.org/en/ejb3) or the AS 7 forum (https://community.jboss.org/en/jbossas7).

                   

                  -Ron