Class ConnectorService

    • Constructor Detail

      • ConnectorService

        public ConnectorService()
        Default Constructor
    • Method Detail

      • getDefaultPoolName

        public String getDefaultPoolName​(String moduleName,
                                         String connectionDefName)
        Returns the generated default connection poolName for a connection definition.
        Parameters:
        moduleName - rar module name
        connectionDefName - connection definition name
        Returns:
        generated connection poolname
      • getDefaultResourceName

        public String getDefaultResourceName​(String moduleName,
                                             String connectionDefName)
        Returns the generated default connector resource for a connection definition.
        Parameters:
        moduleName - resource-adapter name
        connectionDefName - connection definition name
        Returns:
        generated default connector resource name
      • getConnectorDescriptor

        public ConnectorDescriptor getConnectorDescriptor​(String rarName)
                                                   throws ConnectorRuntimeException
        Obtains the connector Descriptor pertaining to rar. If ConnectorDescriptor is present in registry, it is obtained from registry and returned. Else it is explicitly read from directory where rar is exploded.
        Parameters:
        rarName - Name of the rar
        Returns:
        ConnectorDescriptor pertaining to rar.
        Throws:
        ConnectorRuntimeException - when unable to get descriptor
      • switchOnMatching

        public void switchOnMatching​(String rarName,
                                     PoolInfo poolInfo)
        Matching will be switched off in the pool, by default. This will be switched on if the connections with different resource principals reach the pool.
        Parameters:
        poolInfo - Name of the pool to switchOn matching.
        rarName - Name of the resource adater.
      • checkAndLoadPool

        public boolean checkAndLoadPool​(PoolInfo poolInfo)
      • checkAccessibility

        public boolean checkAccessibility​(String rarName,
                                          ClassLoader loader)
        Check whether ClassLoader is permitted to access this resource adapter. If the RAR is deployed and is not a standalone RAR, then only the ClassLoader that loaded the archive (any of its child) should be able to access it. Otherwise everybody can access the RAR.
        Parameters:
        rarName - Resource adapter module name.
        loader - ClassLoader to verify.