[1/2] qpid-broker-j git commit: QPID-7782: [Tests] Generalise test framework class org.apache.qpid.tests.protocol.v1_0.Response

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[1/2] qpid-broker-j git commit: QPID-7782: [Tests] Generalise test framework class org.apache.qpid.tests.protocol.v1_0.Response

orudyy
Repository: qpid-broker-j
Updated Branches:
  refs/heads/master 82ef9deaa -> 2535b45de


http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/session/BeginTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/session/BeginTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/session/BeginTest.java
index 31a48af..663ed34 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/session/BeginTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/session/BeginTest.java
@@ -58,8 +58,8 @@ public class BeginTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), equalTo(AmqpError.DECODE_ERROR));
         }
@@ -85,8 +85,8 @@ public class BeginTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Begin.class)));
-            Begin responseBegin = (Begin) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Begin.class)));
+            Begin responseBegin = (Begin) response.getBody();
             assertThat(responseBegin.getRemoteChannel(), equalTo(channel));
             assertThat(responseBegin.getIncomingWindow(), is(instanceOf(UnsignedInteger.class)));
             assertThat(responseBegin.getOutgoingWindow(), is(instanceOf(UnsignedInteger.class)));
@@ -115,7 +115,7 @@ public class BeginTest extends ProtocolTestBase
             transport.sendPerformative(open, UnsignedShort.valueOf((short) 0));
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
 
             Begin begin = new Begin();
             begin.setNextOutgoingId(UnsignedInteger.ZERO);
@@ -127,8 +127,8 @@ public class BeginTest extends ProtocolTestBase
             response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), equalTo(ConnectionError.FRAMING_ERROR));
         }


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[2/2] qpid-broker-j git commit: QPID-7782: [Tests] Generalise test framework class org.apache.qpid.tests.protocol.v1_0.Response

orudyy
QPID-7782: [Tests] Generalise test framework class org.apache.qpid.tests.protocol.v1_0.Response


Project: http://git-wip-us.apache.org/repos/asf/qpid-broker-j/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-broker-j/commit/2535b45d
Tree: http://git-wip-us.apache.org/repos/asf/qpid-broker-j/tree/2535b45d
Diff: http://git-wip-us.apache.org/repos/asf/qpid-broker-j/diff/2535b45d

Branch: refs/heads/master
Commit: 2535b45de2e1e3abbaad76dc9d45403d1da980f5
Parents: 82ef9de
Author: Alex Rudyy <[hidden email]>
Authored: Mon Jun 12 12:32:05 2017 +0100
Committer: Alex Rudyy <[hidden email]>
Committed: Mon Jun 12 12:52:46 2017 +0100

----------------------------------------------------------------------
 .../tests/protocol/v1_0/FrameTransport.java     | 60 +++++++++-----------
 .../tests/protocol/v1_0/HeaderResponse.java     |  5 +-
 .../qpid/tests/protocol/v1_0/InputHandler.java  |  4 +-
 .../qpid/tests/protocol/v1_0/Matchers.java      |  2 +-
 .../protocol/v1_0/PerformativeResponse.java     |  6 +-
 .../qpid/tests/protocol/v1_0/Response.java      |  3 +-
 .../protocol/v1_0/SaslPerformativeResponse.java |  5 +-
 .../apache/qpid/tests/protocol/v1_0/Utils.java  | 12 ++--
 .../bindmapjms/TemporaryDestinationTest.java    |  6 +-
 .../soleconn/CloseExistingPolicy.java           | 36 ++++++------
 .../v1_0/extensions/soleconn/MixedPolicy.java   | 16 +++---
 .../soleconn/RefuseConnectionPolicy.java        | 46 +++++++--------
 .../extensions/websocket/WebSocketTest.java     | 12 ++--
 .../v1_0/messaging/DeleteOnCloseTest.java       | 24 ++++----
 .../protocol/v1_0/messaging/TransferTest.java   | 50 ++++++++--------
 .../v1_0/transport/ProtocolHeaderTest.java      |  4 +-
 .../v1_0/transport/connection/OpenTest.java     | 20 +++----
 .../v1_0/transport/link/AttachTest.java         | 12 ++--
 .../protocol/v1_0/transport/link/FlowTest.java  | 16 +++---
 .../v1_0/transport/security/sasl/SaslTest.java  | 46 +++++++--------
 .../v1_0/transport/session/BeginTest.java       | 14 ++---
 21 files changed, 199 insertions(+), 200 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/FrameTransport.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/FrameTransport.java b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/FrameTransport.java
index 16eb3d8..b72ed4e 100644
--- a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/FrameTransport.java
+++ b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/FrameTransport.java
@@ -79,7 +79,8 @@ public class FrameTransport implements AutoCloseable
     private static final Set<Integer> AMQP_CONNECTION_IDS = Collections.newSetFromMap(new ConcurrentHashMap<>());
     private static final Response CHANNEL_CLOSED_RESPONSE = new ChannelClosedResponse();
 
-    private final BlockingQueue<Response> _queue = new ArrayBlockingQueue<>(100);
+    private final BlockingQueue<Response<?>> _queue = new ArrayBlockingQueue<>(100);
+
     private final EventLoopGroup _workerGroup;
     private final InetSocketAddress _brokerAddress;
     private final boolean _isSasl;
@@ -218,14 +219,14 @@ public class FrameTransport implements AutoCloseable
         return sendPipelined(null, frames);
     }
 
-    public Response getNextResponse() throws Exception
+    public <T extends Response<?>> T getNextResponse() throws Exception
     {
-        return _queue.poll(RESPONSE_TIMEOUT, TimeUnit.MILLISECONDS);
+        return (T)_queue.poll(RESPONSE_TIMEOUT, TimeUnit.MILLISECONDS);
     }
 
-    public <R extends Response> R getNextResponse(Class<? extends Response> expectedResponseClass) throws Exception
+    public <R extends Response<?>> R getNextResponse(Class<R> expectedResponseClass) throws Exception
     {
-        R actualResponse = (R) getNextResponse();
+        R actualResponse = getNextResponse();
         if (actualResponse == null)
         {
             throw new IllegalStateException(String.format("No response received within timeout %d - expecting %s",
@@ -241,23 +242,10 @@ public class FrameTransport implements AutoCloseable
         return actualResponse;
     }
 
-    public <P> P getNextPerformativeResponse(Class<?> expectedFrameBodyClass) throws Exception
+    public <T> T getNextResponseBody(Class<T> expectedFrameBodyClass) throws Exception
     {
-        final P actualFrameBody;
-        if (SaslFrameBody.class.isAssignableFrom(expectedFrameBodyClass))
-        {
-            SaslPerformativeResponse response = getNextResponse(SaslPerformativeResponse.class);
-            actualFrameBody = (P) response.getFrameBody();
-        }
-        else if (FrameBody.class.isAssignableFrom(expectedFrameBodyClass))
-        {
-            PerformativeResponse response = getNextResponse(PerformativeResponse.class);
-            actualFrameBody = (P) response.getFrameBody();
-        }
-        else
-        {
-            throw new IllegalArgumentException(String.format("Unexpected class %s", expectedFrameBodyClass.getName()));
-        }
+        Response<T>  response = getNextResponse();
+        T actualFrameBody =  response.getBody();
 
         if (!expectedFrameBodyClass.isAssignableFrom(actualFrameBody.getClass()))
         {
@@ -275,7 +263,7 @@ public class FrameTransport implements AutoCloseable
         sendProtocolHeader(bytes);
         HeaderResponse response = (HeaderResponse) getNextResponse();
 
-        if (!Arrays.equals(bytes, response.getHeader()))
+        if (!Arrays.equals(bytes, response.getBody()))
         {
             throw new IllegalStateException("Unexpected protocol header");
         }
@@ -289,7 +277,7 @@ public class FrameTransport implements AutoCloseable
         open.setContainerId(String.format("testContainer-%d", getConnectionId()));
         sendPerformative(open, UnsignedShort.valueOf((short) 0));
         PerformativeResponse response = (PerformativeResponse) getNextResponse();
-        if (!(response.getFrameBody() instanceof Open))
+        if (!(response.getBody() instanceof Open))
         {
             throw new IllegalStateException("Unexpected response to connection Open");
         }
@@ -301,10 +289,10 @@ public class FrameTransport implements AutoCloseable
 
         sendPerformative(close, UnsignedShort.valueOf((short) 0));
         PerformativeResponse response = (PerformativeResponse) getNextResponse();
-        if (!(response.getFrameBody() instanceof Close))
+        if (!(response.getBody() instanceof Close))
         {
             throw new IllegalStateException(String.format(
-                    "Unexpected response to connection Close. Expected Close got '%s'", response.getFrameBody()));
+                    "Unexpected response to connection Close. Expected Close got '%s'", response.getBody()));
         }
     }
 
@@ -318,10 +306,10 @@ public class FrameTransport implements AutoCloseable
         _amqpChannelId = (short) 1;
         sendPerformative(begin, UnsignedShort.valueOf(_amqpChannelId));
         PerformativeResponse response = (PerformativeResponse) getNextResponse();
-        if (!(response.getFrameBody() instanceof Begin))
+        if (!(response.getBody() instanceof Begin))
         {
             throw new IllegalStateException(String.format(
-                    "Unexpected response to connection Begin. Expected Begin got '%s'", response.getFrameBody()));
+                    "Unexpected response to connection Begin. Expected Begin got '%s'", response.getBody()));
         }
     }
 
@@ -348,8 +336,8 @@ public class FrameTransport implements AutoCloseable
         PerformativeResponse response = (PerformativeResponse) getNextResponse();
 
         assertThat(response, is(notNullValue()));
-        assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-        Attach responseAttach = (Attach) response.getFrameBody();
+        assertThat(response.getBody(), is(instanceOf(Attach.class)));
+        Attach responseAttach = (Attach) response.getBody();
         assertThat(responseAttach.getSource(), is(notNullValue()));
     }
 
@@ -377,13 +365,13 @@ public class FrameTransport implements AutoCloseable
         PerformativeResponse response = (PerformativeResponse) getNextResponse();
 
         assertThat(response, is(notNullValue()));
-        assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-        Attach responseAttach = (Attach) response.getFrameBody();
+        assertThat(response.getBody(), is(instanceOf(Attach.class)));
+        Attach responseAttach = (Attach) response.getBody();
         assertThat(responseAttach.getTarget(), is(notNullValue()));
 
         PerformativeResponse flowResponse = (PerformativeResponse) getNextResponse();
         assertThat(flowResponse, Is.is(CoreMatchers.notNullValue()));
-        assertThat(flowResponse.getFrameBody(), Is.is(CoreMatchers.instanceOf(Flow.class)));
+        assertThat(flowResponse.getBody(), Is.is(CoreMatchers.instanceOf(Flow.class)));
     }
 
     public void assertNoMoreResponses() throws Exception
@@ -411,12 +399,18 @@ public class FrameTransport implements AutoCloseable
         return _amqpConnectionId;
     }
 
-    private static class ChannelClosedResponse implements Response
+    private static class ChannelClosedResponse implements Response<Void>
     {
         @Override
         public String toString()
         {
             return "ChannelClosed";
         }
+
+        @Override
+        public Void getBody()
+        {
+            return null;
+        }
     }
 }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/HeaderResponse.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/HeaderResponse.java b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/HeaderResponse.java
index 8ab2b5c..9503113 100644
--- a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/HeaderResponse.java
+++ b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/HeaderResponse.java
@@ -21,7 +21,7 @@ package org.apache.qpid.tests.protocol.v1_0;
 
 import java.util.Arrays;
 
-public class HeaderResponse implements Response
+public class HeaderResponse implements Response<byte[]>
 {
     private final byte[] _header;
 
@@ -30,7 +30,8 @@ public class HeaderResponse implements Response
         _header = header;
     }
 
-    public byte[] getHeader()
+    @Override
+    public byte[] getBody()
     {
         return _header;
     }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/InputHandler.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/InputHandler.java b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/InputHandler.java
index 10fde24..a8663a4 100644
--- a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/InputHandler.java
+++ b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/InputHandler.java
@@ -73,13 +73,13 @@ public class InputHandler extends ChannelInboundHandlerAdapter
 
     private final MyConnectionHandler _connectionHandler;
     private final ValueHandler _valueHandler;
-    private final BlockingQueue<Response> _responseQueue;
+    private final BlockingQueue<Response<?>> _responseQueue;
 
     private QpidByteBuffer _inputBuffer = QpidByteBuffer.allocate(0);
     private volatile FrameHandler _frameHandler;
     private volatile ParsingState _state = ParsingState.HEADER;
 
-    public InputHandler(final BlockingQueue<Response> queue, final boolean isSasl)
+    public InputHandler(final BlockingQueue<Response<?>> queue, final boolean isSasl)
     {
 
         _valueHandler = new ValueHandler(TYPE_REGISTRY);

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Matchers.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Matchers.java b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Matchers.java
index e9d6c1e..029dc70 100644
--- a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Matchers.java
+++ b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Matchers.java
@@ -49,7 +49,7 @@ public class Matchers
                 {
                     return false;
                 }
-                if (!Arrays.equals(expectedHeader, ((HeaderResponse) o).getHeader()))
+                if (!Arrays.equals(expectedHeader, ((HeaderResponse) o).getBody()))
                 {
                     return false;
                 }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/PerformativeResponse.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/PerformativeResponse.java b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/PerformativeResponse.java
index 6838d10..06a64dc 100644
--- a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/PerformativeResponse.java
+++ b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/PerformativeResponse.java
@@ -21,7 +21,7 @@ package org.apache.qpid.tests.protocol.v1_0;
 
 import org.apache.qpid.server.protocol.v1_0.type.FrameBody;
 
-public class PerformativeResponse implements Response
+public class PerformativeResponse implements Response<FrameBody>
 {
     private final short _channelId;
     private final FrameBody _frameBody;
@@ -33,11 +33,13 @@ public class PerformativeResponse implements Response
         _frameBody = frameBody;
     }
 
-    public FrameBody getFrameBody()
+    @Override
+    public FrameBody getBody()
     {
         return _frameBody;
     }
 
+
     public short getChannelId()
     {
         return _channelId;

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Response.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Response.java b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Response.java
index 3156737..a7e341c 100644
--- a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Response.java
+++ b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Response.java
@@ -19,6 +19,7 @@
 
 package org.apache.qpid.tests.protocol.v1_0;
 
-public interface Response
+public interface Response<T>
 {
+    T getBody();
 }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/SaslPerformativeResponse.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/SaslPerformativeResponse.java b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/SaslPerformativeResponse.java
index cd2da99..08893e0 100644
--- a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/SaslPerformativeResponse.java
+++ b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/SaslPerformativeResponse.java
@@ -22,7 +22,7 @@ package org.apache.qpid.tests.protocol.v1_0;
 
 import org.apache.qpid.server.protocol.v1_0.type.SaslFrameBody;
 
-public class SaslPerformativeResponse implements Response
+public class SaslPerformativeResponse implements Response<SaslFrameBody>
 {
     private final short _channelId;
     private final SaslFrameBody _frameBody;
@@ -34,7 +34,8 @@ public class SaslPerformativeResponse implements Response
         _frameBody = frameBody;
     }
 
-    public SaslFrameBody getFrameBody()
+    @Override
+    public SaslFrameBody getBody()
     {
         return _frameBody;
     }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Utils.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Utils.java b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Utils.java
index b892589..5d4c52f 100644
--- a/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Utils.java
+++ b/systests/protocol-tests-amqp-1-0/src/main/java/org/apache/qpid/tests/protocol/v1_0/Utils.java
@@ -59,8 +59,8 @@ public class Utils
             transport.sendPerformative(validationAttach);
             PerformativeResponse validationResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(validationResponse, is(notNullValue()));
-            assertThat(validationResponse.getFrameBody(), is(instanceOf(Attach.class)));
-            final Attach attachValidationResponse = (Attach) validationResponse.getFrameBody();
+            assertThat(validationResponse.getBody(), is(instanceOf(Attach.class)));
+            final Attach attachValidationResponse = (Attach) validationResponse.getBody();
             if (attachValidationResponse.getSource() != null)
             {
                 queueExists = true;
@@ -70,14 +70,14 @@ public class Utils
                 transport.sendPerformative(validationDetach);
                 PerformativeResponse validationDetachResponse = (PerformativeResponse) transport.getNextResponse();
                 assertThat(validationDetachResponse, is(notNullValue()));
-                assertThat(validationDetachResponse.getFrameBody(), is(instanceOf(Detach.class)));
+                assertThat(validationDetachResponse.getBody(), is(instanceOf(Detach.class)));
             }
             else
             {
                 queueExists = false;
                 PerformativeResponse validationDetachResponse = (PerformativeResponse) transport.getNextResponse();
                 assertThat(validationDetachResponse, is(notNullValue()));
-                assertThat(validationDetachResponse.getFrameBody(), is(instanceOf(Detach.class)));
+                assertThat(validationDetachResponse.getBody(), is(instanceOf(Detach.class)));
             }
             return queueExists;
         }
@@ -105,8 +105,8 @@ public class Utils
             {
                 PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
                 assertThat(response, Is.is(notNullValue()));
-                assertThat(response.getFrameBody(), Is.is(instanceOf(Transfer.class)));
-                Transfer responseTransfer = (Transfer) response.getFrameBody();
+                assertThat(response.getBody(), Is.is(instanceOf(Transfer.class)));
+                Transfer responseTransfer = (Transfer) response.getBody();
                 messageDecoder.addTransfer(responseTransfer);
                 hasMore = Boolean.TRUE.equals(responseTransfer.getMore());
             }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/bindmapjms/TemporaryDestinationTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/bindmapjms/TemporaryDestinationTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/bindmapjms/TemporaryDestinationTest.java
index 5583f2a..e9a6957 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/bindmapjms/TemporaryDestinationTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/bindmapjms/TemporaryDestinationTest.java
@@ -105,8 +105,8 @@ public class TemporaryDestinationTest extends ProtocolTestBase
 
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-            final Attach attachResponse = (Attach) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Attach.class)));
+            final Attach attachResponse = (Attach) response.getBody();
             assertThat(attachResponse.getSource(), is(notNullValue()));
             assertThat(attachResponse.getTarget(), is(notNullValue()));
 
