Author: mriou
Date: Mon Sep 15 16:04:53 2008
New Revision: 695682
URL: http://svn.apache.org/viewvc?rev=695682&view=rev
Log:
Static JMS Destinations Parsed Incorrectly
Modified:
ode/branches/APACHE_ODE_1.X/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java
Modified:
ode/branches/APACHE_ODE_1.X/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java
URL:
http://svn.apache.org/viewvc/ode/branches/APACHE_ODE_1.X/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java?rev=695682&r1=695681&r2=695682&view=diff
==============================================================================
---
ode/branches/APACHE_ODE_1.X/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java
(original)
+++
ode/branches/APACHE_ODE_1.X/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java
Mon Sep 15 16:04:53 2008
@@ -153,8 +153,10 @@
if (index == -1) {
destinationPrefix = baseUri + "/";
index = serviceName.indexOf(destinationPrefix);
+ return (index != -1) ?
serviceName.substring(destinationPrefix.length()) : serviceName;
+ } else {
+ return serviceName.substring(index);
}
- return (index != -1) ? serviceName.substring(index) : serviceName;
}
public static AxisService createService(AxisConfiguration axisConfig,
QName serviceQName, String port,
@@ -224,7 +226,7 @@
String servicePrefix = "/processes/";
// Don't assume JMS-based paths start the same way
if (path.startsWith("jms")) {
- servicePrefix = "jms:/";
+ servicePrefix = "jms://";
}
int index = path.indexOf(servicePrefix);
if (-1 != index) {
@@ -240,7 +242,8 @@
}
// Qualify shared JMS names with unique baseUri
if (path.startsWith("jms")) {
- service = baseUri + "/" + service;
+ boolean slashPresent = baseUri.endsWith("/") ||
service.startsWith("/");
+ service = baseUri + (slashPresent ? "" : "/") + service;
}
return service;
}
@@ -307,11 +310,11 @@
if (bundleName != null) {
baseServiceUri.append(bundleName).append("/");
if (pconf.getBpelDocument() != null) {
- String diagramName =
pconf.getBpelDocument();
- if (diagramName.indexOf(".") > 0) {
- diagramName =
diagramName.substring(0, diagramName.indexOf(".") - 1);
+ String bpelDocumentName =
pconf.getBpelDocument();
+ if (bpelDocumentName.indexOf(".") > 0) {
+ bpelDocumentName =
bpelDocumentName.substring(0, bpelDocumentName.indexOf("."));
}
-
baseServiceUri.append(diagramName).append("/");
+
baseServiceUri.append(bpelDocumentName).append("/");
String processName = pconf.getType() !=
null
?
pconf.getType().getLocalPart() : null;
if (processName != null) {