output.write(os.getRawBuffer(), 0, os.size());
}
private ExposedByteArrayOutputStream marshallParameters(
CacheRpcCommand cmd, StreamingMarshaller marshaller) throws IOException {
BufferSizePredictor sizePredictor = BufferSizePredictorFactory.getBufferSizePredictor();
int estimatedSize = sizePredictor.nextSize(cmd);
ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(estimatedSize);
ObjectOutput output = marshaller.startObjectOutput(baos, true, estimatedSize);
try {
commandExt.writeCommandParameters(output, cmd);
} finally {