Author: veithen
Date: Sun May 23 18:39:33 2010
New Revision: 947463
URL: http://svn.apache.org/viewvc?rev=947463&view=rev
Log:
AXIS2-4722: Set the useGlobalListener attribute automatically based on the
configuration of the transport.
Modified:
axis/axis2/java/transports/trunk/modules/base/src/main/java/org/apache/axis2/transport/base/AbstractTransportListenerEx.java
axis/axis2/java/transports/trunk/modules/udp/src/main/java/org/apache/axis2/transport/udp/UDPListener.java
Modified:
axis/axis2/java/transports/trunk/modules/base/src/main/java/org/apache/axis2/transport/base/AbstractTransportListenerEx.java
URL:
http://svn.apache.org/viewvc/axis/axis2/java/transports/trunk/modules/base/src/main/java/org/apache/axis2/transport/base/AbstractTransportListenerEx.java?rev=947463&r1=947462&r2=947463&view=diff
==============================================================================
---
axis/axis2/java/transports/trunk/modules/base/src/main/java/org/apache/axis2/transport/base/AbstractTransportListenerEx.java
(original)
+++
axis/axis2/java/transports/trunk/modules/base/src/main/java/org/apache/axis2/transport/base/AbstractTransportListenerEx.java
Sun May 23 18:39:33 2010
@@ -45,7 +45,7 @@ public abstract class AbstractTransportL
/** A Map of service name to the protocol endpoints */
private List<E> endpoints = new ArrayList<E>();
- protected boolean useGlobalListener = false;
+ private boolean useGlobalListener;
@Override
public final void init(ConfigurationContext cfgCtx,
@@ -61,6 +61,7 @@ public abstract class AbstractTransportL
if (endpoint.loadConfiguration(transportIn)) {
startEndpoint(endpoint);
endpoints.add(endpoint);
+ useGlobalListener = true;
}
}
@@ -144,8 +145,10 @@ public abstract class AbstractTransportL
return;
}
}
- log.error("Unable to stop service : " + service.getName() +
- " - unable to find the corresponding protocol endpoint");
+ if (!useGlobalListener) {
+ log.error("Unable to stop service : " + service.getName() +
+ " - unable to find the corresponding protocol endpoint");
+ }
}
protected abstract void stopEndpoint(E endpoint);
Modified:
axis/axis2/java/transports/trunk/modules/udp/src/main/java/org/apache/axis2/transport/udp/UDPListener.java
URL:
http://svn.apache.org/viewvc/axis/axis2/java/transports/trunk/modules/udp/src/main/java/org/apache/axis2/transport/udp/UDPListener.java?rev=947463&r1=947462&r2=947463&view=diff
==============================================================================
---
axis/axis2/java/transports/trunk/modules/udp/src/main/java/org/apache/axis2/transport/udp/UDPListener.java
(original)
+++
axis/axis2/java/transports/trunk/modules/udp/src/main/java/org/apache/axis2/transport/udp/UDPListener.java
Sun May 23 18:39:33 2010
@@ -44,10 +44,6 @@ import org.apache.axis2.transport.base.d
public class UDPListener extends AbstractDatagramTransportListener<Endpoint>
implements ManagementSupport {
- public UDPListener() {
- this.useGlobalListener = true;
- }
-
@Override
protected IODispatcher createDispatcher(DatagramDispatcherCallback
callback)
throws IOException {