summaryrefslogtreecommitdiff
path: root/qpid/java/common/src
diff options
context:
space:
mode:
Diffstat (limited to 'qpid/java/common/src')
-rw-r--r--qpid/java/common/src/main/java/org/apache/qpid/transport/Session.java9
-rw-r--r--qpid/java/common/src/main/java/org/apache/qpid/transport/SessionDelegate.java4
2 files changed, 11 insertions, 2 deletions
diff --git a/qpid/java/common/src/main/java/org/apache/qpid/transport/Session.java b/qpid/java/common/src/main/java/org/apache/qpid/transport/Session.java
index 22561dcc33..1a44ed8973 100644
--- a/qpid/java/common/src/main/java/org/apache/qpid/transport/Session.java
+++ b/qpid/java/common/src/main/java/org/apache/qpid/transport/Session.java
@@ -179,7 +179,9 @@ public class Session extends SessionInvoker
{
initReceiver();
sessionAttach(name.getBytes());
- sessionRequestTimeout(expiry);
+ // XXX: when the broker and client support full session
+ // recovery we should use expiry as the requested timeout
+ sessionRequestTimeout(0);
}
void resume()
@@ -734,6 +736,11 @@ public class Session extends SessionInvoker
synchronized (commands)
{
state = CLOSING;
+ // XXX: we manually set the expiry to zero here to
+ // simulate full session recovery in brokers that don't
+ // support it, we should remove this line when there is
+ // broker support for full session resume:
+ expiry = 0;
sessionRequestTimeout(0);
sessionDetach(name.getBytes());
Waiter w = new Waiter(commands, timeout);
diff --git a/qpid/java/common/src/main/java/org/apache/qpid/transport/SessionDelegate.java b/qpid/java/common/src/main/java/org/apache/qpid/transport/SessionDelegate.java
index 520291e71c..b2c22f22e9 100644
--- a/qpid/java/common/src/main/java/org/apache/qpid/transport/SessionDelegate.java
+++ b/qpid/java/common/src/main/java/org/apache/qpid/transport/SessionDelegate.java
@@ -64,7 +64,9 @@ public class SessionDelegate
@Override public void sessionTimeout(Session ssn, SessionTimeout t)
{
- ssn.setExpiry(t.getTimeout());
+ // XXX: we ignore this right now, we should uncomment this
+ // when full session resume is supported:
+ // ssn.setExpiry(t.getTimeout());
}
@Override public void sessionCompleted(Session ssn, SessionCompleted cmp)