9 Replies Latest reply on Jun 17, 2006 7:46 AM by Srikanth Doddaballapur

    Have you coded a cool MBean service you want to share?

    Dimitris Andreadis Master
        • 1. Re: Have you coded a cool MBean service you want to share?
          Ashok Kandasamy Shanmugam Newbie

          I would like to create new MBean service. But the above link is not provided proper inforamtion. I need proper information for creating new MBean service (ie: In which java class i will add my new code(new MBean service) and where shall i register this new MBean service(any xml file?)?)

          • 2. Re: Have you coded a cool MBean service you want to share?
            Dimitris Andreadis Master

            This is really meant for people that are "already" proficient with MBean Services. :)

            If you want to become one of them, start here:

            http://www.jboss.org/wiki/Wiki.jsp?page=JBossService
            http://www.jboss.org/wiki/Wiki.jsp?page=FAQJBossJMX

            • 3. Re: Have you coded a cool MBean service you want to share?
              Jimmy Wilson Apprentice

              I have an MBean service that I would like to share, and I have it all packaged and ready to use (with a README that can double as a Wiki). However, I do not seem to be able to edit the Wiki page provided.

              • 4. Re: Have you coded a cool MBean service you want to share?
                Jimmy Wilson Apprentice

                 

                "jiwils" wrote:
                I have an MBean service that I would like to share, and I have it all packaged and ready to use (with a README that can double as a Wiki). However, I do not seem to be able to edit the Wiki page provided.


                Not sure if this was due to my post or not, but the ability (for me anyway) to edit Wiki's has been restored.

                • 5. Re: Have you coded a cool MBean service you want to share?
                  Dimitris Andreadis Master

                  That was a temporary problem of the wiki, nothing personal :)

                  • 6. Re: Have you coded a cool MBean service you want to share?
                    Vivek Srivastav Newbie

                    I tried the UserAccounts service. When deployed it on 4.0.3SP1, it failed to deploy the org.ii.jaas.har archive. It expected the jboss-service.xml file to be present. After packaging hibernate-service.xml as META-INF/jboss-service.xml in the har file, I was able to deploy it. However when trying to list the users, it gives the following exception:

                    1:56:53,625 WARN [SessionFactoryObjectFactory] Not found: 4028400908e89e2a0108e8be3d450001
                    11:57:45,875 ERROR [[HtmlAdaptor]] Servlet.service() for servlet HtmlAdaptor threw exception
                    javax.management.RuntimeMBeanException
                     at org.jboss.mx.interceptor.ReflectedDispatcher.handleInvocationExceptions(ReflectedDispatcher.java:162)
                     at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:149)
                     at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
                     at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
                     at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:245)
                     at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:644)
                     at org.jboss.jmx.adaptor.control.Server.invokeOpByName(Server.java:243)
                     at org.jboss.jmx.adaptor.control.Server.invokeOp(Server.java:208)
                     at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.invokeOp(HtmlAdaptorServlet.java:247)
                     at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.processRequest(HtmlAdaptorServlet.java:85)
                     at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.doPost(HtmlAdaptorServlet.java:67)
                     at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
                     at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
                     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                     at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)
                     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                     at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                     at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
                     at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
                     at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:159)
                     at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:482)
                     at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
                     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
                     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
                     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
                     at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
                     at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
                     at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
                     at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
                     at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
                     at java.lang.Thread.run(Thread.java:595)
                    Caused by: java.lang.NullPointerException
                     at org.ii.UserAccountsService.getAccounts(UserAccountsService.java:383)
                     at org.ii.UserAccountsService.listAll(UserAccountsService.java:304)
                     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
                     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                     at java.lang.reflect.Method.invoke(Method.java:585)
                     at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
                     ... 31 more
                    11:57:47,343 INFO [Log4jService$URLWatchTimerTask] Configuring from URL: resource:log4j.xml
                    11:58:55,312 ERROR [[HtmlAdaptor]] Servlet.service() for servlet HtmlAdaptor threw exception
                    javax.management.InstanceNotFoundException: ii.org:service=UserAccounts is not registered.
                     at org.jboss.mx.server.registry.BasicMBeanRegistry.get(BasicMBeanRegistry.java:508)
                     at org.jboss.mx.server.MBeanServerImpl.getMBeanInfo(MBeanServerImpl.java:651)
                     at org.jboss.jmx.adaptor.control.Server.getMBeanData(Server.java:83)
                     at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.inspectMBean(HtmlAdaptorServlet.java:186)
                     at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.processRequest(HtmlAdaptorServlet.java:81)
                     at org.jboss.jmx.adaptor.html.HtmlAdaptorServlet.doGet(HtmlAdaptorServlet.java:62)
                     at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
                     at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
                     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                     at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:81)
                     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
                     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                     at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
                     at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
                     at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
                     at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:159)
                     at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:482)
                     at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
                     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
                     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
                     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
                     at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
                     at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
                     at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
                     at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
                     at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
                     at java.lang.Thread.run(Thread.java:595)
                    


                    When trying to login to the web using the forms-login-config. I get the following error:

                    12:11:24,937 INFO [TomcatDeployer] deploy, ctxPath=/OurTripToMadrid_May05, warUrl=.../deploy/OurTripToMadrid_May05.war/
                    12:12:15,906 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,906 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,906 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,921 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,921 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,921 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,937 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,937 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,937 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    12:12:15,937 ERROR [MyEntityResolver] Invalid PUBLIC ID: null
                    

                    Am I missing something or you have done all the testing only on a customized environment.

                    • 7. Re: Have you coded a cool MBean service you want to share?
                      Anshuman Atri Newbie

                      HI,
                      I am new to jboss.
                      I want to run a smtp server as a service for jboss application server something in the same fashion like how a JNDI server runs.
                      Can you help me to how to create a mbean so that I can run this as a part of jboss and manage it through the jmx console.

                      • 9. Re: Have you coded a cool MBean service you want to share?
                        Srikanth Doddaballapur Newbie

                        Hi,

                        Already posted but never got a reply ;(

                        I want to run my SessionBean afte doing some functionality in Start() method of my MBean.
                        But EJB just doesn't get deployed before MBean.
                        I have tried with tag. y jboss-serv ice.xml looks like this:

                        jboss.j2ee:service=EJB,jndiName=DrawResultsBean



                        But when run getting this error:
                        --- MBeans waiting for other MBeans ---
                        ObjectName: com.gameteclabs.bizlogic.workflow:service=CheckForDraw
                        State: CONFIGURED
                        I Depend On:
                        jboss.j2ee:service=EJB,jndiName=ejb/ADMDrawResults1Bean

                        --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
                        ObjectName: jboss.j2ee:service=EJB,jndiName=ejb/DrawResultsBean
                        State: NOTYETINSTALLED
                        Depends On Me:
                        com.gameteclabs.bizlogic.workflow:service=CheckForDraw

                        Please help me in solving this error. I am stuck for last 4 days ;(

                        Regards,