@@ -118,7 +118,7 @@ public class TemporaryDestinationTest extends ProtocolTestBase
             final PerformativeResponse flowResponse = ((PerformativeResponse) transport.getNextResponse());
             if (flowResponse != null)
             {
-                assertThat(flowResponse.getFrameBody(), is(instanceOf(Flow.class)));
+                assertThat(flowResponse.getBody(), is(instanceOf(Flow.class)));
             }
 
             transport.doCloseConnection();

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/CloseExistingPolicy.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/CloseExistingPolicy.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/CloseExistingPolicy.java
index c3e5999..6d8007a 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/CloseExistingPolicy.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/CloseExistingPolicy.java
@@ -77,8 +77,8 @@ public class CloseExistingPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
-            Open responseOpen = (Open) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
+            Open responseOpen = (Open) response.getBody();
             assertThat(Arrays.asList(responseOpen.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
             if (responseOpen.getProperties().containsKey(SOLE_CONNECTION_DETECTION_POLICY))
             {
@@ -105,7 +105,7 @@ public class CloseExistingPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
 
             try (FrameTransport transport2 = new FrameTransport(_brokerAddress).connect())
             {
@@ -120,16 +120,16 @@ public class CloseExistingPolicy extends ProtocolTestBase
 
                 final PerformativeResponse closeResponse1 = (PerformativeResponse) transport1.getNextResponse();
                 assertThat(closeResponse1, is(notNullValue()));
-                assertThat(closeResponse1.getFrameBody(), is(instanceOf(Close.class)));
-                Close close1 = (Close) closeResponse1.getFrameBody();
+                assertThat(closeResponse1.getBody(), is(instanceOf(Close.class)));
+                Close close1 = (Close) closeResponse1.getBody();
                 assertThat(close1.getError(), is(notNullValue()));
                 assertThat(close1.getError().getCondition(), is(equalTo(AmqpError.RESOURCE_LOCKED)));
                 assertThat(close1.getError().getInfo(), is(equalTo(Collections.singletonMap(Symbol.valueOf("sole-connection-enforcement"), true))));
 
                 PerformativeResponse response2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(response2, is(notNullValue()));
-                assertThat(response2.getFrameBody(), is(instanceOf(Open.class)));
-                Open responseOpen2 = (Open) response2.getFrameBody();
+                assertThat(response2.getBody(), is(instanceOf(Open.class)));
+                Open responseOpen2 = (Open) response2.getBody();
                 assertThat(Arrays.asList(responseOpen2.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
                 if (responseOpen2.getProperties().containsKey(SOLE_CONNECTION_DETECTION_POLICY))
                 {
@@ -156,7 +156,7 @@ public class CloseExistingPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
 
             try (FrameTransport transport2 = new FrameTransport(_brokerAddress).connect())
             {
@@ -171,16 +171,16 @@ public class CloseExistingPolicy extends ProtocolTestBase
 
                 final PerformativeResponse closeResponse1 = (PerformativeResponse) transport1.getNextResponse();
                 assertThat(closeResponse1, is(notNullValue()));
-                assertThat(closeResponse1.getFrameBody(), is(instanceOf(Close.class)));
-                Close close1 = (Close) closeResponse1.getFrameBody();
+                assertThat(closeResponse1.getBody(), is(instanceOf(Close.class)));
+                Close close1 = (Close) closeResponse1.getBody();
                 assertThat(close1.getError(), is(notNullValue()));
                 assertThat(close1.getError().getCondition(), is(equalTo(AmqpError.RESOURCE_LOCKED)));
                 assertThat(close1.getError().getInfo(), is(equalTo(Collections.singletonMap(Symbol.valueOf("sole-connection-enforcement"), true))));
 
                 PerformativeResponse response2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(response2, is(notNullValue()));
-                assertThat(response2.getFrameBody(), is(instanceOf(Open.class)));
-                Open responseOpen2 = (Open) response2.getFrameBody();
+                assertThat(response2.getBody(), is(instanceOf(Open.class)));
+                Open responseOpen2 = (Open) response2.getBody();
                 assertThat(Arrays.asList(responseOpen2.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
                 if (responseOpen2.getProperties().containsKey(SOLE_CONNECTION_DETECTION_POLICY))
                 {
@@ -208,8 +208,8 @@ public class CloseExistingPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
-            Open responseOpen = (Open) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
+            Open responseOpen = (Open) response.getBody();
             assertThat(Arrays.asList(responseOpen.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
             if (responseOpen.getProperties().containsKey(SOLE_CONNECTION_DETECTION_POLICY))
             {
@@ -228,16 +228,16 @@ public class CloseExistingPolicy extends ProtocolTestBase
 
                 final PerformativeResponse closeResponse1 = (PerformativeResponse) transport1.getNextResponse();
                 assertThat(closeResponse1, is(notNullValue()));
-                assertThat(closeResponse1.getFrameBody(), is(instanceOf(Close.class)));
-                Close close1 = (Close) closeResponse1.getFrameBody();
+                assertThat(closeResponse1.getBody(), is(instanceOf(Close.class)));
+                Close close1 = (Close) closeResponse1.getBody();
                 assertThat(close1.getError(), is(notNullValue()));
                 assertThat(close1.getError().getCondition(), is(equalTo(AmqpError.RESOURCE_LOCKED)));
                 assertThat(close1.getError().getInfo(), is(equalTo(Collections.singletonMap(Symbol.valueOf("sole-connection-enforcement"), true))));
 
                 PerformativeResponse response2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(response2, is(notNullValue()));
-                assertThat(response2.getFrameBody(), is(instanceOf(Open.class)));
-                Open responseOpen2 = (Open) response2.getFrameBody();
+                assertThat(response2.getBody(), is(instanceOf(Open.class)));
+                Open responseOpen2 = (Open) response2.getBody();
                 assertThat(Arrays.asList(responseOpen2.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
                 if (responseOpen2.getProperties().containsKey(SOLE_CONNECTION_DETECTION_POLICY))
                 {

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/MixedPolicy.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/MixedPolicy.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/MixedPolicy.java
index 0248a9f..c579bf8 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/MixedPolicy.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/MixedPolicy.java
@@ -69,7 +69,7 @@ public class MixedPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
 
             try (FrameTransport transport2 = new FrameTransport(_brokerAddress).connect())
             {
@@ -84,11 +84,11 @@ public class MixedPolicy extends ProtocolTestBase
 
                 final PerformativeResponse closeResponse1 = (PerformativeResponse) transport1.getNextResponse();
                 assertThat(closeResponse1, is(notNullValue()));
-                assertThat(closeResponse1.getFrameBody(), is(instanceOf(Close.class)));
+                assertThat(closeResponse1.getBody(), is(instanceOf(Close.class)));
 
                 PerformativeResponse response2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(response2, is(notNullValue()));
-                assertThat(response2.getFrameBody(), is(instanceOf(Open.class)));
+                assertThat(response2.getBody(), is(instanceOf(Open.class)));
 
                 try (FrameTransport transport3 = new FrameTransport(_brokerAddress).connect())
                 {
@@ -103,10 +103,10 @@ public class MixedPolicy extends ProtocolTestBase
 
                     PerformativeResponse closeResponse3 = (PerformativeResponse) transport3.getNextResponse();
                     assertThat(closeResponse3, is(notNullValue()));
-                    assertThat(closeResponse3.getFrameBody(), is(instanceOf(Open.class)));
+                    assertThat(closeResponse3.getBody(), is(instanceOf(Open.class)));
                     PerformativeResponse closeResponse3b = (PerformativeResponse) transport3.getNextResponse();
                     assertThat(closeResponse3b, is(notNullValue()));
-                    assertThat(closeResponse3b.getFrameBody(), is(instanceOf(Close.class)));
+                    assertThat(closeResponse3b.getBody(), is(instanceOf(Close.class)));
                 }
             }
         }
@@ -128,7 +128,7 @@ public class MixedPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
 
             try (FrameTransport transport2 = new FrameTransport(_brokerAddress).connect())
             {
@@ -143,10 +143,10 @@ public class MixedPolicy extends ProtocolTestBase
 
                 final PerformativeResponse openResponse2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(openResponse2, is(notNullValue()));
-                assertThat(openResponse2.getFrameBody(), is(instanceOf(Open.class)));
+                assertThat(openResponse2.getBody(), is(instanceOf(Open.class)));
                 final PerformativeResponse closeResponse2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(closeResponse2, is(notNullValue()));
-                assertThat(closeResponse2.getFrameBody(), is(instanceOf(Close.class)));
+                assertThat(closeResponse2.getBody(), is(instanceOf(Close.class)));
             }
         }
     }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/RefuseConnectionPolicy.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/RefuseConnectionPolicy.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/RefuseConnectionPolicy.java
index 409cc17..011508d 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/RefuseConnectionPolicy.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/soleconn/RefuseConnectionPolicy.java
@@ -78,8 +78,8 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
-            Open responseOpen = (Open) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
+            Open responseOpen = (Open) response.getBody();
             assertThat(Arrays.asList(responseOpen.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
             if (responseOpen.getProperties().containsKey(SOLE_CONNECTION_DETECTION_POLICY))
             {
@@ -106,7 +106,7 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
 
             try (FrameTransport transport2 = new FrameTransport(_brokerAddress).connect())
             {
@@ -121,16 +121,16 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
 
                 PerformativeResponse response2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(response2, is(notNullValue()));
-                assertThat(response2.getFrameBody(), is(instanceOf(Open.class)));
-                Open responseOpen2 = (Open) response2.getFrameBody();
+                assertThat(response2.getBody(), is(instanceOf(Open.class)));
+                Open responseOpen2 = (Open) response2.getBody();
                 assertThat(Arrays.asList(responseOpen2.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
                 assertThat(responseOpen2.getProperties(), hasKey(Symbol.valueOf("amqp:connection-establishment-failed")));
                 assertThat(responseOpen2.getProperties().get(Symbol.valueOf("amqp:connection-establishment-failed")), is(true));
 
                 PerformativeResponse closeResponse2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(closeResponse2, is(notNullValue()));
-                assertThat(closeResponse2.getFrameBody(), is(instanceOf(Close.class)));
-                Close close2 = (Close) closeResponse2.getFrameBody();
+                assertThat(closeResponse2.getBody(), is(instanceOf(Close.class)));
+                Close close2 = (Close) closeResponse2.getBody();
                 assertThat(close2.getError(), is(notNullValue()));
                 assertThat(close2.getError().getCondition(), is(equalTo(AmqpError.INVALID_FIELD)));
                 assertThat(close2.getError().getInfo(), is(equalTo(Collections.singletonMap(Symbol.valueOf("invalid-field"), Symbol.valueOf("container-id")))));
@@ -153,7 +153,7 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
 
             try (FrameTransport transport2 = new FrameTransport(_brokerAddress).connect())
             {
@@ -168,16 +168,16 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
 
                 PerformativeResponse response2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(response2, is(notNullValue()));
-                assertThat(response2.getFrameBody(), is(instanceOf(Open.class)));
-                Open responseOpen2 = (Open) response2.getFrameBody();
+                assertThat(response2.getBody(), is(instanceOf(Open.class)));
+                Open responseOpen2 = (Open) response2.getBody();
                 assertThat(Arrays.asList(responseOpen2.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
                 assertThat(responseOpen2.getProperties(), hasKey(Symbol.valueOf("amqp:connection-establishment-failed")));
                 assertThat(responseOpen2.getProperties().get(Symbol.valueOf("amqp:connection-establishment-failed")), is(true));
 
                 PerformativeResponse closeResponse2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(closeResponse2, is(notNullValue()));
-                assertThat(closeResponse2.getFrameBody(), is(instanceOf(Close.class)));
-                Close close2 = (Close) closeResponse2.getFrameBody();
+                assertThat(closeResponse2.getBody(), is(instanceOf(Close.class)));
+                Close close2 = (Close) closeResponse2.getBody();
                 assertThat(close2.getError(), is(notNullValue()));
                 assertThat(close2.getError().getCondition(), is(equalTo(AmqpError.INVALID_FIELD)));
                 assertThat(close2.getError().getInfo(), is(equalTo(Collections.singletonMap(Symbol.valueOf("invalid-field"), Symbol.valueOf("container-id")))));
@@ -201,8 +201,8 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
-            Open responseOpen = (Open) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
+            Open responseOpen = (Open) response.getBody();
             assertThat(Arrays.asList(responseOpen.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
             if (responseOpen.getProperties().containsKey(SOLE_CONNECTION_DETECTION_POLICY))
             {
@@ -221,16 +221,16 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
 
                 PerformativeResponse response2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(response2, is(notNullValue()));
-                assertThat(response2.getFrameBody(), is(instanceOf(Open.class)));
-                Open responseOpen2 = (Open) response2.getFrameBody();
+                assertThat(response2.getBody(), is(instanceOf(Open.class)));
+                Open responseOpen2 = (Open) response2.getBody();
                 assertThat(Arrays.asList(responseOpen2.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
                 assertThat(responseOpen2.getProperties(), hasKey(Symbol.valueOf("amqp:connection-establishment-failed")));
                 assertThat(responseOpen2.getProperties().get(Symbol.valueOf("amqp:connection-establishment-failed")), is(true));
 
                 PerformativeResponse closeResponse2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(closeResponse2, is(notNullValue()));
-                assertThat(closeResponse2.getFrameBody(), is(instanceOf(Close.class)));
-                Close close2 = (Close) closeResponse2.getFrameBody();
+                assertThat(closeResponse2.getBody(), is(instanceOf(Close.class)));
+                Close close2 = (Close) closeResponse2.getBody();
                 assertThat(close2.getError(), is(notNullValue()));
                 assertThat(close2.getError().getCondition(), is(equalTo(AmqpError.INVALID_FIELD)));
                 assertThat(close2.getError().getInfo(), is(equalTo(Collections.singletonMap(Symbol.valueOf("invalid-field"), Symbol.valueOf("container-id")))));
@@ -253,7 +253,7 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport1.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
 
             try (FrameTransport transport2 = new FrameTransport(_brokerAddress).connect())
             {
@@ -267,16 +267,16 @@ public class RefuseConnectionPolicy extends ProtocolTestBase
 
                 PerformativeResponse response2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(response2, is(notNullValue()));
-                assertThat(response2.getFrameBody(), is(instanceOf(Open.class)));
-                Open responseOpen2 = (Open) response2.getFrameBody();
+                assertThat(response2.getBody(), is(instanceOf(Open.class)));
+                Open responseOpen2 = (Open) response2.getBody();
                 assertThat(Arrays.asList(responseOpen2.getOfferedCapabilities()), hasItem(SOLE_CONNECTION_FOR_CONTAINER));
                 assertThat(responseOpen2.getProperties(), hasKey(Symbol.valueOf("amqp:connection-establishment-failed")));
                 assertThat(responseOpen2.getProperties().get(Symbol.valueOf("amqp:connection-establishment-failed")), is(true));
 
                 PerformativeResponse closeResponse2 = (PerformativeResponse) transport2.getNextResponse();
                 assertThat(closeResponse2, is(notNullValue()));
-                assertThat(closeResponse2.getFrameBody(), is(instanceOf(Close.class)));
-                Close close2 = (Close) closeResponse2.getFrameBody();
+                assertThat(closeResponse2.getBody(), is(instanceOf(Close.class)));
+                Close close2 = (Close) closeResponse2.getBody();
                 assertThat(close2.getError(), is(notNullValue()));
                 assertThat(close2.getError().getCondition(), is(equalTo(AmqpError.INVALID_FIELD)));
                 assertThat(close2.getError().getInfo(), is(equalTo(Collections.singletonMap(Symbol.valueOf("invalid-field"), Symbol.valueOf("container-id")))));

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/websocket/WebSocketTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/websocket/WebSocketTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/websocket/WebSocketTest.java
index 23026d8..c0d1a52 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/websocket/WebSocketTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/extensions/websocket/WebSocketTest.java
@@ -55,8 +55,8 @@ public class WebSocketTest extends ProtocolTestBase
         {
             byte[] bytes = "AMQP\0\1\0\0".getBytes(StandardCharsets.UTF_8);
             transport.sendProtocolHeader(bytes);
-            HeaderResponse response = (HeaderResponse) transport.getNextResponse();
-            assertArrayEquals("Unexpected protocol header response", bytes, response.getHeader());
+            HeaderResponse response = transport.getNextResponse();
+            assertArrayEquals("Unexpected protocol header response", bytes, response.getBody());
         }
     }
 
@@ -70,13 +70,13 @@ public class WebSocketTest extends ProtocolTestBase
         {
             byte[] bytes = "AMQP\0\1\0\0".getBytes(StandardCharsets.UTF_8);
             transport.sendProtocolHeader(bytes);
-            HeaderResponse response = (HeaderResponse) transport.getNextResponse();
-            assertArrayEquals("Unexpected protocol header response", bytes, response.getHeader());
+            HeaderResponse response = transport.getNextResponse();
+            assertArrayEquals("Unexpected protocol header response", bytes, response.getBody());
 
             Open open = new Open();
             open.setContainerId("testContainerId");
             transport.sendPerformative(open, UnsignedShort.valueOf((short) 0));
-            Open responseOpen = transport.getNextPerformativeResponse(Open.class);
+            Open responseOpen = transport.getNextResponseBody(Open.class);
 
             assertThat(responseOpen.getContainerId(), is(notNullValue()));
             assertThat(responseOpen.getMaxFrameSize().longValue(),
@@ -100,7 +100,7 @@ public class WebSocketTest extends ProtocolTestBase
             Open open = new Open();
             open.setContainerId("testContainerId");
             transport.sendPerformative(open, UnsignedShort.valueOf((short) 0));
-            Open responseOpen = transport.getNextPerformativeResponse(Open.class);
+            Open responseOpen = transport.getNextResponseBody(Open.class);
 
             assertThat(responseOpen.getContainerId(), is(notNullValue()));
             assertThat(responseOpen.getMaxFrameSize().longValue(),

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/DeleteOnCloseTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/DeleteOnCloseTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/DeleteOnCloseTest.java
index 44b2b21..a39cd92 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/DeleteOnCloseTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/DeleteOnCloseTest.java
@@ -88,8 +88,8 @@ public class DeleteOnCloseTest extends ProtocolTestBase
 
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-            final Attach attachResponse = (Attach) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Attach.class)));
+            final Attach attachResponse = (Attach) response.getBody();
             assertThat(attachResponse.getSource(), is(notNullValue()));
             final String newTempQueueAddress = ((Source) attachResponse.getSource()).getAddress();
 
@@ -101,7 +101,7 @@ public class DeleteOnCloseTest extends ProtocolTestBase
             transport.sendPerformative(detach);
             PerformativeResponse detachResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(detachResponse, is(notNullValue()));
-            assertThat(detachResponse.getFrameBody(), is(instanceOf(Detach.class)));
+            assertThat(detachResponse.getBody(), is(instanceOf(Detach.class)));
 
             assertThat(Utils.doesNodeExist(_brokerAddress, newTempQueueAddress), is(false));
         }
@@ -134,8 +134,8 @@ public class DeleteOnCloseTest extends ProtocolTestBase
 
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-            final Attach attachResponse = (Attach) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Attach.class)));
+            final Attach attachResponse = (Attach) response.getBody();
             assertThat(attachResponse.getTarget(), is(notNullValue()));
             final String newTempQueueAddress = ((Target) attachResponse.getTarget()).getAddress();
 
@@ -143,7 +143,7 @@ public class DeleteOnCloseTest extends ProtocolTestBase
 
             PerformativeResponse flowResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(flowResponse, is(notNullValue()));
-            assertThat(flowResponse.getFrameBody(), is(instanceOf(Flow.class)));
+            assertThat(flowResponse.getBody(), is(instanceOf(Flow.class)));
 
             Detach detach = new Detach();
             detach.setHandle(attach.getHandle());
@@ -151,7 +151,7 @@ public class DeleteOnCloseTest extends ProtocolTestBase
             transport.sendPerformative(detach);
             PerformativeResponse detachResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(detachResponse, is(notNullValue()));
-            assertThat(detachResponse.getFrameBody(), is(instanceOf(Detach.class)));
+            assertThat(detachResponse.getBody(), is(instanceOf(Detach.class)));
 
             assertThat(Utils.doesNodeExist(_brokerAddress, newTempQueueAddress), is(false));
         }
@@ -184,8 +184,8 @@ public class DeleteOnCloseTest extends ProtocolTestBase
 
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-            final Attach attachResponse = (Attach) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Attach.class)));
+            final Attach attachResponse = (Attach) response.getBody();
             assertThat(attachResponse.getSource(), is(notNullValue()));
             final String newTempQueueAddress = ((Source) attachResponse.getSource()).getAddress();
 
@@ -196,7 +196,7 @@ public class DeleteOnCloseTest extends ProtocolTestBase
             transport.sendPerformative(detach);
             PerformativeResponse detachResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(detachResponse, is(notNullValue()));
-            assertThat(detachResponse.getFrameBody(), is(instanceOf(Detach.class)));
+            assertThat(detachResponse.getBody(), is(instanceOf(Detach.class)));
 
             assertThat(Utils.doesNodeExist(_brokerAddress, newTempQueueAddress), is(true));
         }
@@ -230,8 +230,8 @@ public class DeleteOnCloseTest extends ProtocolTestBase
 
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-            final Attach attachResponse = (Attach) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Attach.class)));
+            final Attach attachResponse = (Attach) response.getBody();
             assertThat(attachResponse.getSource(), is(notNullValue()));
             newTempQueueAddress = ((Source) attachResponse.getSource()).getAddress();
 

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/TransferTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/TransferTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/TransferTest.java
index 8d93002..e1136df 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/TransferTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/messaging/TransferTest.java
@@ -110,8 +110,8 @@ public class TransferTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), equalTo(AmqpError.DECODE_ERROR));
         }
@@ -141,8 +141,8 @@ public class TransferTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), equalTo(AmqpError.INVALID_FIELD));
         }
@@ -172,8 +172,8 @@ public class TransferTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Disposition.class)));
-            Disposition responseDisposition = (Disposition) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Disposition.class)));
+            Disposition responseDisposition = (Disposition) response.getBody();
             assertThat(responseDisposition.getRole(), is(Role.RECEIVER));
             assertThat(responseDisposition.getSettled(), is(Boolean.TRUE));
             assertThat(responseDisposition.getState(), is(instanceOf(Accepted.class)));
@@ -217,8 +217,8 @@ public class TransferTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Disposition.class)));
-            Disposition responseDisposition = (Disposition) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Disposition.class)));
+            Disposition responseDisposition = (Disposition) response.getBody();
             assertThat(responseDisposition.getRole(), is(Role.RECEIVER));
             assertThat(responseDisposition.getSettled(), is(Boolean.TRUE));
             assertThat(responseDisposition.getState(), is(instanceOf(Accepted.class)));
