Uploaded image for project: 'TomEE'
  1. TomEE
  2. TOMEE-1628

tomee.sh start registering MBean problem

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.7.2
    • Fix Version/s: 7.0.0-M1
    • Component/s: TomEE Core Server
    • Labels:
      None

      Description

      Whenever you run the tomee.sh start from bin/ directory you get the following exceptions in the log files. The problem is that registering MBean failes because of there is no default constructor in JMXReloadableEntityManagerFactory and TransactionManagerMBean classes. In fact, transaction manager and entity manager factories are already registered to MBean server but these exceptions gives wrong message to the user. Therefore, it is reasonable to register these MBeans under application object names.

      I attached the code that fixes the exception problem.

      Here is the exception when you start tomee.sh start:

      SEVERE: the mbean org.apache.openejb.assembler.classic.ReloadableEntityManagerFactory$JMXReloadableEntityManagerFactory can't be registered because it can't be instantiated
      java.lang.InstantiationException: org.apache.openejb.assembler.classic.ReloadableEntityManagerFactory$JMXReloadableEntityManagerFactory
      at java.lang.Class.newInstance(Class.java:364)
      at org.apache.openejb.assembler.classic.Assembler.deployMBean(Assembler.java:1428)
      at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:950)
      at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:658)
      at org.apache.openejb.assembler.classic.Assembler.buildContainerSystem(Assembler.java:549)
      at org.apache.openejb.assembler.classic.Assembler.build(Assembler.java:445)
      at org.apache.openejb.OpenEJB$Instance.<init>(OpenEJB.java:150)
      at org.apache.openejb.OpenEJB.init(OpenEJB.java:298)
      at org.apache.openejb.server.Server.init(Server.java:65)
      at org.apache.openejb.server.Main.initServer(Main.java:154)
      at org.apache.openejb.server.Main.main(Main.java:128)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.apache.openejb.cli.MainImpl.main(MainImpl.java:148)
      at org.apache.openejb.cli.Bootstrap.main(Bootstrap.java:106)

      Aug 30, 2015 12:02:19 AM org.apache.openejb.assembler.classic.Assembler deployMBean
      INFO: Deployed MBean(openejb.user.mbeans:application=openejb-core-4.7.3-SNAPSHOT,group=org.apache.openejb.assembler.monitoring,name=JMXDeployer)
      Aug 30, 2015 12:02:31 AM org.apache.openejb.assembler.classic.Assembler deployMBean
      SEVERE: the mbean org.apache.openejb.resource.GeronimoTransactionManagerFactory$TransactionManagerMBean can't be registered because it can't be instantiated
      java.lang.InstantiationException: org.apache.openejb.resource.GeronimoTransactionManagerFactory$TransactionManagerMBean
      at java.lang.Class.newInstance(Class.java:364)
      at org.apache.openejb.assembler.classic.Assembler.deployMBean(Assembler.java:1428)
      at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:950)
      at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:658)
      at org.apache.openejb.assembler.classic.Assembler.buildContainerSystem(Assembler.java:549)
      at org.apache.openejb.assembler.classic.Assembler.build(Assembler.java:445)
      at org.apache.openejb.OpenEJB$Instance.<init>(OpenEJB.java:150)
      at org.apache.openejb.OpenEJB.init(OpenEJB.java:298)
      at org.apache.openejb.server.Server.init(Server.java:65)
      at org.apache.openejb.server.Main.initServer(Main.java:154)
      at org.apache.openejb.server.Main.main(Main.java:128)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.apache.openejb.cli.MainImpl.main(MainImpl.java:148)
      at org.apache.openejb.cli.Bootstrap.main(Bootstrap.java:106)

        Attachments

        1. TOMEE_1628.patch
          7 kB
          Gurkan Erdogdu

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              gerdogdu Gurkan Erdogdu
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: