private void writeMetaDataPadding() {
        // Pad out the stream with zero value byte[], so we can write the typeId and hash
        // in later when they are known
        final byte[] paddingBytes = new byte[META_LENGTH];
        try {
            pooledByteBufferOutputStream.write(paddingBytes);
        } catch (IOException e) {
            throw new RuntimeException(LogUtil.message("Error padding out pooledByteBufferOutputStream: {}",
                    e.getMessage()), e);
        }
    }
<pre>{@code
<type ID int><hash code long><value bytes................>
}</pre>
<p>
Allows us to build a {@link ByteBuffer} backed value from a stream of data and at the end
insert the type information and a hash of the value into the buffer. {@link PooledByteBufferOutputStream}
is used to expand to accommodate any size of data.
stroom-pipeline/src/main/java/stroom/pipeline/refdata/store/StagingValueOutputStream.java