@@ -262,8 +262,8 @@ public class TransferTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Detach.class)));
-            Detach detach = (Detach) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Detach.class)));
+            Detach detach = (Detach) response.getBody();
             Error error = detach.getError();
             assertThat(error, is(notNullValue()));
             assertThat(error.getCondition(), is(equalTo(AmqpError.INVALID_FIELD)));
@@ -321,16 +321,16 @@ public class TransferTest extends ProtocolTestBase
 
             final PerformativeResponse openResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(openResponse, is(notNullValue()));
-            assertThat(openResponse.getFrameBody(), is(instanceOf(Open.class)));
+            assertThat(openResponse.getBody(), is(instanceOf(Open.class)));
             final PerformativeResponse beginResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(beginResponse, is(notNullValue()));
-            assertThat(beginResponse.getFrameBody(), is(instanceOf(Begin.class)));
+            assertThat(beginResponse.getBody(), is(instanceOf(Begin.class)));
             final PerformativeResponse attachResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(attachResponse, is(notNullValue()));
-            assertThat(attachResponse.getFrameBody(), is(instanceOf(Attach.class)));
+            assertThat(attachResponse.getBody(), is(instanceOf(Attach.class)));
             final PerformativeResponse flowResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(flowResponse, is(notNullValue()));
