Uploaded image for project: 'Commons Modeler'
  1. Commons Modeler
  2. MODELER-17

[modeler] MbeansSource don't use args at mbeans and operations

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.1
    • Fix Version/s: 2.0
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: PC

    • Bugzilla Id:
      26493

      Description

      I missing the feature to set args at construct a mbean or calling a jmx-
      operation. A look inside MbeansSource and see that args parsed but not used.
      Ohh. OK, now a I have add this feature and add tag jmx-atttriute to set
      without construting a bean values to mbeans attributes.

      Peter
      s. added patch with Testcase and examples.

      PS: To strange things:
      a) all operation must have unique names, You can't have init() and init
      (String,String) as mbean operations.
      b) boolean is<Attribute> get-methode not found. currently only get<attribute>
      supported.
      c) missing mbean-instance.dtd

      Example script:

      <bean>

      <mbean name="Bean:type=Bean"
      code="org.apache.commons.modeler.modules.MyBean">
      <attribute name="name" value="Peter"/>
      </mbean>
      <jmx-attribute objectName="Bean:type=Bean"
      name="street"
      value="Am Jo"/>

      <jmx-operation objectName="Bean:type=Bean"
      operation="start"/>
      <mbean name="Bean:type=Bean2"
      code="org.apache.commons.modeler.modules.MyBean">
      </mbean>
      <jmx-operation objectName="Bean:type=Bean2"
      operation="setall">
      <arg type="java.lang.String" value="Peter"/>
      <arg type="java.lang.String">Am Jo</arg>
      </jmx-operation>

      <mbean name="Bean:type=Bean3"
      code="org.apache.commons.modeler.modules.MyBean">
      <arg type="java.lang.String" value="Peter"/>
      <arg type="java.lang.String">Am Jo</arg>
      </mbean>

      </bean>

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              pr@webapp.de Peter Rossbach
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: