0 Replies Latest reply on Sep 3, 2007 6:57 AM by V K

    Obtaining Servlet Container Instance

    V K Newbie

      We have AJP13 protocal for comm. between JK and JBoss server. Request generated by JK are handled by AJP Connector running in JBoss.

      My understanding of code is this:

      Client Request ---> mod_JK ---> AJP Connector ---> AJP Processor ---
      ---> Final Request is sent to container(Code is something like this connector.getContainer().invoke(request, response));

      Question:
      Who is setting up "container"? In "Ajp13Connector.java" there are setter and getter for container. But, who is setting these container?

      What I am trying to do:
      I have a bean which is loaded by some(like spring) framwork. This bean act like a server( handles the requests). It is similer to AJP Connector but, in my case this bean is loaded by my framwork which is loaded by JBoss.
      This bean works perfect, problem is to forward final request to servlet container.
      So, what my server want to do is to simply accepting the socket connection, removing all the custom details and pass on the request to normal request handling procedure (Which I think is passing request to container).

      Question:
      From where to get container instance to which I can pass on the request.
      Or
      I will have to make connector similer to AJP13 activated by JBoss(or Tomcat)
      Or you can see it in these way also
      Can a bean use JBoss normal request handling machanise, working as a source of request?