-            assertThat(flowResponse.getFrameBody(), is(instanceOf(Flow.class)));
+            assertThat(flowResponse.getBody(), is(instanceOf(Flow.class)));
 /*
             final PerformativeResponse dispositionResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(dispositionResponse, is(notNullValue()));
@@ -344,7 +344,7 @@ public class TransferTest extends ProtocolTestBase
 */
             final PerformativeResponse closeResponse = (PerformativeResponse) transport.getNextResponse();
             assertThat(closeResponse, is(notNullValue()));
-            assertThat(closeResponse.getFrameBody(), is(instanceOf(Close.class)));
+            assertThat(closeResponse.getBody(), is(instanceOf(Close.class)));
         }
     }
 
@@ -357,7 +357,7 @@ public class TransferTest extends ProtocolTestBase
                           + "detached by the receiver with the same error.")
     public void durableTransferWithRejectedOutcome() throws Exception
     {
-        try (FrameTransport transport = new FrameTransport(_brokerAddress))
+        try (FrameTransport transport = new FrameTransport(_brokerAddress).connect())
         {
             final Attach attach = new Attach();
             attach.setName("testLink");
@@ -390,8 +390,8 @@ public class TransferTest extends ProtocolTestBase
             if (getBrokerAdmin().supportsRestart())
             {
                 assertThat(response, is(notNullValue()));
-                assertThat(response.getFrameBody(), is(instanceOf(Disposition.class)));
-                final Disposition receivedDisposition = (Disposition) response.getFrameBody();
+                assertThat(response.getBody(), is(instanceOf(Disposition.class)));
+                final Disposition receivedDisposition = (Disposition) response.getBody();
                 assertThat(receivedDisposition.getSettled(), is(true));
                 assertThat(receivedDisposition.getState(), is(instanceOf(Outcome.class)));
                 assertThat(((Outcome) receivedDisposition.getState()).getSymbol(), is(Accepted.ACCEPTED_SYMBOL));
@@ -399,8 +399,8 @@ public class TransferTest extends ProtocolTestBase
             else
             {
                 assertThat(response, is(notNullValue()));
-                assertThat(response.getFrameBody(), is(instanceOf(Disposition.class)));
-                final Disposition receivedDisposition = (Disposition) response.getFrameBody();
+                assertThat(response.getBody(), is(instanceOf(Disposition.class)));
+                final Disposition receivedDisposition = (Disposition) response.getBody();
                 assertThat(receivedDisposition.getSettled(), is(true));
                 assertThat(receivedDisposition.getState(), is(instanceOf(Outcome.class)));
                 assertThat(((Outcome) receivedDisposition.getState()).getSymbol(), is(Rejected.REJECTED_SYMBOL));
@@ -417,7 +417,7 @@ public class TransferTest extends ProtocolTestBase
                           + "detached by the receiver with the same error.")
     public void durableTransferWithoutRejectedOutcome() throws Exception
     {
-        try (FrameTransport transport = new FrameTransport(_brokerAddress))
+        try (FrameTransport transport = new FrameTransport(_brokerAddress).connect())
         {
             final Attach attach = new Attach();
             attach.setName("testLink");
@@ -450,8 +450,8 @@ public class TransferTest extends ProtocolTestBase
             if (getBrokerAdmin().supportsRestart())
             {
                 assertThat(response, is(notNullValue()));
-                assertThat(response.getFrameBody(), is(instanceOf(Disposition.class)));
-                final Disposition receivedDisposition = (Disposition) response.getFrameBody();
+                assertThat(response.getBody(), is(instanceOf(Disposition.class)));
+                final Disposition receivedDisposition = (Disposition) response.getBody();
                 assertThat(receivedDisposition.getSettled(), is(true));
                 assertThat(receivedDisposition.getState(), is(instanceOf(Outcome.class)));
                 assertThat(((Outcome) receivedDisposition.getState()).getSymbol(), is(Accepted.ACCEPTED_SYMBOL));
@@ -459,8 +459,8 @@ public class TransferTest extends ProtocolTestBase
             else
             {
                 assertThat(response, is(notNullValue()));
-                assertThat(response.getFrameBody(), is(instanceOf(Detach.class)));
-                final Detach receivedDetach = (Detach) response.getFrameBody();
+                assertThat(response.getBody(), is(instanceOf(Detach.class)));
+                final Detach receivedDetach = (Detach) response.getBody();
                 assertThat(receivedDetach.getError(), is(notNullValue()));
                 assertThat(receivedDetach.getError().getCondition(), is(AmqpError.PRECONDITION_FAILED));
             }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/ProtocolHeaderTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/ProtocolHeaderTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/ProtocolHeaderTest.java
index b68ae8d..91da8a9 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/ProtocolHeaderTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/ProtocolHeaderTest.java
@@ -49,7 +49,7 @@ public class ProtocolHeaderTest extends ProtocolTestBase
             byte[] bytes = "AMQP\0\1\0\0".getBytes(StandardCharsets.UTF_8);
             transport.sendProtocolHeader(bytes);
             HeaderResponse response = (HeaderResponse) transport.getNextResponse();
-            assertArrayEquals("Unexpected protocol header response", bytes, response.getHeader());
+            assertArrayEquals("Unexpected protocol header response", bytes, response.getBody());
         }
     }
 
@@ -68,7 +68,7 @@ public class ProtocolHeaderTest extends ProtocolTestBase
             transport.sendProtocolHeader(rawHeaderBytes);
             HeaderResponse response = (HeaderResponse) transport.getNextResponse();
 
-            assertArrayEquals("Unexpected protocol header response", expectedSaslHeaderBytes, response.getHeader());
+            assertArrayEquals("Unexpected protocol header response", expectedSaslHeaderBytes, response.getBody());
 
             transport.assertNoMoreResponses();
         }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/connection/OpenTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/connection/OpenTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/connection/OpenTest.java
index d3c83b5..2c30034 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/connection/OpenTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/connection/OpenTest.java
@@ -66,8 +66,8 @@ public class OpenTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), equalTo(AmqpError.DECODE_ERROR));
         }
