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 REQ] Provide a easy way to use Azure Schema Registry in Spring Cloud Azure #41041

Open
2 tasks done
rujche opened this issue Jul 8, 2024 · 2 comments
Open
2 tasks done
Assignees
Labels
azure-spring All azure-spring related issues azure-spring-eventhubs Spring event hubs related issues. azure-spring-servicebus Spring service bus related issues. Client This issue points to a problem in the data-plane of the library.

Comments

@rujche
Copy link
Member

rujche commented Jul 8, 2024

Is your feature request related to a problem? Please describe.
In this sample: Use Azure Schema Registry in Spring Boot Application, Using Azure Schema Registry only need to configure a Kafka Serializer or Kafka Deserializer. But when customer use Event Hub or Service Bus without Kafka protocal, it's not easy to use Azure Schema Registry.

Describe the solution you'd like
Provide a feature to help customer easily use Azure Schema Registry with Event Hub or Service Bus without using Kafka protocal.

Describe alternatives you've considered
If use sdk, customer can do serialize and deserizlize by themself. Example code:

List<EventData> serializedCards = playingCards.stream()
.map(card -> {
return serializer.serialize(card, TypeReference.createInstance(EventData.class));
})
.collect(Collectors.toList());
// Publish the events
producerClient.send(serializedCards, sendOptions);

But for Spring Cloud Azure users, it's not easy to achieve this.

Additional context
In above sample, the schema validation is done in kafka client. Here is a screenshot about using serializer:
image

But in this repository, schema validation can NOT be done in sdk level, because the sdk level not have information of schema, you can refer to related code to confirm that. But it can be done in Spring Cloud Azure level.

In Spring Cloud Azure, every place use sdk to send/receive message using Event Hub or Service Bus can be a candidate to enhance. Here is a sample analyze of service bus:

graph
    ServiceBusTemplate:::task --> ServiceBusSenderAsyncClient:::sdk
    ServiceBusListener --> ServiceBusListenerAnnotationBeanPostProcessor
    ServiceBusListenerAnnotationBeanPostProcessor --> AzureListenerAnnotationBeanPostProcessorAdapter
    AzureListenerAnnotationBeanPostProcessorAdapter --> AzureListenerEndpointRegistrar
    AzureListenerEndpointRegistrar --> AzureListenerEndpointRegistry
    AzureListenerEndpointRegistry --> ServiceBusMessageListenerContainerFactory
    ServiceBusMessageListenerContainerFactory --> ServiceBusMessageListenerContainer
    ServiceBusMessageListenerContainer --> ServiceBusProcessorFactory
    ServiceBusProcessorFactory --> ServiceBusProcessorClient:::sdk
    ServiceBusMessageListenerContainer:::task --> ServiceBusProcessorClient:::sdk
    ServiceBusProcessorClientLifecycleManager --> ServiceBusProcessorClient:::sdk
    AzureServiceBusProcessorClientConfiguration --> ServiceBusProcessorClient:::sdk
    DefaultServiceBusNamespaceProcessorFactory --> ServiceBusProcessorClient:::sdk
    
classDef sdk fill:red
classDef task fill:green
Loading

Items with green background color is a potential enhance point.
Need more investigation and analyzation before implement this function.

Information Checklist
Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report

  • Description Added
  • Expected solution specified
@rujche rujche added azure-spring All azure-spring related issues azure-spring-servicebus Spring service bus related issues. labels Jul 8, 2024
@rujche rujche added the azure-spring-eventhubs Spring event hubs related issues. label Jul 8, 2024
@github-actions github-actions bot added Client This issue points to a problem in the data-plane of the library. needs-team-attention This issue needs attention from Azure service team or SDK team Service Bus labels Jul 8, 2024
Copy link

github-actions bot commented Jul 8, 2024

@anuchandy @conniey @lmolkova

Copy link

github-actions bot commented Jul 8, 2024

Thank you for your feedback. Tagging and routing to the team member best able to assist.

@rujche rujche assigned rujche and unassigned lmolkova Jul 8, 2024
@rujche rujche removed Service Bus needs-team-attention This issue needs attention from Azure service team or SDK team labels Jul 8, 2024
@rujche rujche changed the title [FEATURE REQ] Support Azure Schema Registry in Spring related function [FEATURE REQ] Provide a easy way to use Azure Schema Registry when customer use Spring Cloud Azure Jul 8, 2024
@rujche rujche changed the title [FEATURE REQ] Provide a easy way to use Azure Schema Registry when customer use Spring Cloud Azure [FEATURE REQ] Provide a easy way to use Azure Schema Registry in Spring Cloud Azure Jul 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
azure-spring All azure-spring related issues azure-spring-eventhubs Spring event hubs related issues. azure-spring-servicebus Spring service bus related issues. Client This issue points to a problem in the data-plane of the library.
Projects
Status: Todo
Development

No branches or pull requests

2 participants