Author: ningjiang
Date: Mon Apr 16 08:06:34 2007
New Revision: 529279
URL: http://svn.apache.org/viewvc?view=rev&rev=529279
Log:
CXF-535 Fixed the services list bug and update cxf-servlet.xml in the samples
Modified:
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world/wsdl/cxf-servlet.xml
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_RPCLit/wsdl/cxf-servlet.xml
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_xml_bare/wsdl/cxf-servlet.xml
incubator/cxf/trunk/distribution/src/main/release/samples/mtom/wsdl/cxf-servlet.xml
incubator/cxf/trunk/distribution/src/main/release/samples/soap12/wsdl/cxf-servlet.xml
incubator/cxf/trunk/distribution/src/main/release/samples/soap_header/wsdl/cxf-servlet.xml
incubator/cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/servlet/CXFServletTest.java
Modified:
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world/wsdl/cxf-servlet.xml
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/hello_world/wsdl/cxf-servlet.xml?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world/wsdl/cxf-servlet.xml
(original)
+++
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world/wsdl/cxf-servlet.xml
Mon Apr 16 08:06:34 2007
@@ -27,8 +27,8 @@
http://cxf.apache.org/jaxws http://cxf.apache.org/schema/jaxws.xsd">
<jaxws:endpoint
- id="hello_world"
- implementation="demo.hw.server.GreeterImpl"
+ id="hello_world_xml_bare"
+ implementor="demo.hw.server.GreeterImpl"
wsdlLocation="WEB-INF/wsdl/hello_world.wsdl"
- url-pattern="/hello_world" />
+ address="/services/hello_world" />
</beans>
Modified:
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_RPCLit/wsdl/cxf-servlet.xml
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_RPCLit/wsdl/cxf-servlet.xml?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_RPCLit/wsdl/cxf-servlet.xml
(original)
+++
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_RPCLit/wsdl/cxf-servlet.xml
Mon Apr 16 08:06:34 2007
@@ -17,15 +17,19 @@
specific language governing permissions and limitations
under the License.
-->
-<endpoints>
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:jaxws="http://cxf.apache.org/jaxws"
+ xmlns:soap="http://cxf.apache.org/bindings/soap"
+ xsi:schemaLocation="
+http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
+http://cxf.apache.org/bindings/soap
http://cxf.apache.org/schema/bindings/soap.xsd
+http://cxf.apache.org/jaxws http://cxf.apache.org/schema/jaxws.xsd">
- <endpoint
- name="hello_world_rpclit"
- interface="org.apache.hello_world_rpclit.GreeterRPCLit"
- implementation="demo.hwRPCLit.server.GreeterRPCLitImpl"
- wsdl="WEB-INF/wsdl/hello_world_RPCLit.wsdl"
- service="{http://apache.org/hello_world_rpclit}SOAPServiceRPCLit"
- port="{http://apache.org/hello_world_rpclit}SOAPPortRPCLit"
- url-pattern="/hello_world_rpclit" />
+ <jaxws:endpoint
+ id="hello_world_rpclit"
+ implementor="demo.hwRPCLit.server.GreeterRPCLitImpl"
+ wsdlLocation="WEB-INF/wsdl/hello_world_RPCLit.wsdl"
+ address="/services/hello_world_rpclit" />
-</endpoints>
+</beans>
Modified:
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_xml_bare/wsdl/cxf-servlet.xml
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_xml_bare/wsdl/cxf-servlet.xml?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_xml_bare/wsdl/cxf-servlet.xml
(original)
+++
incubator/cxf/trunk/distribution/src/main/release/samples/hello_world_xml_bare/wsdl/cxf-servlet.xml
Mon Apr 16 08:06:34 2007
@@ -17,15 +17,18 @@
specific language governing permissions and limitations
under the License.
-->
-<endpoints>
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:jaxws="http://cxf.apache.org/jaxws"
+ xmlns:soap="http://cxf.apache.org/bindings/soap"
+ xsi:schemaLocation="
+http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
+http://cxf.apache.org/bindings/soap
http://cxf.apache.org/schema/bindings/soap.xsd
+http://cxf.apache.org/jaxws http://cxf.apache.org/schema/jaxws.xsd">
- <endpoint
- name="hello_world"
- interface="org.apache.hello_world_soap_http.Greeter"
- implementation="demo.hw.server.GreeterImpl"
- wsdl="WEB-INF/wsdl/hello_world.wsdl"
- service="{http://apache.org/hello_world_soap_http}SOAPService"
- port="{http://apache.org/hello_world_soap_http}SOAPPort"
- url-pattern="/hello_world" />
-
-</endpoints>
+ <jaxws:endpoint
+ id="hello_world"
+ implementor="demo.hw.server.GreeterImpl"
+ wsdlLocation="WEB-INF/wsdl/hello_world.wsdl"
+ address="/services/hello_world"/>
+</beans>
Modified:
incubator/cxf/trunk/distribution/src/main/release/samples/mtom/wsdl/cxf-servlet.xml
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/mtom/wsdl/cxf-servlet.xml?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/distribution/src/main/release/samples/mtom/wsdl/cxf-servlet.xml
(original)
+++
incubator/cxf/trunk/distribution/src/main/release/samples/mtom/wsdl/cxf-servlet.xml
Mon Apr 16 08:06:34 2007
@@ -17,15 +17,19 @@
specific language governing permissions and limitations
under the License.
-->
-<endpoints>
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:jaxws="http://cxf.apache.org/jaxws"
+ xmlns:soap="http://cxf.apache.org/bindings/soap"
+ xsi:schemaLocation="
+http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
+http://cxf.apache.org/bindings/soap
http://cxf.apache.org/schema/bindings/soap.xsd
+http://cxf.apache.org/jaxws http://cxf.apache.org/schema/jaxws.xsd">
- <endpoint
+ <jaxws:endpoint
name="mtom"
- interface="org.apache.cxf.mime.TestMtom"
- implementation="demo.mtom.server.TestMtomImpl"
- wsdl="WEB-INF/wsdl/mtom_xop.wsdl"
- service="{http://cxf.apache.org/mime}TestMtomService"
- port="{http://cxf.apache.org/mime}TestMtomPort"
- url-pattern="/mtom" />
+ implementor="demo.mtom.server.TestMtomImpl"
+ wsdlLocation="WEB-INF/wsdl/mtom_xop.wsdl"
+ address="/services/mtom" />
-</endpoints>
+</beans>
Modified:
incubator/cxf/trunk/distribution/src/main/release/samples/soap12/wsdl/cxf-servlet.xml
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/soap12/wsdl/cxf-servlet.xml?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/distribution/src/main/release/samples/soap12/wsdl/cxf-servlet.xml
(original)
+++
incubator/cxf/trunk/distribution/src/main/release/samples/soap12/wsdl/cxf-servlet.xml
Mon Apr 16 08:06:34 2007
@@ -17,15 +17,19 @@
specific language governing permissions and limitations
under the License.
-->
-<endpoints>
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:jaxws="http://cxf.apache.org/jaxws"
+ xmlns:soap="http://cxf.apache.org/bindings/soap"
+ xsi:schemaLocation="
+http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
+http://cxf.apache.org/bindings/soap
http://cxf.apache.org/schema/bindings/soap.xsd
+http://cxf.apache.org/jaxws http://cxf.apache.org/schema/jaxws.xsd">
- <endpoint
- name="hello_world_soap12"
- interface="org.apache.hello_world_soap12_http.Greeter"
- implementation="demo.hw.server.GreeterImpl"
- wsdl="WEB-INF/wsdl/hello_world_soap12.wsdl"
- service="{http://apache.org/hello_world_soap12_http}SOAPService"
- port="{http://apache.org/hello_world_soap12_http}SOAPPort"
- url-pattern="/hello_world_soap12" />
+ <jaxws:endpoint
+ name="hello_world_soap12"
+ implementor="demo.hw.server.GreeterImpl"
+ wsdlLocation="WEB-INF/wsdl/hello_world_soap12.wsdl"
+ address="/server/hello_world_soap12" />
-</endpoints>
+</beans>
Modified:
incubator/cxf/trunk/distribution/src/main/release/samples/soap_header/wsdl/cxf-servlet.xml
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/soap_header/wsdl/cxf-servlet.xml?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/distribution/src/main/release/samples/soap_header/wsdl/cxf-servlet.xml
(original)
+++
incubator/cxf/trunk/distribution/src/main/release/samples/soap_header/wsdl/cxf-servlet.xml
Mon Apr 16 08:06:34 2007
@@ -17,15 +17,19 @@
specific language governing permissions and limitations
under the License.
-->
-<endpoints>
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:jaxws="http://cxf.apache.org/jaxws"
+ xmlns:soap="http://cxf.apache.org/bindings/soap"
+ xsi:schemaLocation="
+http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
+http://cxf.apache.org/bindings/soap
http://cxf.apache.org/schema/bindings/soap.xsd
+http://cxf.apache.org/jaxws http://cxf.apache.org/schema/jaxws.xsd">
- <endpoint
+ <jaxws:endpoint
name="soap_headers"
- interface="org.apache.soap_header.TestHeader"
- implementation="demo.soap_header.server.HeaderTesterImpl"
+ implementor="demo.soap_header.server.HeaderTesterImpl"
wsdl="WEB-INF/wsdl/soap_header.wsdl"
- service="{http://apache.org/headers}HeaderService"
- port="{http://apache.org/headers}SOAPPort"
- url-pattern="/soap_header" />
+ address="/services/soap_header" />
</endpoints>
Modified:
incubator/cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
(original)
+++
incubator/cxf/trunk/rt/management/src/main/java/org/apache/cxf/management/jmx/InstrumentationManagerImpl.java
Mon Apr 16 08:06:34 2007
@@ -199,7 +199,7 @@
public void postShutdown() {
- //Using the array to hold the busMBeans to avoid the
CurrentModification exception
+ //Using the array to hold the busMBeans to avoid the
CurrentModificationException
Object[] mBeans = busMBeans.toArray();
for (Object name : mBeans) {
busMBeans.remove((ObjectName)name);
Modified:
incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
(original)
+++
incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletController.java
Mon Apr 16 08:06:34 2007
@@ -132,8 +132,12 @@
for (ServletDestination sd : destinations) {
if (null != sd.getEndpointInfo().getName()) {
String address = sd.getAddress().getAddress().getValue();
- int bi = address.indexOf(CXFServlet.ADDRESS_PERFIX);
- address = request.getRequestURL()
+ int bi = address.indexOf(CXFServlet.ADDRESS_PERFIX);
+ String reqPerfix = request.getRequestURL().toString();
+ if (reqPerfix.endsWith("/")) {
+ reqPerfix = reqPerfix.substring(0, reqPerfix.length()
- 1);
+ }
+ address = reqPerfix
+ address.substring(bi +
CXFServlet.ADDRESS_PERFIX.length());
response.getWriter().write("<p> <a href=\"" + address +
"?wsdl\">");
response.getWriter().write(sd.getEndpointInfo().getName()
+ "</a> </p>");
Modified:
incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/servlet/CXFServletTest.java
URL:
http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/servlet/CXFServletTest.java?view=diff&rev=529279&r1=529278&r2=529279
==============================================================================
---
incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/servlet/CXFServletTest.java
(original)
+++
incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/servlet/CXFServletTest.java
Mon Apr 16 08:06:34 2007
@@ -97,6 +97,12 @@
assertEquals("There should get one link for service", links.length, 1);
assertEquals(links[0].getURLString(),
"http://localhost/services/greeter?wsdl");
assertEquals("text/html", res.getContentType());
+
+ res = client.getResponse("http://localhost/services/");
+ links = res.getLinks();
+ assertEquals("There should get one link for service", links.length, 1);
+ assertEquals(links[0].getURLString(),
"http://localhost/services/greeter?wsdl");
+ assertEquals("text/html", res.getContentType());
}
@Test