@@ -89,8 +89,8 @@ public class OpenTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
-            Open responseOpen = (Open) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Open.class)));
+            Open responseOpen = (Open) response.getBody();
             assertThat(responseOpen.getContainerId(), is(notNullValue()));
             assertThat(responseOpen.getMaxFrameSize().longValue(),
                        is(both(greaterThanOrEqualTo(0L)).and(lessThan(UnsignedInteger.MAX_VALUE.longValue()))));
@@ -119,8 +119,8 @@ public class OpenTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), equalTo(ConnectionError.FRAMING_ERROR));
         }
@@ -144,8 +144,8 @@ public class OpenTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), equalTo(AmqpError.NOT_FOUND));
         }
@@ -156,8 +156,8 @@ public class OpenTest extends ProtocolTestBase
         PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
         assertThat(response, is(notNullValue()));
-        assertThat(response.getFrameBody(), is(instanceOf(Open.class)));
-        Open responseOpen = (Open) response.getFrameBody();
+        assertThat(response.getBody(), is(instanceOf(Open.class)));
+        Open responseOpen = (Open) response.getBody();
         assertThat(responseOpen.getContainerId(), is(notNullValue()));
     }
 }

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/AttachTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/AttachTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/AttachTest.java
index c5ce03e..d2c54fc 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/AttachTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/AttachTest.java
@@ -62,8 +62,8 @@ public class AttachTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), equalTo(AmqpError.DECODE_ERROR));
         }
