-
Enhancement
-
Resolution: Obsolete
-
Major
-
11.0.0.Final
-
None
Currently it's necessary for users to automatically add SerializationContextIntializer instances to the client via addContextInitializers and for .proto files to be registered like so:
Path proto = Paths.get(Query.class.getClassLoader().getResource("proto/sheep.proto").toURI()); cacheManager.getCache(ProtobufMetadataManagerConstants.PROTOBUF_METADATA_CACHE_NAME).put("sheep.proto", Files.readString(proto));
Instead we should allow users to configure the client so that:
- SerializationContextInitalizer services are automatically registerd if builder.autoAddAllContextInitializers() is configured.
- *.proto files on the classpath and in available SerializationContextInitializers are automatically registered with the server if .autoRegisterSchemas() is configured.
ProtoStreams AutoProtoSchemaBuilder already provides a `service` attribute to generate the service files for SerializationContextInitiailizer, however this is false by default. We should update this to true so that users have one less knob to confgure.
NOTE: autoRegisterSchemas() will fail if authorization is enabled and the client does not have the ___schema_manager role.
- relates to
-
ISPN-10998 Client should automatically register .proto schemas with the server
- Closed