title: How to merge a serialized protobuf with a another protobuf without deserializing the first
body: <p>I'm trying to understand if it's possible to take a serialized protobuf that makes up part of another protobuf and merge them together without having to deserialize the first protobuf. </p>
  
  <p>For example, given a protobuf wrapper: </p>
  
  <pre><code>syntax = "proto2";
  
  import "content.proto";
  
  message WrapperContent {
  
   required string metatData = 1;
   required Content content = 2;
  
  }
  </code></pre>
  
  <p>And then imagine we get a serialized version of <strong><em>Content</em></strong> below (i.e. <strong><em>Content</em></strong> is coming that is coming from a remote client):</p>
  
  <pre><code>syntax = "proto2";
  
  message Content {
  
   required string name = 1;
   required bytes payload = 2;
  
  }
  </code></pre>
  
  <p>Do you know if any way I can inject the serialized <strong><em>Content</em></strong> into the <strong><em>WrapperContent</em></strong> without first having to deserialize <strong><em>Content</em></strong>. </p>
  
  <p>The reason I'm trying to inject <strong><em>Content</em></strong> without deserializing it, is that I'm try and save on the overhead of deserializing the message. </p>
  
  <p>If that answer is, no, it's not possible. That is still helpful. </p>
  
  <p>Thanks, Mike.</p>