Uploaded image for project: 'TomEE'
  1. TomEE
  2. TOMEE-42

TCCL.getResources() returns duplicated when deploying with OpenEJB deployer

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.0.0-beta-2
    • None
    • None
    • 1.0.0-beta-2-20111019.211229-11-plus

    Description

      Having a testing listener:

      @WebListener
      public class Listener implements ServletContextListener {

      @Override
      public void contextInitialized(ServletContextEvent sce) {
      int j = 0;
      try {
      ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
      Enumeration<URL> urls = classLoader.getResources("foo.bar");
      while (urls.hasMoreElements())

      { urls.nextElement(); j++; }

      System.out.println("foo.bar count: " + j);
      } catch (IOException e)

      { e.printStackTrace(); }

      }

      @Override
      public void contextDestroyed(ServletContextEvent sce) {
      }
      }

      it returns the expected count (1) when deployed using the manager app or filesystem deployment. However, it returns 2 when deployed using OpenEJB deployer service (remote arquillian container).

      Attachments

        1. test.war
          3 kB
          Jozef Hartinger

        Activity

          People

            romain.manni-bucau Romain Manni-Bucau
            jharting Jozef Hartinger
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: