Skip to content

Latest commit

 

History

History
41 lines (30 loc) · 2.58 KB

Readme.md

File metadata and controls

41 lines (30 loc) · 2.58 KB

This Spring Boot 3.2 project integrates with Azure Cloud services for notification and event handling. It utilizes Azure Cloud PubSub service for notification delivery and Azure Event Hubs service for messaging purposes acting as a queue.

Features:

  1. Notification System with Azure Cloud PubSub:

    • Sends notifications to users when connected.
    • Stores notifications in the database for offline users, sends them upon next user connection.
  2. Event Handling with Azure Event Hubs:

    • Listens for events from Azure Event Hubs acting as a queue.
    • Sends notifications to users based on received events.

Configuration:

  • Azure Cloud PubSub:

    • Configure Azure Cloud PubSub service in the Azure portal.
    • Set up necessary access policies and roles for local development environment.
    • Use tunneling to connect the local development environment to the PubSub instance in the cloud.
    • Users register to receive notifications. Upon connection, a WebSocket channel is opened, enabling real-time notification delivery from the backend. Notifications are sent to connected users instantly, while offline users' notifications are stored and delivered upon reconnection.
    • The WebSocket channel acts as a webhook-like mechanism, allowing the backend to push notifications to the user in real-time.
  • Azure Event Hubs:

    • Configure Azure Event Hubs service in the Azure portal.
    • Set up access policies and roles for local development environment.

Importance of Using a Queue:

In this scenario, utilizing a queue (Azure Event Hubs) is crucial for several reasons:

  • Reliability: A queue ensures reliable message delivery, even if the recipient is temporarily unavailable.
  • Scalability: Azure Event Hubs scales automatically to handle high message throughput, ensuring that notifications are processed efficiently.
  • Asynchronous Processing: By decoupling the sender and receiver, the system can operate asynchronously, improving overall system responsiveness and scalability.
  • Fault Tolerance: Queues provide fault tolerance, ensuring that messages are not lost in case of system failures.

Prerequisites:

  • Valid Azure Cloud account.
  • Basic understanding of Azure Cloud services.
  • Familiarity with Spring Boot 3.2 and Java 17 programming.
  • Access to the Azure portal for configuring resource groups, instances, and role-based access management for local development environment.

This project provides a robust notification and event handling system using Azure Cloud services, ensuring efficient delivery and processing of notifications in a scalable and reliable manner.