| | |
| | | public static final String EXCHANGE_A = "biue-exchange-A"; |
| | | |
| | | |
| | | public static final String EXCHANGE_USDT_UPDATE = "exchange_usdt_update"; |
| | | |
| | | public static final String QUEUE_USDT_UPDATE = "queue_usdt_update"; |
| | | |
| | | public static final String ROUTING_KEY_USDT_UPDATE = "routing_key_usdt_update"; |
| | | |
| | | public static final String EXCHANGE_USDT_ADDRESS = "exchange_usdt_address"; |
| | | |
| | | public static final String QUEUE_USDT_ADDRESS= "queue_usdt_address"; |
| | | |
| | | public static final String ROUTING_KEY_USDT_ADDRESS = "routing_key_usdt_address"; |
| | | |
| | | |
| | | /** |
| | | * 撮合交易 |
| | | */ |
| | | public static final String EXCHANGE_B = "biue-exchange-B"; |
| | | |
| | | |
| | | // 开多止盈队列 |
| | | public static final String QUEUE_MOREPRO = "QUEUE_MOREPRO_NEW"; |
| | | // 开空止盈队列 |
| | |
| | | // 全仓价格操作 |
| | | public static final String QUEUE_WHOLE_PRICE = "QUEUE_WHOLE_PRCE"; |
| | | |
| | | // 跟单下单 |
| | | public static final String QUEUE_FOLLOW_ORDER = "QUEUE_FOLLOW_ORDER"; |
| | | |
| | | public static final String ROUTINGKEY_FOLLOW_ORDER = "ROUTINGKEY_FOLLOW_ORDER"; |
| | | |
| | | // 跟单调整保证金 |
| | | public static final String QUEUE_FOLLOW_CHANGE_BOND = "QUEUE_FOLLOW_CHANGE_BOND"; |
| | | |
| | | public static final String ROUTINGKEY_FOLLOW_CHANGE_BOND = "ROUTINGKEY_FOLLOW_CHANGE_BOND"; |
| | | |
| | | // 开多止盈路由键 |
| | | public static final String ROUTINGKEY_MOREPRO = "ROUTINGKEY_MOREPRO"; |
| | |
| | | @Bean |
| | | public Binding binding() { |
| | | return BindingBuilder.bind(testQueue()).to(defaultExchange()).with(ROUTING_KEY_TEST); |
| | | } |
| | | |
| | | |
| | | @Bean |
| | | public DirectExchange usdtUpdateExchange() { |
| | | return new DirectExchange(EXCHANGE_USDT_UPDATE); |
| | | } |
| | | |
| | | |
| | | @Bean |
| | | public Queue usdtUpdateQueue() { |
| | | return new Queue(QUEUE_USDT_UPDATE, true); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding usdtUpdatebinding() { |
| | | return BindingBuilder.bind(usdtUpdateQueue()).to(usdtUpdateExchange()).with(ROUTING_KEY_USDT_UPDATE); |
| | | } |
| | | |
| | | @Bean |
| | | public DirectExchange usdtAddressExchange() { |
| | | return new DirectExchange(EXCHANGE_USDT_ADDRESS); |
| | | } |
| | | |
| | | |
| | | @Bean |
| | | public Queue usdtAddressQueue() { |
| | | return new Queue(QUEUE_USDT_ADDRESS, true); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding usdtAddressbinding() { |
| | | return BindingBuilder.bind(usdtAddressQueue()).to(usdtAddressExchange()).with(ROUTING_KEY_USDT_ADDRESS); |
| | | } |
| | | |
| | | |
| | |
| | | return new Queue(QUEUE_WHOLE_BOMB, true); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue queueFollowOrder() { |
| | | return new Queue(QUEUE_FOLLOW_ORDER, true); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue queueFollowChangeBond() { |
| | | return new Queue(QUEUE_FOLLOW_CHANGE_BOND, true); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding bindingFollowChangeBond() { |
| | | return BindingBuilder.bind(queueFollowChangeBond()).to(orderExchange()).with(ROUTINGKEY_FOLLOW_CHANGE_BOND); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding bindingFollowOrder() { |
| | | return BindingBuilder.bind(queueFollowOrder()).to(orderExchange()).with(RabbitMqConfig.ROUTINGKEY_FOLLOW_ORDER); |
| | | } |
| | | |
| | | |
| | | @Bean |
| | | public Binding bindingWholePrice() { |