Modify mq-related codes