How kristjan-jonsson/topicpubsubpoc works
This is a small .NET proof of concept for IBM MQ topic publish/subscribe. The principal workflow is to load MQ settings, select publisher or subscriber mode, then publish JSON messages to a configured topic or listen for messages on that topic; the README also describes hierarchical topic strings. The sampled source shows the entry point, configuration loader, publisher, consumer, and message model. The MQ service is external. The appsettings relationship is documented, while runtime behavior beyond the sampled files is not inferred.
Main entry points: Program.cs Mode dispatcher · SimplePublisher.cs Topic publisher · MQConfig.cs Config loader · SimpleConsumer.cs Topic subscriber
Components 8
Application runtime
- Mode dispatcher
Program.cs - MQ settings
appsettings.json - Config loader
MQConfig.cs
Message handling
- Topic publisher
SimplePublisher.cs - Topic subscriber
SimpleConsumer.cs - JSON message
jsonMessage.cs
IBM MQ
- MQ topic service
Other components
- Operator
Connections 9
- Operator → Mode dispatcher: selects mode
README.md - MQ settings → Config loader: provides settings
README.md - Mode dispatcher → Config loader: loads settings
Program.cs - Config loader → Mode dispatcher: returns config
Program.cs - Mode dispatcher → Topic publisher: dispatches publish
Program.cs - Mode dispatcher → Topic subscriber: dispatches subscribe
Program.cs - Topic publisher → JSON message: serializes message
SimplePublisher.cs - Topic publisher → MQ topic service: publishes topic
SimplePublisher.cs - Topic subscriber → MQ topic service: subscribes and receives
SimpleConsumer.cs