title: How to get and parse a serialized string using protobuf in java?
body: <p>There is a client which serialize some values using protobuf. This client is programmed by python. I send the serialization result to a java code using socket:</p>
  
  <pre><code>serializedRow = t_event.SerializeToString()
  sock.send(serializedRow)
  </code></pre>
  
  <p>In java code the message is received as string, but at the step of "ParseFrom" function, there is some ambiguous Errors. As the argument of ParseFrom is Bytes, before passing the string, it is converted to Bytes.</p>
  
  <pre><code>byte[] bytes = row.getBytes();
  TaxiEvent taxiEvent1 = TaxiEvent.ParseFrom(bytes);
  int sec = taxiEvent1.getTripTimeInSecs();
  </code></pre>
  
  <p>The java code is running in context of Apache Flink, as a result the Error message is very long and not clear. but when I omit the parsefrom line, no error occurs and obviously by omitting this line the received data couldn't be used.</p>
  
  <p>The version of protobuf is 3.5.0.  </p>