@Override
    public void writeBytes(int fieldNumber, ByteString value, boolean repeated) throws IOException
    {
        writeByteArray(fieldNumber, value.getBytes(), repeated);
    }
Before serializing a message/object tied to a schema, this should be called.
protostuff-yaml/src/main/java/io/protostuff/YamlOutput.java