private static DocapiFeed.DocumentUpdate toProtoUpdate(DocumentUpdate update) {
        // TODO also consider DocumentUpdate serialization directly to OutputStream to avoid unneeded copying
        return DocapiFeed.DocumentUpdate.newBuilder()
                .setPayload(ByteString.copyFrom(serializeUpdate(update)))
                .build();
    }
Implementation of MessageBus message request/response serialization built around Protocol Buffers.
documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutableFactories80.java