Skip to content

Feat connection module

To use in your code:

# first import the class
from usrreg_mq import UserRegMQ

# Initial with Exchange name:
userreg_mq = UserRegMQ({ 'exchange': 'RegUsr' })

# specify routing key and the message(JSON format)
userreg_mq.publish_msg({
        'routing_key': 'ohpc',
        'msg': {
                "username": 'user_name',
                "fullname": "Full Name",
                "reason": "Reason1, Reason2."
        }
})

Merge request reports