1 Reply Latest reply on Jun 15, 2004 2:18 PM by raja05

    deploy mbean in jboss

    pedrosalazar

      Greetings,

      I would like to know how to deploy a mbean in jboss:

      - Should I edit the ${JBOSS_HOME}/*/conf/jboss-service.xm, and add my bean configuration there having my mbean jar in ${JBOSS_HOME}/*/lib/ directory?

      I think the approach above works only for start/shutdown of jboss and is not suitable for hotdeploy of mbeans (imagine I must deploy a new mbean - a restart of jboss could be pain).

      - In alternative I read something about the jboss-service_3_2.dtd. Can I deploy my custom mbean on ${JBOSS_HOME}/*/deploy/ as *-service.xml, which I supose the hot deploy should work, I suppose. And where should I deploy the jar files?

      Are these thoughs correct?

      BTW, what are the MLETs?

      Thanks,
      Pedro Salazar

        • 1. Re: deploy mbean in jboss
          raja05

          You can create a .sar file which has a META-INF/jboss-service.xml that defines your mbean. You could then jar up the files that make up ur MBean and package that in the sar as well. so ur SAR structure wud be something like
          SAR File
          MBeans.jar
          META-INF
          jboss-service.xml


          You could also deploy this unpacked in the same structure, just that the directory name has to end with ".sar".. Checkout the deploy directory in jboss for any examples. Basically anything thast in the deploy dir is hot-deployable.