protobuf-go/reflect
Joe Tsai 73618879f4 reflect/protoregistry: protect global registries with a lock
The global registry is initialized via generated code.
The Go language guarantees that these are serialized (non concurrently).
The main concern is when a concurrent read operation occurs while
registration is still ongoing. In such a case, we do need a lock to
serialize the read with regard to the writes (i.e. registrations).

Change-Id: Ied35d6f8d2620f448cb281c3ec46d8de893b5671
Reviewed-on: https://go-review.googlesource.com/c/protobuf/+/199217
Reviewed-by: Damien Neil <dneil@google.com>
2019-10-06 03:28:52 +00:00
..
protodesc all: use typed variant of protoreflect.ValueOf 2019-09-17 21:33:16 +00:00
protoreflect reflect/protoreflect: emit valid Go from GoString 2019-09-05 21:59:19 +00:00
protoregistry reflect/protoregistry: protect global registries with a lock 2019-10-06 03:28:52 +00:00