-
Notifications
You must be signed in to change notification settings - Fork 811
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support preservation of unknown fields for proto3 #275
Comments
I was just following golang/protobuf and the proto3 spec. gogoprotobuf has an option goproto_unrecognized to turn this generation off in proto2. |
I am closing this, but just comment if you would like it reopened. |
There is still discussion on this upstream. This is a wider "protobuf" issue more than a language issue. |
Technically we could support this with |
@awalterschulze They made some upstream changes regarding this but I am not sure what the path forward here is. |
@stevvooe |
@awalterschulze I gave it a shot and the generated code looks okay. I did get the following error when building:
Looks like a definition is missing from the gogo/protobuf/proto package. I have the changes in a branch in https://github.com/stevvooe/containerd/tree/try-gogo-upstream. |
I will look into this.
I also started merging upstream into dev and more commits from golang dev
into gogo dev, to mimic golang protobuf.
…On Sat, 7 Apr 2018, 00:01 Stephen Day, ***@***.***> wrote:
@awalterschulze <https://github.com/awalterschulze> I gave it a shot and
the generated code looks okay.
I did get the following error when building:
~/g/s/g/c/containerd ❯❯❯ make ⏎ master ✭ ✚ ◼
🇩 bin/ctr
github.com/containerd/containerd/vendor/k8s.io/apimachinery/pkg/api/resource
vendor/k8s.io/apimachinery/pkg/api/resource/quantity_proto.go:26:7:
undefined: proto.Sizer
Makefile:168: recipe for target 'bin/ctr' failed
make: *** [bin/ctr] Error 2
Looks like a definition is missing from the gogo/protobuf/proto package.
I have the changes in a branch in
https://github.com/stevvooe/containerd/tree/try-gogo-upstream.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#275 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ABvsLexaOswaO3CxLe5kfyG5utDfixriks5tl-WggaJpZM4Mc9WN>
.
|
I found it. Here it seems to have been deleted |
The Also I wanted to know whether you had any problems with the |
In protobuf 2, fields unknown to a particular schema were generally passed through under Read-Modify-Write or passthrough conditions. This allowed use cases that supported uncoordinated upgrade paths where older intermediates could operate with knowing about updated schemas. This feature was silently dropped in proto3 and I am not sure it was ever supported in gogo.
Likely, gogo protobuf support can be controlled by enabling a plugin or option. This determination is dependent on the design details of the upstream protobuf project.
Please see protocolbuffers/protobuf#272 for details. The maintainers have also released a document describing the plan.
There may be nothing to do in this project at this time. Please let me know if this has already been visited.
The text was updated successfully, but these errors were encountered: