mysql control and rabbitmq using model