geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rwo...@apache.org
Subject svn commit: r834802 - in /geronimo/sandbox/rex: M2_REPO/ M2_REPO/org/ M2_REPO/org/osgi/ M2_REPO/org/osgi/org.osgi.jmx/ M2_REPO/org/osgi/org.osgi.jmx/1.0/ org.apache.geronimo.blueprint.jmx/ org.apache.geronimo.blueprint.jmx/src/ org.apache.geronimo.blue...
Date Wed, 11 Nov 2009 08:46:42 GMT
Author: rwonly
Date: Wed Nov 11 08:46:41 2009
New Revision: 834802

URL: http://svn.apache.org/viewvc?rev=834802&view=rev
Log:
Blueprint MBean initialization

Added:
    geronimo/sandbox/rex/M2_REPO/
    geronimo/sandbox/rex/M2_REPO/org/
    geronimo/sandbox/rex/M2_REPO/org/osgi/
    geronimo/sandbox/rex/M2_REPO/org/osgi/org.osgi.jmx/
    geronimo/sandbox/rex/M2_REPO/org/osgi/org.osgi.jmx/1.0/
    geronimo/sandbox/rex/M2_REPO/org/osgi/org.osgi.jmx/1.0/org.osgi.jmx-1.0.jar   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/pom.xml   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/jmx/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/jmx/BlueprintStateMBean.java
  (with props)

Added: geronimo/sandbox/rex/M2_REPO/org/osgi/org.osgi.jmx/1.0/org.osgi.jmx-1.0.jar
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/M2_REPO/org/osgi/org.osgi.jmx/1.0/org.osgi.jmx-1.0.jar?rev=834802&view=auto
==============================================================================
Binary file - no diff available.

