Questions tagged [protocol-buffers]

For questions about Google's protocol buffers

Protocol buffers are Google's language-neutral, platform-neutral, extensible mechanism for serializing structured data – think XML, but smaller, faster, and simpler. You define how you want your data to be structured once, then you can use special generated source code to easily write and read your structured data to and from a variety of data streams and using a variety of languages.

https://developers.google.com/protocol-buffers

7638 questions
3
votes
1 answer

Protobuf-net in WP7 throws FieldAccessExceptions

I have a very simple class that I'm trying to serialize: [ProtoContract] public class SettingStore { public event EventHandler ContentsChanged; [ProtoMember(1)] private Dictionary _StringVals = new…
tempy
  • 1,567
  • 2
  • 18
  • 28
3
votes
1 answer

Error: ENOENT: no such file or directory, open 'src/protos/user.proto'?

I'm creating a node.js gRPC service. I'm using the photo buff as an npm package in this service. so the proto buff package is structured as below. and I have published this package to the GitHub npm package registry. then I used it in my…
Sathya Molagoda
  • 531
  • 1
  • 6
  • 17
3
votes
1 answer

How to use Value in the python implementation of protobuf

I have a proto file defined as: syntax = "proto3"; import "google/protobuf/struct.proto"; package generic.name; message Message { uint32 increment = 1; google.protobuf.Value payload = 2; } I have figured out how to make this work if I swap…
3
votes
1 answer

Why protobuf CopyFrom() & MergeFrom() work for every message type?

Seeing a weird issue in my protobuf setup with all the compilers (g++/Linux, clang/Mac, msvc/Windows). Here is its minimal form: message A { // declare objA int32 i; } message B { // declare objB string s; repeated bytes…
iammilind
  • 68,093
  • 33
  • 169
  • 336
3
votes
1 answer

Why use a schema registry

I just started working with Kafka and I use Protocol Buffers for the message format and I just learn about schema registry. To give some context we are a small team with a dozen of webservices and we use Kafka to communicate between them and we…
3
votes
1 answer

importing proto from different files

I maintain all my proto files in one folder. An overview: protos | |__auth | |__some_other Inside auth directory I have auth_service.proto user.proto etc. But I am having issues with importing definitions form user.proto In…
Arnob
  • 195
  • 3
  • 14
3
votes
2 answers

Customize mapstruct to ignore protobuff fields

Since I've noticed that MapStruct was updated to interact with Protobuff and its builder, I thought about migrating our services to fully use MapStruct. However we're still writing manual conversions to protobuff messages because it's rather clumsy…
Kalec
  • 2,681
  • 9
  • 30
  • 49
3
votes
2 answers

can protocol buffer be used without gRPC?

Hello everyone I am getting my hands dirty with gRPC and protocol buffers and have came across an article which has mentioned that the binary protobuf file for a message is 5 times smaller than Json counterpart but in that article it is mentioned…
JayD
  • 748
  • 1
  • 13
  • 38
3
votes
1 answer

Protocol-buffer with Python choose the order of data with SerializeToString

I have buffer that encoded with protocol-buffer , I want to read the buffer and change some data and encode it again. I saw that when I encode the buffer ( SerializeToString) the binary data is not the same so the server that get that buffer can't…
3
votes
1 answer

How do I configure VS Code and Gradle to use generated Java code with the Gradle Protobuf plugin?

I'm trying to use Protobuf with Google's official Gradle plugin, with Gradle, in VS Code, in a small Java application to test out the workflow. I can't get VS Code to recognize the generated Java source code, and in the terminal, I can't get Gradle…
Matt Welke
  • 1,441
  • 1
  • 15
  • 40
3
votes
0 answers

Get predictions from Tensorflow Serve SavedModel

I have a SavedModel that I've managed to load. With the command saved_model_cli show --dir --all I get the following output: MetaGraphDef with tag-set: 'serve' contains the following SignatureDefs: signature_def['serving_default']: …
Iordan Iordanov
  • 253
  • 1
  • 3
  • 13
3
votes
0 answers

A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0 in tid 26201 (mediapipe_gl_ru), pid 26095 (apps.faceeffect)

This is the two related method: absl::Status Open(CalculatorContext* cc) override { ... return gpu_helper_.RunInGlContext([&]() -> absl::Status { const auto& options =…
di wing
  • 91
  • 5
3
votes
1 answer

package to encapsulate float64 in protobuf

I was working in a microservice to create subscriptions in Stripe. One of the fields is listed as a float64 where I set it up as a float in the .proto file. This cast the field as a float32 not float64. I cannot see a direct way to make protobuf to…
Juanjo
  • 670
  • 7
  • 17
3
votes
2 answers

Recursive data structure unmarshalling gives error "cannot parse invalid wire-format data" in Go Lang Protobuf

OS and protobuf version go1.18.1 linux/amd64, github.com/golang/protobuf v1.5.2 Introduction I am trying to use recursive proto definitions. .proto file message AsyncConsensus { int32 sender = 1; int32 receiver = 2; string unique_id = 3; // to…
Pasindu Tennage
  • 1,480
  • 3
  • 14
  • 31
3
votes
0 answers

Difference between Arena::CreateMessage and Arena::CreateMaybeMessage

When I using Protocol Buffer with Arena, what is the difference between those 2 functions google::protobuf::Arena::CreateMaybeMessage(); And google::protobuf::Arena::CreateMessage();
Polo1990
  • 89
  • 3
1 2 3
99
100