geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject cvs commit: incubator-geronimo/modules/core/src/java/org/apache/geronimo/connector/deployment ResourceAdapterHelper.java ResourceAdapterHelperImpl.java
Date Wed, 19 Nov 2003 02:13:04 GMT
djencks     2003/11/18 18:13:04

  Modified:    modules/core/src/java/org/apache/geronimo/connector/deployment
                        ResourceAdapterHelper.java
                        ResourceAdapterHelperImpl.java
  Log:
  Add registration stuff for deploying ActivationSpecs.  Exposed registration methods in GeronimoMBeanInfo.
 Not sure if we actually need the ResourceAdapterHelperImpl.
  
  Revision  Changes    Path
  1.3       +4 -1      incubator-geronimo/modules/core/src/java/org/apache/geronimo/connector/deployment/ResourceAdapterHelper.java
  
  Index: ResourceAdapterHelper.java
  ===================================================================
  RCS file: /home/cvs/incubator-geronimo/modules/core/src/java/org/apache/geronimo/connector/deployment/ResourceAdapterHelper.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ResourceAdapterHelper.java	13 Nov 2003 22:22:30 -0000	1.2
  +++ ResourceAdapterHelper.java	19 Nov 2003 02:13:04 -0000	1.3
  @@ -58,6 +58,7 @@
   
   import javax.resource.ResourceException;
   import javax.resource.spi.ManagedConnectionFactory;
  +import javax.resource.spi.ActivationSpec;
   
   /**
    * ResourceAdapterHelper
  @@ -67,5 +68,7 @@
   public interface ResourceAdapterHelper {
   
       void registerManagedConnectionFactory(ManagedConnectionFactory mcf) throws ResourceException;
  +
  +    void registerActivationSpec(ActivationSpec activationSpec) throws ResourceException;
   
   }
  
  
  
  1.3       +9 -2      incubator-geronimo/modules/core/src/java/org/apache/geronimo/connector/deployment/ResourceAdapterHelperImpl.java
  
  Index: ResourceAdapterHelperImpl.java
  ===================================================================
  RCS file: /home/cvs/incubator-geronimo/modules/core/src/java/org/apache/geronimo/connector/deployment/ResourceAdapterHelperImpl.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ResourceAdapterHelperImpl.java	13 Nov 2003 22:22:30 -0000	1.2
  +++ ResourceAdapterHelperImpl.java	19 Nov 2003 02:13:04 -0000	1.3
  @@ -62,6 +62,7 @@
   import javax.resource.spi.ResourceAdapter;
   import javax.resource.spi.BootstrapContext;
   import javax.resource.spi.ResourceAdapterInternalException;
  +import javax.resource.spi.ActivationSpec;
   
   import org.apache.geronimo.kernel.service.GeronimoMBeanContext;
   import org.apache.geronimo.kernel.service.GeronimoMBeanEndpoint;
  @@ -92,7 +93,7 @@
        * @see org.apache.geronimo.kernel.service.GeronimoMBeanTarget#canStart()
        */
       public boolean canStart() {
  -        return true;
  +        return bootstrapContext != null;
       }
   
       /* (non-Javadoc)
  @@ -137,6 +138,10 @@
           mcf.setResourceAdapter(resourceAdapter);
       }
   
  +    public void registerActivationSpec(ActivationSpec activationSpec) throws ResourceException
{
  +        activationSpec.setResourceAdapter(resourceAdapter);
  +    }
  +
       /**
        * @return Returns the bootstrapContext.
        */
  @@ -154,6 +159,8 @@
       public static void addMBeanInfo(GeronimoMBeanInfo mbeanInfo,
                                       ObjectName bootstrapContextName) {
           mbeanInfo.setTargetClass(TARGET_NAME, ResourceAdapterHelperImpl.class.getName());
  +
  +        mbeanInfo.addOperationsDeclaredIn(ResourceAdapterHelper.class);
   
           mbeanInfo.addEndpoint(new GeronimoMBeanEndpoint("BootstrapContext", BootstrapContext.class.getName(),
bootstrapContextName, true, TARGET_NAME));
   
  
  
  

Mime
View raw message