Author: thomas.diesler(a)jboss.com
Date: 2006-11-21 05:44:00 -0500 (Tue, 21 Nov 2006)
New Revision: 1482
Modified:
trunk/src/main/java/org/jboss/ws/annotation/PortComponent.java
trunk/src/main/java/org/jboss/ws/integration/jboss50/JBossServiceEndpointServlet.java
trunk/src/main/java/org/jboss/ws/jaxrpc/ServiceObjectFactory.java
trunk/src/main/java/org/jboss/ws/jaxrpc/handler/HandlerDelegateJAXRPC.java
trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerResolverImpl.java
trunk/src/main/java/org/jboss/ws/metadata/ClientEndpointMetaData.java
trunk/src/main/java/org/jboss/ws/metadata/EndpointMetaData.java
trunk/src/main/java/org/jboss/ws/metadata/ServerEndpointMetaData.java
trunk/src/main/java/org/jboss/ws/server/ServiceEndpointManager.java
trunk/src/test/java/org/jboss/test/ws/jaxws/jbws1178/JBWS1178TestCase.java
trunk/src/test/resources/jaxws/jbws1178/WEB-INF/web.xml
Log:
[JBWS-864] soap:address in wsdl ignores <url-pattern>
Modified: trunk/src/main/java/org/jboss/ws/annotation/PortComponent.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/annotation/PortComponent.java 2006-11-21 10:41:18 UTC
(rev 1481)
+++ trunk/src/main/java/org/jboss/ws/annotation/PortComponent.java 2006-11-21 10:44:00 UTC
(rev 1482)
@@ -47,6 +47,13 @@
String contextRoot() default "";
/**
+ * The virtual hosts that the web service endpoint is deployed to.
+ *
+ * Applies to server side port components only.
+ */
+ String[] virtualHosts() default {};
+
+ /**
* Relative path that is appended to the contextRoot to form fully qualified
* endpoint address for the web service endpoint.
*
Modified:
trunk/src/main/java/org/jboss/ws/integration/jboss50/JBossServiceEndpointServlet.java
===================================================================
---
trunk/src/main/java/org/jboss/ws/integration/jboss50/JBossServiceEndpointServlet.java 2006-11-21
10:41:18 UTC (rev 1481)
+++
trunk/src/main/java/org/jboss/ws/integration/jboss50/JBossServiceEndpointServlet.java 2006-11-21
10:44:00 UTC (rev 1482)
@@ -68,7 +68,7 @@
sepMetaData.setConfigName(configName);
sepMetaData.setConfigFile(configFile);
- List<HandlerMetaData> sepHandlers =
sepMetaData.getHandlers(HandlerType.ENDPOINT);
+ List<HandlerMetaData> sepHandlers =
sepMetaData.getHandlerMetaData(HandlerType.ENDPOINT);
sepMetaData.clearHandlers();
// Add pre handlers
Modified: trunk/src/main/java/org/jboss/ws/jaxrpc/ServiceObjectFactory.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jaxrpc/ServiceObjectFactory.java 2006-11-21 10:41:18
UTC (rev 1481)
+++ trunk/src/main/java/org/jboss/ws/jaxrpc/ServiceObjectFactory.java 2006-11-21 10:44:00
UTC (rev 1482)
@@ -302,7 +302,7 @@
Set<String> handlerRoles = new HashSet<String>();
ArrayList handlerInfos = new ArrayList();
- for (HandlerMetaData handlerMetaData : epMetaData.getHandlers(HandlerType.ALL))
+ for (HandlerMetaData handlerMetaData :
epMetaData.getHandlerMetaData(HandlerType.ALL))
{
HandlerMetaDataJAXRPC jaxrpcMetaData =
(HandlerMetaDataJAXRPC)handlerMetaData;
handlerRoles.addAll(jaxrpcMetaData.getSoapRoles());
Modified: trunk/src/main/java/org/jboss/ws/jaxrpc/handler/HandlerDelegateJAXRPC.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jaxrpc/handler/HandlerDelegateJAXRPC.java 2006-11-21
10:41:18 UTC (rev 1481)
+++ trunk/src/main/java/org/jboss/ws/jaxrpc/handler/HandlerDelegateJAXRPC.java 2006-11-21
10:44:00 UTC (rev 1482)
@@ -148,7 +148,7 @@
List<HandlerInfo> hInfos = new ArrayList<HandlerInfo>();
ServerEndpointMetaData sepMetaData = seInfo.getServerEndpointMetaData();
- for (HandlerMetaData handlerMetaData : sepMetaData.getHandlers(type))
+ for (HandlerMetaData handlerMetaData : sepMetaData.getHandlerMetaData(type))
{
HandlerMetaDataJAXRPC jaxrpcMetaData = (HandlerMetaDataJAXRPC)handlerMetaData;
handlerRoles.addAll(jaxrpcMetaData.getSoapRoles());
Modified: trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerResolverImpl.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerResolverImpl.java 2006-11-21
10:41:18 UTC (rev 1481)
+++ trunk/src/main/java/org/jboss/ws/jaxws/handler/HandlerResolverImpl.java 2006-11-21
10:44:00 UTC (rev 1482)
@@ -131,7 +131,7 @@
public void initHandlerChain(EndpointMetaData epMetaData, HandlerType type)
{
log.debug("initHandlerChain: " + type);
- for (HandlerMetaData handlerMetaData : epMetaData.getHandlers(type))
+ for (HandlerMetaData handlerMetaData : epMetaData.getHandlerMetaData(type))
{
HandlerMetaDataJAXWS jaxwsMetaData = (HandlerMetaDataJAXWS)handlerMetaData;
String handlerName = jaxwsMetaData.getHandlerName();
Modified: trunk/src/main/java/org/jboss/ws/metadata/ClientEndpointMetaData.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/ClientEndpointMetaData.java 2006-11-21
10:41:18 UTC (rev 1481)
+++ trunk/src/main/java/org/jboss/ws/metadata/ClientEndpointMetaData.java 2006-11-21
10:44:00 UTC (rev 1482)
@@ -168,7 +168,7 @@
{
buffer.append("\n" + opMetaData);
}
- for (HandlerMetaData hdlMetaData : getHandlers(HandlerType.ALL))
+ for (HandlerMetaData hdlMetaData : getHandlerMetaData(HandlerType.ALL))
{
buffer.append("\n" + hdlMetaData);
}
Modified: trunk/src/main/java/org/jboss/ws/metadata/EndpointMetaData.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/EndpointMetaData.java 2006-11-21 10:41:18
UTC (rev 1481)
+++ trunk/src/main/java/org/jboss/ws/metadata/EndpointMetaData.java 2006-11-21 10:44:00
UTC (rev 1482)
@@ -438,7 +438,7 @@
handlersInitialized = false;
}
- public List<HandlerMetaData> getHandlers(HandlerType type)
+ public List<HandlerMetaData> getHandlerMetaData(HandlerType type)
{
List<HandlerMetaData> typeHandlers = new ArrayList<HandlerMetaData>();
for (HandlerMetaData hmd : handlers)
Modified: trunk/src/main/java/org/jboss/ws/metadata/ServerEndpointMetaData.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/metadata/ServerEndpointMetaData.java 2006-11-21
10:41:18 UTC (rev 1481)
+++ trunk/src/main/java/org/jboss/ws/metadata/ServerEndpointMetaData.java 2006-11-21
10:44:00 UTC (rev 1482)
@@ -64,6 +64,8 @@
private ObjectName sepID;
// The HTTP context root
private String contextRoot;
+ // The HTTP virtual hosts
+ private String[] virtualHosts;
// The HTTP url parttern
private String urlPattern;
// The bean that registers with the ServiceEndpointManager
@@ -139,6 +141,16 @@
this.contextRoot = contextRoot;
}
+ public String[] getVirtualHosts()
+ {
+ return virtualHosts;
+ }
+
+ public void setVirtualHosts(String[] virtualHosts)
+ {
+ this.virtualHosts = virtualHosts;
+ }
+
public String getURLPattern()
{
return urlPattern;
@@ -267,7 +279,7 @@
{
buffer.append("\n" + opMetaData);
}
- for (HandlerMetaData hdlMetaData : getHandlers(HandlerType.ALL))
+ for (HandlerMetaData hdlMetaData : getHandlerMetaData(HandlerType.ALL))
{
buffer.append("\n" + hdlMetaData);
}
Modified: trunk/src/main/java/org/jboss/ws/server/ServiceEndpointManager.java
===================================================================
--- trunk/src/main/java/org/jboss/ws/server/ServiceEndpointManager.java 2006-11-21
10:41:18 UTC (rev 1481)
+++ trunk/src/main/java/org/jboss/ws/server/ServiceEndpointManager.java 2006-11-21
10:44:00 UTC (rev 1482)
@@ -508,7 +508,7 @@
if (wsEndpoint != null)
{
ServerEndpointMetaData sepMetaData =
wsEndpoint.getServiceEndpointInfo().getServerEndpointMetaData();
- handlers = sepMetaData.getHandlers(HandlerType.ALL);
+ handlers = sepMetaData.getHandlerMetaData(HandlerType.ALL);
}
return handlers;
}
Modified: trunk/src/test/java/org/jboss/test/ws/jaxws/jbws1178/JBWS1178TestCase.java
===================================================================
--- trunk/src/test/java/org/jboss/test/ws/jaxws/jbws1178/JBWS1178TestCase.java 2006-11-21
10:41:18 UTC (rev 1481)
+++ trunk/src/test/java/org/jboss/test/ws/jaxws/jbws1178/JBWS1178TestCase.java 2006-11-21
10:44:00 UTC (rev 1482)
@@ -37,9 +37,8 @@
import org.jboss.ws.jaxrpc.CallImpl;
/**
- * Multiple virtual host and soap:address problem
- *
- *
http://jira.jboss.org/jira/browse/JBWS-1178
+ * [JBWS-1178] Multiple virtual host and soap:address problem
+ * [JBWS-864] soap:address in wsdl ignores <url-pattern>
*
* @author Thomas.Diesler(a)jboss.com
* @since 05-Oct-2006
@@ -70,7 +69,7 @@
public void testHostAddress() throws Exception
{
InetAddress inetAddr = InetAddress.getByName(getServerHost());
- URL wsdlURL = new URL("http://" + inetAddr.getHostAddress() +
":8080/jaxws-jbws1178?wsdl");
+ URL wsdlURL = new URL("http://" + inetAddr.getHostAddress() +
":8080/jaxws-jbws1178/testpattern?wsdl");
ServiceFactory factory = ServiceFactory.newInstance();
QName serviceName = new QName("http://org.jboss.ws/jbws1178",
"TestEndpointService");
@@ -85,7 +84,7 @@
public void testHostName() throws Exception
{
InetAddress inetAddr = InetAddress.getByName(getServerHost());
- URL wsdlURL = new URL("http://" + inetAddr.getHostName() +
":8080/jaxws-jbws1178?wsdl");
+ URL wsdlURL = new URL("http://" + inetAddr.getHostName() +
":8080/jaxws-jbws1178/testpattern?wsdl");
ServiceFactory factory = ServiceFactory.newInstance();
QName serviceName = new QName("http://org.jboss.ws/jbws1178",
"TestEndpointService");
Modified: trunk/src/test/resources/jaxws/jbws1178/WEB-INF/web.xml
===================================================================
--- trunk/src/test/resources/jaxws/jbws1178/WEB-INF/web.xml 2006-11-21 10:41:18 UTC (rev
1481)
+++ trunk/src/test/resources/jaxws/jbws1178/WEB-INF/web.xml 2006-11-21 10:44:00 UTC (rev
1482)
@@ -10,6 +10,7 @@
<servlet-mapping>
<servlet-name>TestEndpoint</servlet-name>
- <url-pattern>/*</url-pattern>
+ <!-- [JBWS-864] soap:address in wsdl ignores <url-pattern> -->
+ <url-pattern>/testpattern</url-pattern>
</servlet-mapping>
</web-app>
\ No newline at end of file