Propchange: geronimo/sandbox/rex/M2_REPO/org/osgi/org.osgi.jmx/1.0/org.osgi.jmx-1.0.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/pom.xml?rev=834802&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/pom.xml (added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/pom.xml Wed Nov 11 08:46:41 2009
@@ -0,0 +1,18 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.apache.geronimo.blueprint</groupId>
+  <artifactId>org.apache.geronimo.blueprint.jmx</artifactId>
+  <packaging>jar</packaging>
+  <version>1.0-SNAPSHOT</version>
+  
+  <name>org.apache.geronimo.blueprint.jmx</name>
+  
+  <dependencies>
+    <dependency>
+      <groupId>org.osgi</groupId>
+      <artifactId>org.osgi.jmx</artifactId>
+      <version>1.0</version>
+    </dependency>
+  </dependencies>
+</project>

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/jmx/BlueprintStateMBean.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/jmx/BlueprintStateMBean.java?rev=834802&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/jmx/BlueprintStateMBean.java
(added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/jmx/BlueprintStateMBean.java
Wed Nov 11 08:46:41 2009
@@ -0,0 +1,841 @@
+package org.apache.geronimo.blueprint.jmx;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeType;
+import javax.management.openmbean.SimpleType;
+import javax.management.openmbean.TabularData;
+
+import org.osgi.jmx.Item;
+import org.osgi.jmx.JmxConstants;
+/**
+ * This MBean provides the management interface to the OSGi Blueprint Service.
+ * 
+ * @version $Revision: 1 $
+ */
+public interface BlueprintStateMBean {
+    /**
+     * The object name for this mbean.
+     */
+    String OBJECTNAME = JmxConstants.OSGI_COMPENDIUM+":service=blueprint,version=1.0";
+    
+    ///////////////////////////////////////////////////////////////
+    // Define Component's CompositeType
+    // <bean>, <service> & Service Reference's CompositeType will 
+    // extend this.
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key COMPONENT_ID, used in {@link #COMPONENT_ID_ITEM}.
+     */
+    String          COMPONENT_ID                    = "ComponentId";
+
+    /**
+     * The item containing the component id of a component. 
+     * The key is {@link #COMPONENT_ID}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            COMPONENT_ID_ITEM       = new Item(
+                                                    COMPONENT_ID,
+                                                    "The id of the component",
+                                                    SimpleType.STRING);
+    /**
+     * The key ACTIVATION, used in {@link #ACTIVATION_ITEM}.
+     */
+    String          ACTIVATION              = "Activation";
+    
+    /**
+     * The item containing the activation strategy for a component. 
+     * The key is {@link #ACTIVATION}, and the type is {@link SimpleType#INTEGER}.
+     */
+    Item            ACTIVATION_ITEM         = new Item(
+                                                    ACTIVATION,
+                                                    "",
+                                                    SimpleType.INTEGER);
+    
+    /**
+     * The key DEPENDS_ON, used in {@link #DEPENDS_ON_ITEM}.
+     */
+    String          DEPENDS_ON              = "DependsOn";
+    
+    /**
+     * The item containing the ids of any components listed in a <code>depends-on</code>
attribute for the component. 
+     * The key is {@link #DEPENDS_ON}, and the type is {@link JmxConstants#STRING_ARRAY_TYPE}.
+     */
+    Item            DEPENDS_ON_ITEM         = new Item(
+                                                    DEPENDS_ON,
+                                                    "",
+                                                    JmxConstants.STRING_ARRAY_TYPE);
+    
+    /**
+     * The CompositeType for a ComponentMetadata object, it contains 
+     * the following items:
+     * <ul>
+     * <li>{@link #COMPONENT_ID}</li>
+     * <li>{@link #ACTIVATION}</li>
+     * <li>{@link #DEPENDS_ON}</li>
+     * </ul>
+     */
+    CompositeType   COMPONENT_METADATA_TYPE = Item.compositeType(
+                                                    "ComponentMetadata",
+                                                    "",
+                                                    COMPONENT_ID_ITEM,
+                                                    ACTIVATION_ITEM,
+                                                    DEPENDS_ON_ITEM);
+                            
+    ///////////////////////////////////////////////////////////////
+    // Define <bean>'s CompositeType
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key CLASS_NAME, used in {@link #CLASS_NAME_ITEM}.
+     */
+    String          CLASS_NAME              = "ClassName";
+    
+    /**
+     * The item containing the name of the class specified for the bean. 
+     * The key is {@link #CLASS_NAME}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            CLASS_NAME_ITEM         = new Item(
+                                                    CLASS_NAME,
+                                                    "",
+                                                    SimpleType.STRING
+                                                    );
+    
+    /**
+     * The key INIT_METHOD, used in {@link #INIT_METHOD_ITEM}.
+     */
+    String          INIT_METHOD             = "InitMethod";
+    
+    /**
+     * The item containing the name of the init method specified for the bean.
+     * The key is {@link #INIT_METHOD}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            INIT_METHOD_ITEM        = new Item(
+                                                    INIT_METHOD, 
+                                                    "", 
+                                                    SimpleType.STRING);
+    
+    /**
+     * The key DESTROY_METHOD, used in {@link #DESTROY_METHOD_ITEM}.
+     */
+    String          DESTROY_METHOD          = "DestroyMethod";
+    
+    /**
+     * The item containing the name of the destroy method specified for the bean.
+     * The key is {@link #DESTROY_METHOD}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            DESTROY_METHOD_ITEM     = new Item(
+                                                    DESTROY_METHOD, 
+                                                    "", 
+                                                    SimpleType.STRING);
+
+    /**
+     * The key FACTORY_METHOD, used in {@link #FACTORY_METHOD_ITEM}.
+     */
+    String          FACTORY_METHOD          = "FactoryMethod";
+    
+    /**
+     * The item containing the name of the factory method specified for the bean.
+     * The key is {@link #FACTORY_METHOD}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            FACTORY_METHOD_ITEM     = new Item(
+                                                    FACTORY_METHOD, 
+                                                    "", 
+                                                    SimpleType.STRING);
+    
+    /**
+     * The key FACTORY_COMPONENT, used in {@link #FACTORY_COMPONENT_ITEM}.
+     */
+    String          FACTORY_COMPONENT       = "FactoryComponent";
+    
+    /**
+     * The item containing the id of the factory component on which to invoke the factory
method for the bean.
+     * The key is {@link #FACTORY_COMPONENT}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            FACTORY_COMPONENT_ITEM  = new Item(
+                                                    FACTORY_COMPONENT, 
+                                                    "", 
+                                                    SimpleType.STRING);
+    
+    /**
+     * The key SCOPE, used in {@link #SCOPE_ITEM}.
+     */
+    String          SCOPE                   = "Scope";
+    
+    /**
+     * The item containing the scope for the bean.
+     * The key is {@link #SCOPE}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            SCOPE_ITEM              = new Item(
+                                                    SCOPE, 
+                                                    "", 
+                                                    SimpleType.STRING);
+
+    /**
+     * The CompositeType for a BeanMetadata object, it extends {@link #COMPONENT_METADATA_TYPE}

+     * and adds the following items:
+     * <ul>
+     * <li>{@link #CLASS_NAME}</li>
+     * <li>{@link #INIT_METHOD}</li>
+     * <li>{@link #DESTROY_METHOD}</li>
+     * <li>{@link #FACTORY_METHOD}</li>
+     * <li>{@link #FACTORY_COMPONENT}</li>
+     * <li>{@link #SCOPE}</li>
+     * </ul>
+     */
+    CompositeType   BEAN_METADATA_TYPE      = Item.extend(
+                                                    COMPONENT_METADATA_TYPE, 
+                                                    "BeanMetadata", 
+                                                    "",
+                                                    CLASS_NAME_ITEM,
+                                                    INIT_METHOD_ITEM,
+                                                    DESTROY_METHOD_ITEM, 
+                                                    FACTORY_METHOD_ITEM,
+                                                    FACTORY_COMPONENT_ITEM,
+                                                    SCOPE_ITEM);
+    
+    ///////////////////////////////////////////////////////////////
+    // Define <service>'s CompositeType
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key INTERFACES, used in {@link #INTERFACES_ITEM}.
+     */
+    String          INTERFACES              = "Interfaces";
+    
+    /**
+     * The item containing the type names of the interfaces that the service should be advertised
as supporting.
+     * The key is {@link #INTERFACES}, and the type is {@link JmxConstants#STRING_ARRAY_TYPE}.
+     */
+    Item            INTERFACES_ITEM         = new Item(
+                                                    INTERFACES, 
+                                                    "", 
+                                                    JmxConstants.STRING_ARRAY_TYPE);
+    /**
+     * The key AUTO_EXPORT, used in {@link #AUTO_EXPORT_ITEM}.
+     */
+    String          AUTO_EXPORT             = "AutoExport";
+    
+    /**
+     * The item containing the auto-export mode for the service.
+     * The key is {@link #AUTO_EXPORT}, and the type is {@link SimpleType#INTEGER}.
+     */
+    Item            AUTO_EXPORT_ITEM        = new Item(
+                                                    AUTO_EXPORT, 
+                                                    "", 
+                                                    SimpleType.INTEGER);
+
+    /**
+     * The key RANKING, used in {@link #RANKING_ITEM}.
+     */
+    String          RANKING                 = "Ranking";
+    
+    /**
+     * The item containing the ranking value to use when advertising the service.
+     * The key is {@link #RANKING}, and the type is {@link SimpleType#INTEGER}.
+     */
+    Item            RANKING_ITEM            = new Item(
+                                                    RANKING, 
+                                                    "", 
+                                                    SimpleType.INTEGER);
+
+    /**
+     * The key SERVICE_COMPONENT, used in {@link #SERVICE_COMPONENT_ITEM}.
+     */
+    String          SERVICE_COMPONENT       = "ServiceComponent";
+    
+    /**
+     * The item containing the id of the component to be exported as a service.
+     * The key is {@link #SERVICE_COMPONENT}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            SERVICE_COMPONENT_ITEM  = new Item(
+                                                    SERVICE_COMPONENT, 
+                                                    "", 
+                                                    SimpleType.STRING);
+    
+    /**
+     * The CompositeType for a ServiceMetadata object, it extends {@link #COMPONENT_METADATA_TYPE}
+     * and adds the following items:
+     * <ul>
+     * <li>{@link #INTERFACES}</li>
+     * <li>{@link #AUTO_EXPORT}</li>
+     * <li>{@link #RANKING}</li>
+     * <li>{@link #SERVICE_COMPONENT}</li>
+     * </ul>
+     */
+    CompositeType   SERVICE_MATADATA_TYPE        = Item.extend(
+                                                    COMPONENT_METADATA_TYPE, 
+                                                    "ServiceMetadata", 
+                                                    "", 
+                                                    INTERFACES_ITEM,
+                                                    AUTO_EXPORT_ITEM,
+                                                    RANKING_ITEM,
+                                                    SERVICE_COMPONENT_ITEM);
+
+    ///////////////////////////////////////////////////////////////
+    // Define Service Reference's CompositeType, 
+    // <reference> & <reference-list> will extend this
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key AVAILABILITY, used in {@link #AVAILABILITY_ITEM}.
+     */
+    String          AVAILABILITY            = "Availability";
+    
+    /**
+     * The item containing whether or not a matching service is required at all times.
+     * The key is {@link #AVAILABILITY}, and the type is {@link SimpleType#INTEGER}.
+     */
+    Item            AVAILABILITY_ITEM       = new Item(
+                                                    AVAILABILITY, 
+                                                    "", 
+                                                    SimpleType.INTEGER);
+    
+    /**
+     * The key INTERFACE, used in {@link #INTERFACE_ITEM}.
+     */
+    String          INTERFACE               = "Interface";
+    
+    /**
+     * The item containing the name of the interface type that a matching service must support.
+     * The key is {@link #INTERFACE}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            INTERFACE_ITEM          = new Item(
+                                                    INTERFACE, 
+                                                    "", 
+                                                    SimpleType.STRING);
+    
+    /**
+     * The key COMPONENT_NAME, used in {@link #COMPONENT_NAME_ITEM}.
+     */
+    String          COMPONENT_NAME          = "ComponentName";
+    
+    /**
+     * The item containing the value of the <code>component-name</code> attribute
of the service reference.
+     * The key is {@link #INTERFACE}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            COMPONENT_NAME_ITEM     = new Item(
+                                                    COMPONENT_NAME, 
+                                                    "", 
+                                                    SimpleType.STRING);
+    /**
+     * The key FILTER, used in {@link #FILTER_ITEM}.
+     */
+    String          FILTER                  = "Filter";
+    
+    /**
+     * The item containing the filter expression that a matching service must match.
+     * The key is {@link #FILTER}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            FILTER_ITEM             = new Item(
+                                                    FILTER, 
+                                                    "", 
+                                                    SimpleType.STRING);
+    
+    /**
+     * The CompositeType for a ServiceReferenceMetadata object, it extends 
+     * {@link #COMPONENT_METADATA_TYPE} and adds the following items:
+     * <ul>
+     * <li>{@link #AVAILABILITY}</li>
+     * <li>{@link #INTERFACE}</li>
+     * <li>{@link #COMPONENT_NAME}</li>
+     * <li>{@link #FILTER}</li>
+     * </ul>
+     */
+    CompositeType   SERVICE_REFERENCE_METADATA_TYPE  = Item.extend(
+                                                    COMPONENT_METADATA_TYPE, 
+                                                    "ServiceReferenceMetadata", 
+                                                    "", 
+                                                    AVAILABILITY_ITEM,
+                                                    INTERFACE_ITEM,
+                                                    COMPONENT_NAME_ITEM,
+                                                    FILTER_ITEM);
+    
+    ///////////////////////////////////////////////////////////////
+    // Define <reference>'s CompositeType
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key TIME_OUT, used in {@link #TIMEOUT_ITEM}.
+     */
+    String          TIMEOUT                = "TimeOut";
+    
+    /**
+     * The item containing the timeout for service invocations when a backing service is
is unavailable.
+     * The key is {@link #TIMEOUT}, and the type is {@link SimpleType#LONG}.
+     */
+    Item            TIMEOUT_ITEM           = new Item(
+                                                    TIMEOUT, 
+                                                    "", 
+                                                    SimpleType.LONG);
+    /**
+     * The CompositeType for a ReferenceMetadata object, it extends 
+     * {@link #SERVICE_REFERENCE_METADATA_TYPE} and adds the following items:
+     * <ul>
+     * <li>{@link #TIMEOUT}</li>
+     * </ul>
+     */
+    CompositeType   REFERENCE_METADATA_TYPE = Item.extend(
+                                                    SERVICE_REFERENCE_METADATA_TYPE, 
+                                                    "ReferenceMetadata", 
+                                                    "", 
+                                                    TIMEOUT_ITEM);
+    
+    ///////////////////////////////////////////////////////////////
+    // Define <reference-list>'s CompositeType
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key MEMBER_TYPE, used in {@link #MEMBER_TYPE_ITEM}.
+     */
+    String          MEMBER_TYPE             = "MemberType";
+    
+    /**
+     * The item containing whether the List will contain service object proxies or ServiceReference
objects.
+     * The key is {@link #MEMBER_TYPE}, and the type is {@link SimpleType#INTEGER}.
+     */
+    Item            MEMBER_TYPE_ITEM        = new Item(
+                                                    MEMBER_TYPE, 
+                                                    "", 
+                                                    SimpleType.INTEGER);
+    
+    /**
+     * The CompositeType for a ReferenceListMetadata object, it extends 
+     * {@link #SERVICE_REFERENCE_METADATA_TYPE} and adds the following items:
+     * <ul>
+     * <li>{@link #MEMBER_TYPE}</li>
+     * </ul>
+     */
+    CompositeType   REFERENCE_LIST_METADATA_TYPE = Item.extend(
+                                                    SERVICE_REFERENCE_METADATA_TYPE, 
+                                                    "ReferenceListMetadata", 
+                                                    "", 
+                                                    MEMBER_TYPE_ITEM);
+                                                    
+    ///////////////////////////////////////////////////////////////
+    // Define <value>'s CompositeType, has not been used yet
+    // also should add more CompositeType for <ref>, <idref>...
+    ///////////////////////////////////////////////////////////////
+    
+//    /**
+//     * The key STRING_VALUE, used in {@link #STRING_VALUE_ITEM}.
+//     */
+//    String          STRING_VALUE            = "StringValue";
+//    
+//    /**
+//     * The item containing the un-converted string representation of the value.
+//     * The key is {@link #STRING_VALUE}, and the type is {@link SimpleType#STRING}.
+//     */
+//    Item            STRING_VALUE_ITEM       = new Item(
+//                                                    STRING_VALUE, 
+//                                                    "", 
+//                                                    SimpleType.STRING);
+//    
+//    /**
+//     * The key TYPE, used in {@link #TYPE_ITEM}.
+//     */
+//    String          TYPE                    = "Type";
+//    
+//    /**
+//     * The item containing the name of the type to which the value should be converted.
+//     * The key is {@link #TYPE}, and the type is {@link SimpleType#STRING}.
+//     */
+//    Item            TYPE_ITEM               = new Item(
+//                                                    TYPE, 
+//                                                    "", 
+//                                                    SimpleType.STRING);
+//    
+//    /**
+//     * The CompositeType for a ValueMetadata object. It contains the following items:
+//     * <ul>
+//     * <li>{@link #STRING_VALUE}</li>
+//     * <li>{@link #TYPE}</li>
+//     * </ul>
+//     */
+//    CompositeType   VALUE_METADATA_TYPE     = Item.compositeType(
+//                                                    "ValueMetadata", 
+//                                                    "", 
+//                                                    STRING_VALUE_ITEM, 
+//                                                    TYPE_ITEM);                  
+    
+    ///////////////////////////////////////////////////////////////
+    // Define Generic CompositeType
+    // which represents the compositeData of this type is actually 
+    // the data of <value>, <ref>, <idref>, <map>, Collectoins, <props>
CompositeType
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The CompositeType for a generic metadata
+     */
+    CompositeType   GENERIC_METADATA_TYPE           = Item.compositeType("GenericMetaData",
"", new Item[0]);
+    
+    /**
+     * The key GENERIC_VALUE, used in {@link #GENERIC_VALUE_ITEM}.
+     */
+    String          GENERIC_VALUE                   = "GenericValue";
+        
+    /**
+     * The item containing the Metadata for the argument value.
+     * The key is {@link #VALUE}, and the type is {@link METADATA_TYPE}.
+     */
+    Item            GENERIC_VALUE_ITEM       = new Item(
+                                                    GENERIC_VALUE, 
+                                                    "", 
+                                                    GENERIC_METADATA_TYPE);
+    
+    ///////////////////////////////////////////////////////////////
+    // Define <argument>'s CompositeType
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key INDEX, used in {@link #INDEX_ITEM}.
+     */
+    String          INDEX                   = "Index";
+    
+    /**
+     * The item containing the zero-based index into the parameter list of
+     * the factory method or constructor to be invoked for this argument.
+     * The key is {@link #INDEX}, and the type is {@link SimpleType#INTEGER}.
+     */
+    Item            INDEX_ITEM              = new Item(
+                                                    INDEX, 
+                                                    "", 
+                                                    SimpleType.INTEGER);
+
+    /**
+     * The key VALUE_TYPE, used in {@link #VALUE_TYPE_ITEM}.
+     */
+    String          VALUE_TYPE              = "ValueType";
+    
+    /**
+     * The item containing the name of the value type to match the argument and
+     * convert the value into when invoking the constructor or factory method.
+     * The key is {@link #VALUE_TYPE}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            VALUE_TYPE_ITEM         = new Item(
+                                                    VALUE_TYPE, 
+                                                    "", 
+                                                    SimpleType.STRING);
+    
+    /**
+     * The CompositeType for a Argument object. It contains the following items:
+     * <ul>
+     * <li>{@link #INDEX}</li>
+     * <li>{@link #VALUE_TYPE}</li>
+     * <li>{@link #VALUE}</li>
+     * </ul>
+     */
+    CompositeType   ARGUMENT_TYPE           = Item.compositeType(
+                                                    "Argument",
+                                                    "",
+                                                    INDEX_ITEM,
+                                                    VALUE_TYPE_ITEM,
+                                                    GENERIC_VALUE_ITEM);
+    
+    ///////////////////////////////////////////////////////////////
+    // Define <property>'s CompositeType
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key NAME, used in {@link #NAME_ITEM}.
+     */
+    String          NAME                    = "Name";
+    
+    /**
+     * The item containing the name of the property to be injected.
+     * The key is {@link #NAME}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            NAME_ITEM               = new Item(
+                                                    NAME,
+                                                    "",
+                                                    SimpleType.STRING);
+    
+    /**
+     * The CompositeType for property type. It contains the following items:
+     * <ul>
+     * <li>{@link #NAME}</li>
+     * <li>{@link #VALUE}</li>
+     * </ul>
+     */
+    CompositeType   PROPERTY_TYPE           = Item.compositeType(
+                                                    "Property", 
+                                                    "", 
+                                                    NAME_ITEM,
+                                                    GENERIC_VALUE_ITEM);
+    
+    ///////////////////////////////////////////////////////////////
+    // Define Event's CompositeType
+    ///////////////////////////////////////////////////////////////
+    
+    /**
+     * The key EVENT_BUNDLE, used in {@link #EVENT_BUNDLE_ID_ITEM}.
+     */
+    String          EVENT_BUNDLE            = "EventBundle";
+    
+    /**
+     * The item containing the Blueprint bundle id associated with this event.
+     * The key is {@link #EVENT_BUNDLE}, and the type is {@link SimpleType#LONG}.
+     */
+    Item            EVENT_BUNDLE_ID_ITEM    = new Item(
+                                                    EVENT_BUNDLE,
+                                                    "",
+                                                    SimpleType.LONG);
+    
+    /**
+     * The key EVENT_EXTENDER_BUNDLE, used in {@link #EVENT_EXTENDER_BUNDLE_ID_ITEM}.
+     */
+    String          EVENT_EXTENDER_BUNDLE   = "EventExtenderBundle";
+    
+    /**
+     * The item containing the Blueprint extender bundle id that is generating this event.
+     * The key is {@link #EVENT_EXTENDER_BUNDLE}, and the type is {@link SimpleType#LONG}.
+     */
+    Item            EVENT_EXTENDER_BUNDLE_ID_ITEM    = new Item(
+                                                            EVENT_EXTENDER_BUNDLE,
+                                                            "",
+                                                            SimpleType.LONG);
+
+    /**
+     * The key IS_REPLAY, used in {@link #IS_REPLAY_ITEM}.
+     */ 
+    String          IS_REPLAY               = "IsReplay";
+    
+    /**
+     * The item containing the flag that represents whether this event is a replay event.
+     * The key is {@link #IS_REPLAY}, and the type is {@link SimpleType#BOOLEAN}.
+     */
+    Item            IS_REPLAY_ITEM          = new Item(
+                                                IS_REPLAY,
+                                                "",
+                                                SimpleType.BOOLEAN);
+    
+    
+    /**
+     * The key EVENT_TYPE, used in {@link #EVENT_TYPE_ITEM}.
+     */
+    String          EVENT_TYPE              = "EventType";
+    
+    /**
+     * Constant CREATED for the {@link #EVENT_TYPE}
+     */
+    String          CREATED                 = "CREATED";
+    /**
+     * Constant CREATING for the {@link #EVENT_TYPE}
+     */
+    String          CREATING                = "CREATING";
+    /**
+     * Constant DESTROYED for the {@link #EVENT_TYPE}
+     */
+    String          DESTROYED               = "DESTROYED";
+    /**
+     * Constant DESTROYING for the {@link #EVENT_TYPE}
+     */
+    String          DESTROYING              = "DESTROYING";
+    /**
+     * Constant FAILURE for the {@link #EVENT_TYPE}
+     */
+    String          FAILURE                 = "FAILURE";
+    /**
+     * Constant GRACE_PERIOD for the {@link #EVENT_TYPE}
+     */
+    String          GRACE_PERIOD            = "GRACE_PERIOD";
+    /**
+     * Constant WAITING for the {@link #EVENT_TYPE}
+     */
+    String          WAITING                 = "WAITING";
+    
+    /**
+     * The item containing the type of this event.
+     * The key is {@link #EVENT_TYPE}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            EVENT_TYPE_ITEM         = new Item(
+                                                EVENT_TYPE,
+                                                "",
+                                                SimpleType.STRING,
+                                                CREATED, CREATING, DESTROYED, DESTROYING,
FAILURE, GRACE_PERIOD, WAITING);    
+    
+    /**
+     * The key TIMESTAMP, used in {@link #EVENT_TYPE_ITEM}.
+     */    
+    String          TIMESTAMP               = "Timestamp";
+    
+    /**
+     * The item containing the time at which this event was created.
+     * The key is {@link #TIMESTAMP}, and the type is {@link SimpleType#LONG}.
+     */
+    Item            TIMESTAMP_ITEM          = new Item(
+                                                TIMESTAMP,
+                                                "",
+                                                SimpleType.LONG);
+
+
+    /**
+     * The key MISSED_DEPENDENCIES, used in {@link #MISSED_DEPENDENCIES_ITEM}.
+     */
+    String          MISSED_DEPENDENCIES     = "MissedDependencies";
+    
+    /**
+     * The item containing the filters identifying the missing dependencies that caused the
WAITING, GRACE_PERIOD or FAILURE event.
+     * The key is {@link #MISSED_DEPENDENCIES}, and the type is {@link JmxConstants#STRING_ARRAY_TYPE}.
+     */
+    Item            MISSED_DEPENDENCIES_ITEM         = new Item(
+                                                            MISSED_DEPENDENCIES,
+                                                            "",
+                                                            JmxConstants.STRING_ARRAY_TYPE);
+        
+    /**
+     * The key ERROR_MESSAGE, used in {@link #ERROR_MESSAGE_ITEM}.
+     */    
+    String          ERROR_MESSAGE           = "ErrorMessage";
+    
+    /**
+     * The item containing the error message for this FAILURE event.
+     * The key is {@link #ERROR_MESSAGE}, and the type is {@link SimpleType#STRING}.
+     */
+    Item            ERROR_MESSAGE_ITEM      = new Item(
+                                                ERROR_MESSAGE,
+                                                "",
+                                                SimpleType.STRING);
+    
+    /**
+     * The CompositeType for a blueprint event. It contains the following items:
+     * <ul>
+     * <li>{@link #EVENT_BUNDLE}</li>
+     * <li>{@link #EVENT_EXTENDER_BUNDLE}</li>
+     * <li>{@link #EVENT_TYPE}</li>
+     * <li>{@link #IS_REPLAY}</li>
+     * <li>{@link #TIMESTAMP}</li>
+     * <li>{@link #MISSED_DEPENDENCIES}</li>
+     * <li>{@link #ERROR_MESSAGE}</li>
+     * </ul>
+     */
+    CompositeType   BLUEPRINT_EVENT_TYPE    = Item.compositeType(
+                                                "BLUEPRINT_EVENT", 
+                                                "", 
+                                                EVENT_BUNDLE_ID_ITEM,
+                                                EVENT_EXTENDER_BUNDLE_ID_ITEM,
+                                                EVENT_TYPE_ITEM,
+                                                IS_REPLAY_ITEM,
+                                                TIMESTAMP_ITEM,
+                                                MISSED_DEPENDENCIES_ITEM,
+                                                ERROR_MESSAGE_ITEM);
+    
+    /**
+     * Returns the list of component id.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @return the array of component id
+     */
+    String[] getComponentIds(long containerServiceId);
+    
+    /**
+     * Returns all component ids of the specified component type
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @param type The string used to specify the type of component
+     * @return the array of component id
+     */
+    String[] getComponentIdsByType(long containerServiceId, String type);
+    
+    /**
+     * Returns the BeanMetadata according to the its component id.
+     * The returned Composite Data is typed by {@link #BEAN_METADATA_TYPE}.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @param componentId The component id
+     * @return the BeanMetadata, see {@link #BEAN_METADATA_TYPE}
+     */
+    CompositeData getBeanMetadata(long containerServiceId, String componentId);
+    
+    /**
+     * Returns the ServiceMetadata according to the its component id.
+     * The returned Composite Data is typed by {@link #SERVICE_MATADATA_TYPE}.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @param componentId The component id
+     * @return the ServiceMetadata, see {@link #SERVICE_MATADATA_TYPE} 
+     */
+    CompositeData getServiceMetadata(long containerServiceId, String componentId);
+    
+    /**
+     * Returns the ReferenceMetadata according to the its component id.
+     * The returned Composite Data is typed by {@link #REFERENCE_METADATA_TYPE}.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @param componentId The component id
+     * @return the ReferenceMetadata, see {@link #REFERENCE_METADATA_TYPE}
+     */
+    CompositeData getReferenceMetadata(long containerServiceId, String componentId);
+    
+    /**
+     * Returns the ReferenceListMetadata according to the its component id.
+     * The returned Composite Data is typed by {@link #REFERENCE_LIST_METADATA_TYPE}.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @param componentId The component id
+     * @return the ReferenceListMetadata, see {@link #REFERENCE_LIST_METADATA_TYPE} 
+     */
+    CompositeData getReferenceListMetadata(long containerServiceId, String componentId);
+    
+    
+    /**
+     * Returns the arguments associated with a bean component in tabular form.
+     * 
+     * Each row of the returned table represents a single argument. The Tabular
+     * Data consists of Composite Data that is type by {@link #ARGUMENT_TYPE}.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @param componentId The component id
+     * @return the arguments associated with a bean component
+     */
+    TabularData getBeanArguments(long containerServiceId, String componentId);
+    
+    /**
+     * Returns the properties associated with a bean component in tabular form.
+     * 
+     * Each row of the returned table represents a single property. The Tabular
+     * Data consists of Composite Data that is type by {@link #PROPERTY_TYPE}.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @param componentId The component id
+     * @return the properties associated with a bean component
+     */
+    TabularData getBeanProperties(long containerServiceId, String componentId);
+    
+    /**
+     * Returns the properties associated with a service component in tabular form.
+     * 
+     * Each row of the returned table represents a single property. The Tabular
+     * Data consists of Composite Data that is type by {@link #PROPERTY_TYPE}.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @param componentId The component id
+     * @return the properties associated with a service component
+     */
+    TabularData getServiceProperties(long containerServiceId, String componentId);
+    
+    /**
+     * Returns the BlueprintEvent associated with this blueprint container.
+     * The returned Composite Data is typed by {@link #BLUEPRINT_EVENT_TYPE}.
+     * 
+     * @param containerServiceId The blueprint container service id
+     * @return the last event associated with the blueprint bundle, see {@link #BLUEPRINT_EVENT_TYPE}

+     */
+    CompositeData getLastEvent(long containerServiceId);
+    
+    /**
+     * Returns the blueprint container's service id if the bundle specified 
+     * by the bundle id is a blueprint bundle.
+     * 
+     * @param bundleId The bundle id
+     * @return the blueprint container's service id, or null if the bundle is not a blueprint
bundle
+     */
+    String getBlueprintContainerServiceId(long bundleId);
+    
+    /**
+     * Returns all the blueprint containers' service IDs.
+     * 
+     * @return all the blueprint containers' service IDs 
+     */
+    String[] getAllBlueprintContainerServiceIds();
+    
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/jmx/BlueprintStateMBean.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message