public void DirectSendMsg() { var send_msg = new NewOrderMessage { CreatedTime = DateTime.Now, OrderNum = "111111", PayType = 1, Price = 100M, ProductCode = 1, Source = Guid.NewGuid().ToString() }; ///direct模式 rabbitMQProducer.DirectSend(send_msg); }