=rem #16428 optimize protobuf serializer for master

#16428 for master
This is not safe, if there are concurrent updates we'll lose cached entries.