Amila Suriarachchi wrote: > > > On Fri, Aug 21, 2009 at 12:58 AM, Andreas Veithen > <andreas.veit...@gmail.com <mailto:andreas.veit...@gmail.com>> wrote: > > If the user registered a transport receiver for http or https that is > not of type AxisServletListener, then this would obviously mean that > he doesn't want to use the servlet based transport for these > protocols, but some other implementation. So the question in principle > doesn't apply. However, in Axis2 1.5 it is necessary to register the > SimpleHTTPServer as http transport even when AxisServlet is used, > because otherwise the generated WSDLs don't contain any endpoints. For > compatibility this is still supported and AxisServlet will replace the > transport receiver by AxisServletListener (and print a warning). > > > Can someone like Deepal (or any one who is with the Axis2 from day 0 ) > explain why servlet transport is written in this way? I mean adding a > transport receiver for SimpleHttpTransport in axis2.xml and use servlet? > I am sorry Amila, I did not follow this thread fully and I can not do it now (hard to find time). Anyway let me answer the question you just asked.
Just specifying transport in axis2.xml does not mean they are going to start when you start Axis2. They will come into picture only if you call the right method in ListenerManager. Or they will be start if some one try to use that transport. When we start Axis2 we did not have SimpleHTTPServer what we had was the servlet version (even that I copied from Axis1 and did some additional modification), second we did not have this transportInDec and TranportIOutDec, that we introduce later when we introduce new transports. I am not sure whether clearly understand the difference between how AxisServelet works and how SimpleHTTPServer works. In the case of AxisServlet, we first start AxisServlet and then we start Axis2, so when we start Axis2 we already have HTTP listener running (and hence TransportInDec). So once the system start we just create a TransportInDec using servlet and set that as the HTTP TransportDec (and of course we replace what is in axis2.xml for HTTP with this transportInDec, and we must do that). Whereas in SimpleHTTPServer, we first start Axis2 and then we use transport in axis2.xml to configure the system, so we use the tarnporInDec to configure the SimpleHTTPServer. If you still have some doubts please let me know, will try to explain bit further. Deepal