Package com.sun.enterprise.deployment

Examples of com.sun.enterprise.deployment.ConnectorDescriptor


        }
       
        // set connector descriptor classloaders to null
        Set rars = this.application.getRarDescriptors();
        for (Iterator itr = rars.iterator(); itr.hasNext();) {
            ConnectorDescriptor cd = (ConnectorDescriptor) itr.next();
            cd.setClassLoader(null);
        }
       
        this.id                 = null;
        this.parentClassLoader  = null;
        this.application        = null;
View Full Code Here


        try {
            Set rarsDescriptors  = this.application.getRarDescriptors();
            ConnectorRuntime connectorRuntime = ConnectorRuntime.getRuntime();
       
            for (Iterator itr = rarsDescriptors.iterator(); itr.hasNext();) {
                ConnectorDescriptor cd = (ConnectorDescriptor) itr.next();
                String rarName = cd.getDeployName();
                String jndiName = this.id+
                         ConnectorConstants.EMBEDDEDRAR_NAME_DELIMITER+
                         FileUtils.makeFriendlyFilenameNoExtension(rarName);
                connectorRuntime.destroyActiveResourceAdapter(jndiName,cascade);
                if (jsr77) {
View Full Code Here

            String appLocation = this.configManager.getLocation(this.id);
            Set rars = application.getRarDescriptors();
            ConnectorRuntime connectorRuntime = ConnectorRuntime.getRuntime();

            for (Iterator itr = rars.iterator(); itr.hasNext();) {
                ConnectorDescriptor cd = (ConnectorDescriptor) itr.next();
                String rarName = cd.getDeployName();
                String location = DeploymentUtils.getEmbeddedModulePath(
                    appLocation, rarName);
                String jndiName = this.id+
                       ConnectorConstants.EMBEDDEDRAR_NAME_DELIMITER+
                       FileUtils.makeFriendlyFilenameNoExtension(rarName);
View Full Code Here

     * @see ConnectorDescriptor;
     */
    private ConnectorDescriptor createConnectorDescriptor(
            String moduleDir ) {

  ConnectorDescriptor connectorDescriptor = null ;
        FileArchive fa = new FileArchive();
  try {
            fa.open( moduleDir )// directory where rar is exploded
            ConnectorArchivist archivist = new ConnectorArchivist();
            connectorDescriptor = (ConnectorDescriptor)
View Full Code Here

  String moduleName = getModuleName( adminPool );
        String moduleDir = getSystemModuleLocation( moduleName );
  int txSupport = getTxSupport( moduleName );

  ConnectorDescriptor connDesc = createConnectorDescriptor( moduleDir );

        //Create the connector Connection Pool object from the configbean object
        ConnectorConnectionPool conConnPool = new ConnectorConnectionPool(
          adminPool.getName() );
View Full Code Here

    /**
     * Create jsr77 resource adapter mebans which are contained
     * within this connector module
     */
    void createLeafMBean(Descriptor descriptor) throws MBeanException {
        ConnectorDescriptor cd = null;
        try {
            cd = (ConnectorDescriptor) descriptor;
        } catch (Exception e) {
            throw new MBeanException(e);
        }
View Full Code Here

    /**
     * Delete jsr77 resource adapter mebans which are contained
     * within this connector module
     */
    void deleteLeafMBean(Descriptor descriptor) throws MBeanException {
        ConnectorDescriptor cd = null;
        try {
            cd = (ConnectorDescriptor) descriptor;
        } catch (Exception e) {
            throw new MBeanException(e);
        }
View Full Code Here

        String connectionDefinitionName, String rarName,
  ElementProperty[] props, SecurityMap[] securityMaps)
  throws ConnectorRuntimeException {
   
  ConnectorRegistry _registry = ConnectorRegistry.getInstance();
        ConnectorDescriptor connectorDescriptor = _registry.getDescriptor(rarName);
        if (connectorDescriptor == null) {
            ConnectorRuntimeException cre = new ConnectorRuntimeException(
                            "Failed to get connection pool object");
            _logger.log(Level.SEVERE,
                 "rardeployment.connector_descriptor_notfound_registry",rarName);
            _logger.log(Level.SEVERE,"",cre);
            throw cre;
        }
        Set connectionDefs = 
             connectorDescriptor.getOutboundResourceAdapter().getConnectionDefs();
        ConnectionDefDescriptor cdd = null;
        Iterator it = connectionDefs.iterator();
        while(it.hasNext()) {
          cdd = (ConnectionDefDescriptor)it.next();
          if(connectionDefinitionName.equals(cdd.getConnectionFactoryIntf()))
              break;

        }
        ConnectorDescriptorInfo cdi = new ConnectorDescriptorInfo();

        cdi.setRarName(rarName);
        cdi.setResourceAdapterClassName(
                    connectorDescriptor.getResourceAdapterClass());
        cdi.setConnectionDefinitionName(cdd.getConnectionFactoryIntf());
        cdi.setManagedConnectionFactoryClass(
                    cdd.getManagedConnectionFactoryImpl());
        cdi.setConnectionFactoryClass(cdd.getConnectionFactoryImpl());
        cdi.setConnectionFactoryInterface(cdd.getConnectionFactoryIntf());
        cdi.setConnectionClass(cdd.getConnectionImpl());
        cdi.setConnectionInterface(cdd.getConnectionIntf());
        Set mergedProps = mergeProps(props, cdd.getConfigProperties(), rarName);
        cdi.setMCFConfigProperties(mergedProps);
        cdi.setResourceAdapterConfigProperties(
                    connectorDescriptor.getConfigProperties());
        ccp.setConnectorDescriptorInfo( cdi );
        ccp.setSecurityMaps(SecurityMapUtils.getConnectorSecurityMaps(securityMaps));
            
    }
View Full Code Here

    public Node writeDescriptor(Node connectorNode, Descriptor descriptor) {

        if (! (descriptor instanceof ConnectorDescriptor)) {
            throw new IllegalArgumentException(getClass() + " cannot handle descriptors of type " + descriptor.getClass());
        }
        ConnectorDescriptor conDesc = (ConnectorDescriptor) descriptor;
        Node raNode = appendChild(connectorNode, ConnectorTagNames.RESOURCE_ADAPTER);

  appendTextChild(raNode, ConnectorTagNames.RESOURCE_ADAPTER_CLASS, conDesc.getResourceAdapterClass())
 
  //config-property
  ConfigPropertyNode config = new ConfigPropertyNode();
  raNode = config.writeDescriptor(raNode, conDesc);
 
  if (conDesc.getOutBoundDefined() == true) {
      //outbound RA info 
      OutBoundRANode obNode = new OutBoundRANode();
      raNode = obNode.writeDescriptor(raNode, conDesc);
  }
 
  if (conDesc.getInBoundDefined() == true) {
      //inbound RA info
      InBoundRANode inNode = new InBoundRANode();
      raNode = inNode.writeDescriptor(raNode, conDesc);     
  }
 
View Full Code Here

  } else if (obj instanceof EnvironmentProperty) {
      descriptor.addConfigProperty((EnvironmentProperty)obj);
  } else if (obj instanceof SecurityPermission) {
            // security-permission element is a direct sub element of
            // resourceadapter, so set the value in ConnectorDescriptor
            ConnectorDescriptor connDesc =
                (ConnectorDescriptor)getParentNode().getDescriptor();
      connDesc.addSecurityPermission((SecurityPermission)obj);
  }
    }
View Full Code Here

TOP

Related Classes of com.sun.enterprise.deployment.ConnectorDescriptor

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.