Updating Firestore documents in Golang using structs (or protobuf messages) as data
问题 Given the following API: syntax = "proto3"; service FooService { rpc UpdateFoo(UpdateFooRequest) returns (Foo) {} } message Foo { string name = 1; string description = 2; string action = 3; } message UpdateFooRequest { Foo foo = 1; // The list of fields to be updated. For the `FieldMask` definition, // see https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask google.protobuf.FieldMask update_mask = 2; } This API talks to a backend Firestore "foos" collection.