summaryrefslogtreecommitdiff
path: root/java/src/IceInternal/ProxyFactory.java
diff options
context:
space:
mode:
Diffstat (limited to 'java/src/IceInternal/ProxyFactory.java')
-rw-r--r--java/src/IceInternal/ProxyFactory.java33
1 files changed, 18 insertions, 15 deletions
diff --git a/java/src/IceInternal/ProxyFactory.java b/java/src/IceInternal/ProxyFactory.java
index 45d3ea2c557..b70d70f9511 100644
--- a/java/src/IceInternal/ProxyFactory.java
+++ b/java/src/IceInternal/ProxyFactory.java
@@ -105,20 +105,7 @@ public final class ProxyFactory
{
Ice.ObjectNotExistException one = (Ice.ObjectNotExistException)ex;
- LocatorInfo li = ref.getLocatorInfo();
- if(li != null && ref.isIndirect())
- {
- //
- // We retry ObjectNotExistException if the reference is
- // indirect.
- //
-
- if(ref.isWellKnown())
- {
- li.clearCache(ref);
- }
- }
- else if(ref.getRouterInfo() != null && one.operation.equals("ice_add_proxy"))
+ if(ref.getRouterInfo() != null && one.operation.equals("ice_add_proxy"))
{
//
// If we have a router, an ObjectNotExistException with an
@@ -140,6 +127,22 @@ public final class ProxyFactory
}
return cnt; // We must always retry, so we don't look at the retry count.
}
+ else if(ref.isIndirect())
+ {
+ //
+ // We retry ObjectNotExistException if the reference is
+ // indirect.
+ //
+
+ if(ref.isWellKnown())
+ {
+ LocatorInfo li = ref.getLocatorInfo();
+ if(li != null)
+ {
+ li.clearCache(ref);
+ }
+ }
+ }
else
{
//
@@ -220,7 +223,7 @@ public final class ProxyFactory
//
try
{
- Thread.currentThread().sleep(interval);
+ Thread.sleep(interval);
}
catch(InterruptedException ex1)
{