Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Added Qualified and Custom reference name strategy approaches for protobuf references (Schema Registry) #2345

Merged
merged 4 commits into from
Nov 14, 2024

Conversation

RobotechUSA
Copy link
Contributor

Description

This feature allows producers to specify configuration for ReferenceSubjectNameStrategy the following enumeration values:

  • ReferenceName -> (default): Use the reference name as the subject name.
  • Qualified -> Given a reference name, replace slashes with dots, and remove the .proto suffix to obtain the subject name. For example, mypackage/myfile.proto becomes mypackage.myfile. (This provides feature parity with java client)
  • Custom -> Use a custom reference subject name strategy resolver to determine the subject name. This is done by implementing ICustomReferenceSubjectNameStrategy and assigning instance to ProtobufSerializerConfig property CustomReferenceSubjectNameStrategy

Background

An internal team is using java has implemented their Schema Registry with QualifiedReferenceSubjectNameStrategy. As a dotnet team we need to interoperate with that work. Unfortunately, we cannot without this proposed change (We require feature parity with java). Further, we are not allowed to auto register schemas.

Other Information

…ature parity with java version.

Added ability to use any custom ReferenceSubjectNameStrategy by implementing ICustomReferenceSubjectNameStrategy and assigning implemented instance to ProtobufSerializerConfig property CustomReferenceSubjectNameStrategy (Note: ReferenceSubjectNameStrategy enumeration value must be set to Custom)
Code for ProtobufSerializer was reformatted
…ature parity with java version.

Added ability to use any custom ReferenceSubjectNameStrategy by implementing ICustomReferenceSubjectNameStrategy and assigning implemented instance to ProtobufSerializerConfig property CustomReferenceSubjectNameStrategy (Note: ReferenceSubjectNameStrategy enumeration value must be set to Custom)
Code for ProtobufSerializer was reformatted
@RobotechUSA RobotechUSA requested review from a team as code owners November 12, 2024 22:59
@confluent-cla-assistant
Copy link

confluent-cla-assistant bot commented Nov 12, 2024

🎉 All Contributor License Agreements have been signed. Ready to merge.
✅ RobotechUSA
Please push an empty commit if you would like to re-run the checks to verify CLA status for all contributors.

@rayokota
Copy link
Member

@RobotechUSA , can you rebase to master?

@rayokota
Copy link
Member

/sem-approve

@rayokota
Copy link
Member

/sem-approve

Copy link
Member

@rayokota rayokota left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @RobotechUSA , LGTM

@rayokota rayokota merged commit 74da56d into confluentinc:master Nov 14, 2024
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants