Application Server 7
  1. Application Server 7
  2. AS7-351

Implement the HttpService ontop of JBossWeb

    Details

    • Similar Issues:
      Show 10 results 

      Description

      Resolving this issue consolidates the Http services that we ship and should replace pax-web with an HttpService implemenation based on JBossWeb.
      RFC-66 (WebApp) support is also covered by this issue.

      1. DefaultHttpContext.java
        2 kB
        Remy Maucherat
      2. http-service-1.2.pdf
        159 kB
        Thomas Diesler
      3. HttpServiceImpl.java
        6 kB
        Remy Maucherat
      4. registerServlet
        0.6 kB
        Remy Maucherat
      5. ResourceServlet.java
        4 kB
        Remy Maucherat

        Issue Links

          Activity

          Hide
          Thomas Diesler
          added a comment - - edited

          Please provide pointers to documentation that explains how to dynamically create a context and populate it with servlet instances and resources. This can be stable JBossWeb propriatary API or standard servlet API.

          Show
          Thomas Diesler
          added a comment - - edited Please provide pointers to documentation that explains how to dynamically create a context and populate it with servlet instances and resources. This can be stable JBossWeb propriatary API or standard servlet API.
          Hide
          Brian Stansberry
          added a comment -

          Thomas, I'm unassigning Emanuel from this; he's not part of the core JBoss Web team and needs to focus on domain management tasks, not subsystem implementations. Please check with Remy to see what resources are available.

          Show
          Brian Stansberry
          added a comment - Thomas, I'm unassigning Emanuel from this; he's not part of the core JBoss Web team and needs to focus on domain management tasks, not subsystem implementations. Please check with Remy to see what resources are available.
          Hide
          Remy Maucherat
          added a comment -

          Jason added a WelcomeContextService which is a decent example for webapp creation.

          Show
          Remy Maucherat
          added a comment - Jason added a WelcomeContextService which is a decent example for webapp creation.
          Hide
          Thomas Diesler
          added a comment -

          The WelcomeContextService does not register resources. Please show how HttpService.registerResources() can be done

          Show
          Thomas Diesler
          added a comment - The WelcomeContextService does not register resources. Please show how HttpService.registerResources() can be done
          Hide
          Remy Maucherat
          added a comment -

          The code from Felix.

          Show
          Remy Maucherat
          added a comment - The code from Felix.
          Hide
          Remy Maucherat
          added a comment -

          Here's a snippet for how the registerServlet method could be implemented inside a clone of the WelcomeContextService class. The WebServerService must be injected, as well as the desired host.

          The problems are: how to decide which host gets the thing, and which context too. Also, the spec doesn't do filters [but Felix does].

          Show
          Remy Maucherat
          added a comment - Here's a snippet for how the registerServlet method could be implemented inside a clone of the WelcomeContextService class. The WebServerService must be injected, as well as the desired host. The problems are: how to decide which host gets the thing, and which context too. Also, the spec doesn't do filters [but Felix does] .
          Hide
          Hendy Irawan
          added a comment -

          Just to let you know that someone also cares about this issue.

          Thanks for everybody working on this issue. Great work!

          Show
          Hendy Irawan
          added a comment - Just to let you know that someone also cares about this issue. Thanks for everybody working on this issue. Great work!
          Hide
          Hendy Irawan
          added a comment -

          Especially Thomas Diesler

          Show
          Hendy Irawan
          added a comment - Especially Thomas Diesler
          Hide
          Thomas Diesler
          added a comment - - edited
          Wrapper osgiServletWrapper = context.createWrapper();
          osgiServletWrapper.setName("???"); // Generate something ?
          osgiServletWrapper.setServlet(servletInstance);
          osgiServletWrapper.setServletClass(servletInstance.getClass().getName());
          context.addChild(osgiServletWrapper);
          
          context.addServletMapping(alias, "???");
          
          // Must be added to the main mapper as no dynamic servlets usually
          injectedWebServerService.getService().getMapper().addWrapper(injectedHost.getName(), context.getPath(), alias, osgiServletWrapper, false);
          
          Show
          Thomas Diesler
          added a comment - - edited Wrapper osgiServletWrapper = context.createWrapper(); osgiServletWrapper.setName( "???" ); // Generate something ? osgiServletWrapper.setServlet(servletInstance); osgiServletWrapper.setServletClass(servletInstance.getClass().getName()); context.addChild(osgiServletWrapper); context.addServletMapping(alias, "???" ); // Must be added to the main mapper as no dynamic servlets usually injectedWebServerService.getService().getMapper().addWrapper(injectedHost.getName(), context.getPath(), alias, osgiServletWrapper, false );
          Hide
          Thomas Diesler
          added a comment -
          Running org.jboss.as.test.smoke.osgi.SimpleHttpServiceTestCase
          Tests run: 4, Failures: 0, Errors: 0, Skipped: 2, Time elapsed: 0.503 sec
          
          Show
          Thomas Diesler
          added a comment - Running org.jboss.as.test.smoke.osgi.SimpleHttpServiceTestCase Tests run: 4, Failures: 0, Errors: 0, Skipped: 2, Time elapsed: 0.503 sec
          Hide
          Thomas Diesler
          added a comment -

          Done

          Show
          Thomas Diesler
          added a comment - Done

            People

            • Assignee:
              Thomas Diesler
              Reporter:
              Thomas Diesler
            • Votes:
              3 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: