It took me a lot of experimentation with deploying my Axis2 web
application to figure out that, by default, Axis2 assumes that its
servlet mapping is "/services/*". This can apparently be changed with
the "servicePath" configuration parameter in axis2.xml.

However, I notice that even in Axis2 WAR's web.xml file, the
AxisServlet is actually mapped several times:

,----[ Axis2 web.xml ]
|     <servlet-mapping>
|         <servlet-name>AxisServlet</servlet-name>
|         <url-pattern>/servlet/AxisServlet</url-pattern>
|     </servlet-mapping>
| 
|     <servlet-mapping>
|         <servlet-name>AxisServlet</servlet-name>
|         <url-pattern>*.jws</url-pattern>
|     </servlet-mapping>
| 
|     <servlet-mapping>
|         <servlet-name>AxisServlet</servlet-name>
|         <url-pattern>/services/*</url-pattern>
|     </servlet-mapping>
`----

The last mapping makes sense to me, but how do the former two work? In
particular, with the first one, does Axis2 use this mapping for
dispatching to services as well?

My main concern involves a scenario where I want to deploy more than
service to more than one base URL pattern, but I want them both to map
to the AxisServlet. Maybe I want "<context>/foo/bar/<service name>"
active as well as "<context>/baz/quux/42/<service name>" active.

With only one "servicePath" parameter, this doesn't look like it will
possible; Axis2 won't be able to figure out how to strip the URL path
to find the right service. Would SOAPMessageBodyBasedDispatcher¹ be
able to figure this out?

Has there been any discussion about making "servicePath" not a scalar
but a /list/ of path prefixes to try stripping to find the intended
service name?


Footnotes: 
¹ "How Apache Axis2 Finds the Operation and Service a
   Message is Destined To"
  http://wso2.org/library/176

-- 
Steven E. Harris


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to