xiaoyong931011
2022-02-25 89b7fb1d316cfce7eb98a27c8d668da493933f7f
src/main/java/com/xcong/excoin/rabbit/consumer/OperateOrderPriceConsumer.java
@@ -14,32 +14,32 @@
/**
 * 用户修改止损止盈价格、提价限价委托、下单爆仓价等消息
 * 后台打包开启 APP 不开启
 * @author helius
 */
@Component
@ConditionalOnProperty(prefix="app",name="newest-price-update-job",havingValue="true")
@Deprecated
@ConditionalOnProperty(prefix = "app", name = "newest-price-update-job-contract", havingValue = "true")
public class OperateOrderPriceConsumer {
   /**
    * 用户修改止损止盈价格、提价限价委托、下单爆仓价等消息
    * @date 2019年4月19日
    * @param message 消息体
    * @param channel 信道
    */
   @RabbitListener(queues = RabbitMqConfig.QUEUE_PRICEOPERATE)
   public void onMessageMorePro(Message message, Channel channel) {
    /**
     * 用户修改止损止盈价格、提价限价委托、下单爆仓价等消息
     *
     * @param message 消息体
     * @param channel 信道
     * @date 2019年4月19日
     */
    @RabbitListener(queues = RabbitMqConfig.QUEUE_PRICEOPERATE)
    public void onMessageMorePro(Message message, Channel channel) {
        String content = new String(message.getBody());
      System.out.println("我收到了用户的订单操作消息:"+content);
      // 操作前的map
        System.out.println("我收到了用户的订单操作消息:" + content);
        // 操作前的map
        // 转为model
      OrderModel orderModel = JSONObject.parseObject(content, OrderModel.class);
      // 向优先队列添加
      OrderOperatePriceService.dealWithNewMq(orderModel);
        OrderModel orderModel = JSONObject.parseObject(content, OrderModel.class);
        // 向优先队列添加
        OrderOperatePriceService.dealWithNewMq(orderModel);
   }
    }
}