@@ -93,8 +93,8 @@ public class AttachTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-            Attach responseAttach = (Attach) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Attach.class)));
+            Attach responseAttach = (Attach) response.getBody();
             assertThat(responseAttach.getName(), is(notNullValue()));
             assertThat(responseAttach.getHandle().longValue(), is(both(greaterThanOrEqualTo(0L)).and(lessThan(UnsignedInteger.MAX_VALUE.longValue()))));
             assertThat(responseAttach.getRole(), is(Role.RECEIVER));
@@ -130,8 +130,8 @@ public class AttachTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Attach.class)));
-            Attach responseAttach = (Attach) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Attach.class)));
+            Attach responseAttach = (Attach) response.getBody();
             assertThat(responseAttach.getName(), is(notNullValue()));
             assertThat(responseAttach.getHandle().longValue(), is(both(greaterThanOrEqualTo(0L)).and(lessThan(UnsignedInteger.MAX_VALUE.longValue()))));
             assertThat(responseAttach.getRole(), is(Role.SENDER));

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/FlowTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/FlowTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/FlowTest.java
index 1071f84..0735a5a 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/FlowTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/link/FlowTest.java
@@ -61,8 +61,8 @@ public class FlowTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Close.class)));
-            Close responseClose = (Close) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Close.class)));
+            Close responseClose = (Close) response.getBody();
             assertThat(responseClose.getError(), is(notNullValue()));
             assertThat(responseClose.getError().getCondition(), is(AmqpError.DECODE_ERROR));
         }
@@ -88,8 +88,8 @@ public class FlowTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Flow.class)));
-            Flow responseFlow = (Flow) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Flow.class)));
+            Flow responseFlow = (Flow) response.getBody();
             assertThat(responseFlow.getEcho(), not(equalTo(Boolean.TRUE)));
             assertThat(responseFlow.getHandle(), is(nullValue()));
         }
@@ -121,8 +121,8 @@ public class FlowTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Flow.class)));
-            Flow responseFlow = (Flow) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Flow.class)));
+            Flow responseFlow = (Flow) response.getBody();
             assertThat(responseFlow.getEcho(), not(equalTo(Boolean.TRUE)));
             assertThat(responseFlow.getHandle(), is(notNullValue()));
         }
@@ -172,8 +172,8 @@ public class FlowTest extends ProtocolTestBase
             PerformativeResponse response = (PerformativeResponse) transport.getNextResponse();
 
             assertThat(response, is(notNullValue()));
-            assertThat(response.getFrameBody(), is(instanceOf(Flow.class)));
-            Flow responseFlow = (Flow) response.getFrameBody();
+            assertThat(response.getBody(), is(instanceOf(Flow.class)));
+            Flow responseFlow = (Flow) response.getBody();
             assertThat(responseFlow.getHandle(), is(notNullValue()));
             assertThat(responseFlow.getLinkCredit(), is(equalTo(UnsignedInteger.ZERO)));
             assertThat(responseFlow.getDrain(), is(equalTo(Boolean.TRUE)));

http://git-wip-us.apache.org/repos/asf/qpid-broker-j/blob/2535b45d/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/security/sasl/SaslTest.java
----------------------------------------------------------------------
diff --git a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/security/sasl/SaslTest.java b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/security/sasl/SaslTest.java
index a84b8e9..150ccf9 100644
--- a/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/security/sasl/SaslTest.java
+++ b/systests/protocol-tests-amqp-1-0/src/test/java/org/apache/qpid/tests/protocol/v1_0/transport/security/sasl/SaslTest.java
@@ -71,9 +71,9 @@ public class SaslTest extends ProtocolTestBase
             transport.sendProtocolHeader(SASL_AMQP_HEADER_BYTES);
             HeaderResponse saslHeaderResponse = transport.getNextResponse(HeaderResponse.class);
 
