- Queue
- Message
- Publisher
- Subscriber
- Server
- MessageStore
- QueueManager
- QueueHandler
- MessageBroker
- RecieverService
- PublisherHandler
- SenderService
- SubscriberManager
- SubscriberHandler
- Logging
- HttpServerMux
- Monitoring
- Security
- Exception Handling
- Utils
- Config Management
- Dependency Management
- publisher client.
- subscriber application.
-
MessageStore
- GetMessage()
- SetMessage()
- DeleteMessage()
-
QueueManager
- CreateQueue()
- GetQueue()
-
QueueHandler
- QueueManager
- CreateQueueApi()
-
MessageBroker
- SetMessage()
- GetMessage()
- DeleteMessage()
- CallSubscribers()
-
RecieverService
- QueueManager
- MessageBroker
- EnqueueMessage()
-
PublisherHandler
- RecieverService
- PublishMessageApi()
-
SubscriberManager
- RegisterSubscriber()
- GetQueueSubscribers()
-
SenderService
- QueueManager
- MessageBroker
- GetMessage()
-
SubscriberHandler
- SenderService
- RegisterSubscriberApi()
- PollMessageApi()
- CreateQueue
- RegisterSubscriber
- PublishMessage
- PollMessage
-[x] CreateQueue 1. User calls QueueHandler.CreateQueueApi(). 2. It calls QueueManager.CreateQueue() to creates a queue 3. CreateQueue checks if the queue already existed ? 1. IF yes then raise Exception 2. Else return success. 4. Pass the result to handler to create response.
-[x] RegisterSubscriber
- User calls SubscriberHandler.RegisterSubscriberApi().
- It calls the subscriberManager.RegisterSubscriber().
- It checks if the Queue exists using QueueManager?
- IF yes then continue
- Else raise exception and return.
- It checks if the subsciber is already registered for that queue using SubscriberManager?
- If yes then raise exception and return
- Else add subsciber in it and return success.
-[x] PublishMessage
- User publish message using curl/http api on PublisherHandler.PublishMessageApi().
- It calls the RecieverService.EnqueueMessage().
- It validates the message queue using QueueManager?
- IF Queue exists then continue
- Else raise exception and return.
- It calls MessageBroker.SetMessage() and return success OR exception.
- If the publish is successful then it raises an async operation on the MessageBroker.CallSubscribers()
-[x] PollMessage
- Subscriber calls SubscriberHandler.PollMessageApi().
- It calls then SenderService.GetMessage()
- It checks the queue is valid.
- IF yes continue,
- Else raise exception and return
- It checks the subscriber is registered for that queue or not ?
- If yes then continue
- Else raise exception and return
- It calls MessageBroker.GetMessage() to get the messages