Author: sergeyb
Date: Thu Aug 15 10:38:09 2013
New Revision: 1514230
URL: http://svn.apache.org/r1514230
Log:
Merged revisions 1514018 via svnmerge from
https://svn.apache.org/repos/asf/cxf/trunk
........
r1514018 | sergeyb | 2013-08-14 22:49:20 +0300 (Wed, 14 Aug 2013) | 1 line
[CXF-5185] NPE guard in FailoverTargetSelector
........
Modified:
cxf/branches/2.7.x-fixes/ (props changed)
cxf/branches/2.7.x-fixes/rt/features/clustering/src/main/java/org/apache/cxf/clustering/FailoverTargetSelector.java
Propchange: cxf/branches/2.7.x-fixes/
------------------------------------------------------------------------------
Merged /cxf/trunk:r1514018
Propchange: cxf/branches/2.7.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.
Modified:
cxf/branches/2.7.x-fixes/rt/features/clustering/src/main/java/org/apache/cxf/clustering/FailoverTargetSelector.java
URL:
http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/rt/features/clustering/src/main/java/org/apache/cxf/clustering/FailoverTargetSelector.java?rev=1514230&r1=1514229&r2=1514230&view=diff
==============================================================================
---
cxf/branches/2.7.x-fixes/rt/features/clustering/src/main/java/org/apache/cxf/clustering/FailoverTargetSelector.java
(original)
+++
cxf/branches/2.7.x-fixes/rt/features/clustering/src/main/java/org/apache/cxf/clustering/FailoverTargetSelector.java
Thu Aug 15 10:38:09 2013
@@ -392,16 +392,18 @@ public class FailoverTargetSelector exte
}
Endpoint retrieveOriginalEndpoint(Endpoint endpoint) {
- if (endpoint != originalEndpoint) {
- getLogger().log(Level.INFO,
- "REVERT_TO_ORIGINAL_TARGET",
- endpoint.getEndpointInfo().getName());
- }
- if
(!endpoint.getEndpointInfo().getAddress().equals(originalAddress)) {
- endpoint.getEndpointInfo().setAddress(originalAddress);
- getLogger().log(Level.INFO,
- "REVERT_TO_ORIGINAL_ADDRESS",
- endpoint.getEndpointInfo().getAddress());
+ if (endpoint != null) {
+ if (endpoint != originalEndpoint) {
+ getLogger().log(Level.INFO,
+ "REVERT_TO_ORIGINAL_TARGET",
+ endpoint.getEndpointInfo().getName());
+ }
+ if
(!endpoint.getEndpointInfo().getAddress().equals(originalAddress)) {
+ endpoint.getEndpointInfo().setAddress(originalAddress);
+ getLogger().log(Level.INFO,
+ "REVERT_TO_ORIGINAL_ADDRESS",
+ endpoint.getEndpointInfo().getAddress());
+ }
}
return originalEndpoint;
}