Sorry for the delay, does the answer in
https://stackoverflow.com/questions/61597798/how-to-pass-hash-object-in-grpc-ruby-client
work
for you?
On Friday, May 8, 2020 at 1:23:09 AM UTC-7 Anjali Jaiswal wrote:
> I want to make a Ruby client. In my service_pb.rb file I have:
>
> ```
>
> add_message 'request' do
> ...
> optional :test, :message, 12, 'google.protobuf.Struct'
> end```
>
>
> Now I am trying to pass the request params in my client.rb:
>
>
> ```
>
> params = {xyz: "abc", test: { bar: "296" }}
>
>
> stub = Message::Stub.new('localhost:9999', :this_channel_is_insecure)
>
>
> msg = Request.new(params)
>
> ```
>
>
> while running this I am getting: ArgumentError: Unknown field name 'bar'
> in initialization map entry.
>
>
> I need to pass a Hash object in request params.
>
--
You received this message because you are subscribed to the Google Groups
"grpc.io" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/grpc-io/8b4a9181-8961-42fe-bca2-66ac32c97b40n%40googlegroups.com.