You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-dev@hadoop.apache.org by Jason Wen <zh...@workday.com.INVALID> on 2022/08/09 15:51:12 UTC

Protobuf-java compatibilty question

Hi team,

Hadooop 3.2.x release is using protobuf-java 2.5.0 version lib. It looks like protobuf-java 3.x is binary backward compatible with 2.5.0 version. Does that mean Hadoop 3.2.x can work correctly if we replace protobuf-java 2.5.0 lib with 3.x version at runtime?

Thanks,
Jason

Re: Protobuf-java compatibilty question

Posted by Steve Loughran <st...@cloudera.com.INVALID>.
I'm afraid not. protobuf maybe compatible at the wire level -the marshalled
data is good-, but the generated classes in jars Will not link to any
version other than that they were explicitly compiled with.
this is why hadoop 3.3 has a private shaded copy in the hadoop-thirdparty
JAR -how to stop the Hadoop/hdfs code restricting what others can use.

On Tue, 9 Aug 2022 at 16:51, Jason Wen <zh...@workday.com.invalid>
wrote:

> Hi team,
>
> Hadooop 3.2.x release is using protobuf-java 2.5.0 version lib. It looks
> like protobuf-java 3.x is binary backward compatible with 2.5.0 version.
> Does that mean Hadoop 3.2.x can work correctly if we replace protobuf-java
> 2.5.0 lib with 3.x version at runtime?
>
> Thanks,
> Jason
>