google.protobuf.Duration unmarshal: add support for other suffixes ("ns", "us", "ms", "m", "h")

122 views
Skip to first unread message

Alex Efros

unread,
Mar 25, 2021, 8:48:18 PM3/25/21
to Protocol Buffers
Hi!

Unmarshaling (e.g. from JSON) into google.protobuf.Duration currently accept only a string with float seconds with "s" suffix.
I think it would be useful to support same values as time.ParseDuration.

WBR, Alex.
Reply all
Reply to author
Forward
0 new messages