Class DsXmlDeployer

  • All Implemented Interfaces:
    com.github.fungal.spi.deployers.Deployer

    public class DsXmlDeployer
    extends AbstractDsDeployer
    implements com.github.fungal.spi.deployers.Deployer
    The -ds.xml deployer for JCA/SJC
    Author:
    Jesper Pedersen
    • Constructor Detail

      • DsXmlDeployer

        public DsXmlDeployer()
        Constructor
    • Method Detail

      • setJDBCLocal

        public void setJDBCLocal​(String value)
        Set the name for the JDBC Local resource adapter
        Parameters:
        value - The value
      • getJDBCLocal

        public String getJDBCLocal()
        Get the name for the JDBC Local resource adapter
        Returns:
        The value
      • setJDBCXA

        public void setJDBCXA​(String value)
        Set the name for the JDBC XA resource adapter
        Parameters:
        value - The value
      • getJDBCXA

        public String getJDBCXA()
        Get the name for the JDBC Xa resource adapter
        Returns:
        The value
      • setDriverRegistry

        public void setDriverRegistry​(DriverRegistry value)
        Set the driver registry
        Parameters:
        value - The value
      • accepts

        public boolean accepts​(URL url)
        Specified by:
        accepts in interface com.github.fungal.spi.deployers.Deployer
      • getOrder

        public int getOrder()
        Specified by:
        getOrder in interface com.github.fungal.spi.deployers.Deployer
      • deploy

        public com.github.fungal.spi.deployers.Deployment deploy​(URL url,
                                                                 com.github.fungal.spi.deployers.Context context,
                                                                 ClassLoader parent)
                                                          throws com.github.fungal.spi.deployers.DeployException
        Specified by:
        deploy in interface com.github.fungal.spi.deployers.Deployer
        Throws:
        com.github.fungal.spi.deployers.DeployException
      • getFileFromUrl

        protected File getFileFromUrl​(URL url)
                               throws URISyntaxException,
                                      IOException
        Get File object of URL who locate xml resource
        Parameters:
        url - url of the archive
        Returns:
        a File object pointing of xml resource
        Throws:
        URISyntaxException - Thrown if the resource adapter cant be found
        IOException - Thrown if the resource adapter cant be accessible
      • getIronJacamarHome

        protected String getIronJacamarHome()
        Get IronJacamar Home directory
        Returns:
        a String object
      • cleanTemporaryFiles

        protected void cleanTemporaryFiles​(URL url)
                                    throws com.github.fungal.spi.deployers.DeployException
        Clean all potential temporary files
        Parameters:
        url - url of the archive
        Throws:
        com.github.fungal.spi.deployers.DeployException - Thrown if the resource cant be cleaned
      • getDriver

        protected String getDriver​(String driverName,
                                   String moduleId)
        Get the driver
        Overrides:
        getDriver in class AbstractDsDeployer
        Parameters:
        driverName - The name of the driver
        moduleId - The id of the module
        Returns:
        The driver class name; or null if not found
      • start

        public void start()
        Start
      • setMetadataRepository

        public void setMetadataRepository​(MetadataRepository value)
        Set the metadata repository
        Parameters:
        value - The value
      • getMetadataRepository

        public MetadataRepository getMetadataRepository()
        Get the metadata repository
        Returns:
        The handle
      • setResourceAdapterRepository

        public void setResourceAdapterRepository​(ResourceAdapterRepository value)
        Set the resource adapter repository
        Parameters:
        value - The value
      • getResourceAdapterRepository

        public ResourceAdapterRepository getResourceAdapterRepository()
        Get the resource adapter repository
        Returns:
        The handle