6 Replies Latest reply on Feb 27, 2004 8:11 AM by rmaucher

    JMX-console problem in JBoss 3.2.3

    divine_comedy

      I was clicking a button ( an MBean operation ) when an error pops in in
      compiling the JSP. The error has something to do with the class below where a JSP page is trying to instantiate the class below by using the
      <jsp:useBean> which will fail since the class below has a no-args
      constructor.

      Anybody can pitch in on this ? Thanks. I can off course put in the no-args constructor myself but is this the intended use ?

      package org.jboss.console.plugins.helpers.jmx;

      /** A simple tuple of an mbean operation name, sigature and result.

      @author Scott.Stark@jboss.org
      @version $Revision: 1.1.2.1 $
      */
      public class OpResultInfo
      {
      public String name;
      public String[] signature;
      public Object result;

      public OpResultInfo(String name, String[] signature, Object result)
      {
      this.name = name;
      this.signature = signature;
      this.result = result;
      }
      }

        • 1. Re: JMX-console problem in JBoss 3.2.3
          dbeckedo2

          I've got the same problem trying to list JNDI info via the jmx-console (JBoss 3.2.3). I don't see any resolutions posted on this. Seems bizarre that something as basic as this would slip through the QA process.

          -David

          • 2. Re: JMX-console problem in JBoss 3.2.3

            Seems to work fine for me. What version of Tomcat are you using?

            • 3. Re: JMX-console problem in JBoss 3.2.3
              amayingenta

              Are you using Tomcat 5? We had the same problem. The fix (which just adds a no argument constructor) is checked into CVS and will be in JBoss 3.2.4.

              You could do what I did and fix it in a copy of the 3.2.3 source and just update the class in jmx-console.war.

              Seems like Jasper has changed how it creates instances of JavaBeans - it used to use java.beans.Beans.instantiate(), but now it uses the no-args constructor directly. The constructor should never get called as there should already be a copy of the bean in the Request.

              -Andrew

              • 4. Re: JMX-console problem in JBoss 3.2.3
                murxx

                I got the same problem here!
                Can you perhaps provide a compiled version of the fixed class?!
                I know that sounds lazy of me, but finding through the JBOSS CVS would take me half a day, and that's too much time. Or can you point me a quick way?!

                Thx in advance!

                (I'd be glad if you could mail it to me tim.adler(at)bertelsmann.de)

                • 5. Re: JMX-console problem in JBoss 3.2.3
                  murxx

                  Aww man, sorry I didn't say anything!
                  Managed it myself. Thought that thing had some big imports or stuff, but wasn't THAT difficult :)!

                  • 6. Re: JMX-console problem in JBoss 3.2.3
                    rmaucher

                     

                    "amayingenta" wrote:
                    Are you using Tomcat 5? We had the same problem. The fix (which just adds a no argument constructor) is checked into CVS and will be in JBoss 3.2.4.

                    You could do what I did and fix it in a copy of the 3.2.3 source and just update the class in jmx-console.war.

                    Seems like Jasper has changed how it creates instances of JavaBeans - it used to use java.beans.Beans.instantiate(), but now it uses the no-args constructor directly. The constructor should never get called as there should already be a copy of the bean in the Request.

                    -Andrew


                    The page was invalid. The new JSP spec now recommends throwing an exceptio at translation time, so that's what is done. The latest Jasper (will be in Tomcat 5.0.20) now has a flag in case it is better to disable this.