-            assertThat(saslHeaderResponse.getHeader(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
+            assertThat(saslHeaderResponse.getBody(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
 
-            SaslMechanisms saslMechanismsResponse = transport.getNextPerformativeResponse(SaslMechanisms.class);
+            SaslMechanisms saslMechanismsResponse = transport.getNextResponseBody(SaslMechanisms.class);
             assertThat(Arrays.asList(saslMechanismsResponse.getSaslServerMechanisms()), hasItem(PLAIN));
 
 
@@ -82,12 +82,12 @@ public class SaslTest extends ProtocolTestBase
             saslInit.setInitialResponse(new Binary("\0guest\0guest".getBytes(StandardCharsets.US_ASCII)));
             transport.sendPerformative(saslInit);
 
-            SaslOutcome saslOutcome = transport.getNextPerformativeResponse(SaslOutcome.class);
+            SaslOutcome saslOutcome = transport.getNextResponseBody(SaslOutcome.class);
             assertThat(saslOutcome.getCode(), equalTo(SaslCode.OK));
 
             transport.sendProtocolHeader(AMQP_HEADER_BYTES);
             HeaderResponse headerResponse = transport.getNextResponse(HeaderResponse.class);
-            assertThat(headerResponse.getHeader(), is(equalTo(AMQP_HEADER_BYTES)));
+            assertThat(headerResponse.getBody(), is(equalTo(AMQP_HEADER_BYTES)));
 
             transport.assertNoMoreResponses();
         }
@@ -104,16 +104,16 @@ public class SaslTest extends ProtocolTestBase
             transport.sendProtocolHeader(SASL_AMQP_HEADER_BYTES);
             HeaderResponse saslHeaderResponse = transport.getNextResponse(HeaderResponse.class);
 
-            assertThat(saslHeaderResponse.getHeader(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
+            assertThat(saslHeaderResponse.getBody(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
 
-            SaslMechanisms saslMechanismsResponse = transport.getNextPerformativeResponse(SaslMechanisms.class);
+            SaslMechanisms saslMechanismsResponse = transport.getNextResponseBody(SaslMechanisms.class);
             assertThat(Arrays.asList(saslMechanismsResponse.getSaslServerMechanisms()), hasItem(CRAM_MD5));
 
             SaslInit saslInit = new SaslInit();
             saslInit.setMechanism(CRAM_MD5);
             transport.sendPerformative(saslInit);
 
-            SaslChallenge challenge = transport.getNextPerformativeResponse(SaslChallenge.class);
+            SaslChallenge challenge = transport.getNextResponseBody(SaslChallenge.class);
             assertThat(challenge.getChallenge(), is(notNullValue()));
 
             byte[] response = generateCramMD5ClientResponse("guest", "guest", challenge.getChallenge().getArray());
@@ -122,12 +122,12 @@ public class SaslTest extends ProtocolTestBase
             saslResponse.setResponse(new Binary(response));
             transport.sendPerformative(saslResponse);
 
-            SaslOutcome saslOutcome = transport.getNextPerformativeResponse(SaslOutcome.class);
+            SaslOutcome saslOutcome = transport.getNextResponseBody(SaslOutcome.class);
             assertThat(saslOutcome.getCode(), equalTo(SaslCode.OK));
 
             transport.sendProtocolHeader(AMQP_HEADER_BYTES);
             HeaderResponse headerResponse = transport.getNextResponse(HeaderResponse.class);
-            assertThat(headerResponse.getHeader(), is(equalTo(AMQP_HEADER_BYTES)));
+            assertThat(headerResponse.getBody(), is(equalTo(AMQP_HEADER_BYTES)));
 
             transport.assertNoMoreResponses();
         }
@@ -143,9 +143,9 @@ public class SaslTest extends ProtocolTestBase
             transport.sendProtocolHeader(SASL_AMQP_HEADER_BYTES);
             HeaderResponse saslHeaderResponse = transport.getNextResponse(HeaderResponse.class);
 
-            assertThat(saslHeaderResponse.getHeader(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
+            assertThat(saslHeaderResponse.getBody(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
 
-            SaslMechanisms saslMechanismsResponse = transport.getNextPerformativeResponse(SaslMechanisms.class);
+            SaslMechanisms saslMechanismsResponse = transport.getNextResponseBody(SaslMechanisms.class);
             assertThat(Arrays.asList(saslMechanismsResponse.getSaslServerMechanisms()), hasItem(PLAIN));
 
             SaslInit saslInit = new SaslInit();
@@ -153,7 +153,7 @@ public class SaslTest extends ProtocolTestBase
             saslInit.setInitialResponse(new Binary("\0guest\0badpassword".getBytes(StandardCharsets.US_ASCII)));
             transport.sendPerformative(saslInit);
 
-            SaslOutcome saslOutcome = transport.getNextPerformativeResponse(SaslOutcome.class);
+            SaslOutcome saslOutcome = transport.getNextResponseBody(SaslOutcome.class);
             assertThat(saslOutcome.getCode(), equalTo(SaslCode.AUTH));
 
             transport.assertNoMoreResponsesAndChannelClosed();
@@ -173,15 +173,15 @@ public class SaslTest extends ProtocolTestBase
             transport.sendProtocolHeader(SASL_AMQP_HEADER_BYTES);
             HeaderResponse saslHeaderResponse = transport.getNextResponse(HeaderResponse.class);
 
-            assertThat(saslHeaderResponse.getHeader(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
+            assertThat(saslHeaderResponse.getBody(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
 
-            transport.getNextPerformativeResponse(SaslMechanisms.class);
+            transport.getNextResponseBody(SaslMechanisms.class);
 
             SaslInit saslInit = new SaslInit();
             saslInit.setMechanism(Symbol.getSymbol("NOT-A-MECHANISM"));
             transport.sendPerformative(saslInit);
 
-            SaslOutcome saslOutcome = transport.getNextPerformativeResponse(SaslOutcome.class);
+            SaslOutcome saslOutcome = transport.getNextResponseBody(SaslOutcome.class);
             assertThat(saslOutcome.getCode(), equalTo(SaslCode.AUTH));
             assertThat(saslOutcome.getAdditionalData(), is(nullValue()));
 
@@ -198,9 +198,9 @@ public class SaslTest extends ProtocolTestBase
         {
             transport.sendProtocolHeader(SASL_AMQP_HEADER_BYTES);
             HeaderResponse saslHeaderResponse = transport.getNextResponse(HeaderResponse.class);
-            assertThat(saslHeaderResponse.getHeader(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
+            assertThat(saslHeaderResponse.getBody(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
 
-            transport.getNextPerformativeResponse(SaslMechanisms.class);
+            transport.getNextResponseBody(SaslMechanisms.class);
 
             Open open = new Open();
             open.setContainerId("testContainerId");
@@ -221,9 +221,9 @@ public class SaslTest extends ProtocolTestBase
         {
             transport.sendProtocolHeader(SASL_AMQP_HEADER_BYTES);
             HeaderResponse saslHeaderResponse = transport.getNextResponse(HeaderResponse.class);
-            assertThat(saslHeaderResponse.getHeader(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
+            assertThat(saslHeaderResponse.getBody(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
 
-            transport.getNextPerformativeResponse(SaslMechanisms.class);
+            transport.getNextResponseBody(SaslMechanisms.class);
 
             SaslMechanisms clientMechs = new SaslMechanisms();
             clientMechs.setSaslServerMechanisms(new Symbol[] {Symbol.valueOf("CLIENT-MECH")});
@@ -242,9 +242,9 @@ public class SaslTest extends ProtocolTestBase
         {
             transport.sendProtocolHeader(SASL_AMQP_HEADER_BYTES);
             HeaderResponse saslHeaderResponse = transport.getNextResponse(HeaderResponse.class);
-            assertThat(saslHeaderResponse.getHeader(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
+            assertThat(saslHeaderResponse.getBody(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
 
-            transport.getNextPerformativeResponse(SaslMechanisms.class);
+            transport.getNextResponseBody(SaslMechanisms.class);
 
             SaslChallenge saslChallenge = new SaslChallenge();
             saslChallenge.setChallenge(new Binary(new byte[] {}));
@@ -263,9 +263,9 @@ public class SaslTest extends ProtocolTestBase
         {
             transport.sendProtocolHeader(SASL_AMQP_HEADER_BYTES);
             HeaderResponse saslHeaderResponse = transport.getNextResponse(HeaderResponse.class);
-            assertThat(saslHeaderResponse.getHeader(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
+            assertThat(saslHeaderResponse.getBody(), is(equalTo(SASL_AMQP_HEADER_BYTES)));
 
-            transport.getNextPerformativeResponse(SaslMechanisms.class);
+            transport.getNextResponseBody(SaslMechanisms.class);
 
             SaslOutcome saslOutcome = new SaslOutcome();
             saslOutcome.setCode(SaslCode.OK);


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]