@Test
    public void testXIO() throws IOException
    {

        InnerMessage inner = new InnerMessage();
        inner.inner1 = "inner".getBytes();
        inner.inner2 = 12.34;

        ExampleMessage message = new ExampleMessage();
        message.field1 = 42;
        message.field2 = "hello";
        message.field3 = Arrays.asList(true, false, true);
        message.field4 = inner;

        byte[] xdata = MsgpackXIOUtil.toByteArray(message, SCHEMA, false, LinkedBuffer.allocate());
        byte[] data = MsgpackIOUtil.toByteArray(message, SCHEMA, false);

        // System.out.println(Arrays.toString(xdata));
        // System.out.println(Arrays.toString(data));

        Assert.assertTrue(Arrays.equals(data, xdata));
    }
Compatible with

http://kawanet.github.io/msgpack-lite/
protostuff-msgpack/src/test/java/io/protostuff/MsgpackSimpleTest.java