Class MetaInfConfiguration

  • All Implemented Interfaces:
    Configuration

    @Deprecated(since="2021-05-27")
    public class MetaInfConfiguration
    extends AbstractConfiguration
    Deprecated.
    The Eclipse Jetty and Apache Felix Http Jetty packages are no longer supported.
    MetaInfConfiguration

    Scan META-INF of jars to find:

    • tlds
    • web-fragment.xml
    • resources
    The jars which are scanned are:
    1. those from the container classpath whose pattern matched the WebInfConfiguration.CONTAINER_JAR_PATTERN
    2. those from WEB-INF/lib
    • Constructor Detail

      • MetaInfConfiguration

        public MetaInfConfiguration()
        Deprecated.
    • Method Detail

      • scanJars

        public void scanJars​(WebAppContext context,
                             Collection<Resource> jars,
                             boolean useCaches)
                      throws Exception
        Deprecated.
        For backwards compatibility. This method will always scan for all types of data.
        Parameters:
        context - the context for the scan
        jars - the jars to scan
        useCaches - if true, the scanned info is cached
        Throws:
        Exception - if unable to scan the jars
      • scanJars

        public void scanJars​(WebAppContext context,
                             Collection<Resource> jars,
                             boolean useCaches,
                             List<String> scanTypes)
                      throws Exception
        Deprecated.
        Look into the jars to discover info in META-INF. If useCaches == true, then we will cache the info discovered indexed by the jar in which it was discovered: this speeds up subsequent context deployments.
        Parameters:
        context - the context for the scan
        jars - the jars resources to scan
        useCaches - if true, cache the info discovered
        scanTypes - the type of things to look for in the jars
        Throws:
        Exception - if unable to scan the jars
      • scanForResources

        public void scanForResources​(WebAppContext context,
                                     Resource target,
                                     ConcurrentHashMap<Resource,​Resource> cache)
                              throws Exception
        Deprecated.
        Scan for META-INF/resources dir in the given jar.
        Parameters:
        context - the context for the scan
        target - the target resource to scan for
        cache - the resource cache
        Throws:
        Exception - if unable to scan for resources
      • scanForFragment

        public void scanForFragment​(WebAppContext context,
                                    Resource jar,
                                    ConcurrentHashMap<Resource,​Resource> cache)
                             throws Exception
        Deprecated.
        Scan for META-INF/web-fragment.xml file in the given jar.
        Parameters:
        context - the context for the scan
        jar - the jar resource to scan for fragements in
        cache - the resource cache
        Throws:
        Exception - if unable to scan for fragments
      • getTlds

        public Collection<URL> getTlds​(File dir)
                                throws IOException
        Deprecated.
        Find all .tld files in all subdirs of the given dir.
        Parameters:
        dir - the directory to scan
        Returns:
        the list of tlds found
        Throws:
        IOException - if unable to scan the directory
      • getTlds

        public Collection<URL> getTlds​(URI uri)
                                throws IOException
        Deprecated.
        Find all .tld files in the given jar.
        Parameters:
        uri - the uri to jar file
        Returns:
        the collection of tlds as url references
        Throws:
        IOException - if unable to scan the jar file