| | |
| | | return new RabbitTemplate(connectionFactory); |
| | | } |
| | | |
| | | @Bean |
| | | public DirectExchange onlineTransferExchange() { |
| | | return new DirectExchange(QueueEnum.ONLINE_TRANSFER.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue onlineTransferQueue() { |
| | | return new Queue(QueueEnum.ONLINE_TRANSFER.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding defaultBind() { |
| | | return BindingBuilder.bind(onlineTransferQueue()).to(onlineTransferExchange()).with(QueueEnum.ONLINE_TRANSFER.getRoute()); |
| | | } |
| | | |
| | | @Bean |
| | | public DirectExchange distribProfitExchange() { |
| | | return new DirectExchange(QueueEnum.DISTRIB_PROFIT.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue distribProfitQueue() { |
| | | return new Queue(QueueEnum.DISTRIB_PROFIT.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding distribProfitBind() { |
| | | return BindingBuilder.bind(distribProfitQueue()).to(distribProfitExchange()).with(QueueEnum.DISTRIB_PROFIT.getRoute()); |
| | | } |
| | | |
| | | // === 用户购买奖励 start === |
| | | @Bean |
| | | public DirectExchange userBuyRewardExchange() { |
| | | return new DirectExchange(QueueEnum.USER_BUY_REWARD.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue userBuyRewardQueue() { |
| | | return new Queue(QueueEnum.USER_BUY_REWARD.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding userBuyRewardBind() { |
| | | return BindingBuilder.bind(userBuyRewardQueue()).to(userBuyRewardExchange()).with(QueueEnum.USER_BUY_REWARD.getRoute()); |
| | | } |
| | | // === 用户购买奖励 end === |
| | | |
| | | |
| | | // === nft卡牌盲盒 start === |
| | | @Bean |
| | | public DirectExchange nftBoxExchange() { |
| | | return new DirectExchange(QueueEnum.NFT_BOX.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue nftBoxQueue() { |
| | | return new Queue(QueueEnum.NFT_BOX.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding nftBoxBind() { |
| | | return BindingBuilder.bind(nftBoxQueue()).to(nftBoxExchange()).with(QueueEnum.NFT_BOX.getRoute()); |
| | | } |
| | | // === nft卡牌盲盒 end === |
| | | |
| | | |
| | | // === 业绩树 start === |
| | | @Bean |
| | | public DirectExchange achieveTreeExchange() { |
| | |
| | | return BindingBuilder.bind(withdrawFeeQueue()).to(withdrawFeeExchange()).with(QueueEnum.WITHDRAW_FEE.getRoute()); |
| | | } |
| | | // === 提现手续费 end === |
| | | |
| | | |
| | | |
| | | // === tfc最新价 start === |
| | | @Bean |
| | | public DirectExchange tfcNewPriceExchange() { |
| | | return new DirectExchange(QueueEnum.TFC_NEW_PRICE.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue tfcNewPriceQueue() { |
| | | return new Queue(QueueEnum.TFC_NEW_PRICE.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding tfcNewPriceBind() { |
| | | return BindingBuilder.bind(tfcNewPriceQueue()).to(tfcNewPriceExchange()).with(QueueEnum.TFC_NEW_PRICE.getRoute()); |
| | | } |
| | | // === tfc最新价 end === |
| | | |
| | | |
| | | |
| | | // === 手续费分发 start === |
| | | @Bean |
| | | public DirectExchange feeDistributeExchange() { |
| | | return new DirectExchange(QueueEnum.DISTRIB_PROFIT.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue feeDistributeQueue() { |
| | | return new Queue(QueueEnum.DISTRIB_PROFIT.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding feeDistributeBind() { |
| | | return BindingBuilder.bind(feeDistributeQueue()).to(feeDistributeExchange()).with(QueueEnum.DISTRIB_PROFIT.getRoute()); |
| | | } |
| | | // === 手续费分发 end === |
| | | |
| | | |
| | | |
| | | // === 层级奖励分发 start === |
| | | @Bean |
| | | public DirectExchange levelProfitExchange() { |
| | | return new DirectExchange(QueueEnum.LEVEL_PROFIT.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue levelProfitQueue() { |
| | | return new Queue(QueueEnum.LEVEL_PROFIT.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding levelProfitBind() { |
| | | return BindingBuilder.bind(levelProfitQueue()).to(levelProfitExchange()).with(QueueEnum.LEVEL_PROFIT.getRoute()); |
| | | } |
| | | // === 层级奖励分发 end === |
| | | |
| | | |
| | | |
| | | // === 计算是否有人出局 start === |
| | | @Bean |
| | | public DirectExchange memberOutExchange() { |
| | | return new DirectExchange(QueueEnum.MEMBER_OUT.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue memberOutQueue() { |
| | | return new Queue(QueueEnum.MEMBER_OUT.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding memberOutBind() { |
| | | return BindingBuilder.bind(memberOutQueue()).to(memberOutExchange()).with(QueueEnum.MEMBER_OUT.getRoute()); |
| | | } |
| | | // === 计算是否有人出局 end === |
| | | |
| | | |
| | | |
| | | // === 转账拨币 start === |
| | | @Bean |
| | | public DirectExchange bnbTransferExchange() { |
| | | return new DirectExchange(QueueEnum.BNB_TRANSFER.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue bnbTransferQueue() { |
| | | return new Queue(QueueEnum.BNB_TRANSFER.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding bnbTransferBind() { |
| | | return BindingBuilder.bind(bnbTransferQueue()).to(bnbTransferExchange()).with(QueueEnum.BNB_TRANSFER.getRoute()); |
| | | } |
| | | // === 转账拨币 end === |
| | | |
| | | |
| | | |
| | | // === 代理升级 start === |
| | | @Bean |
| | | public DirectExchange agentUpExchange() { |
| | | return new DirectExchange(QueueEnum.BNB_AGENT_UP.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue agentUpQueue() { |
| | | return new Queue(QueueEnum.BNB_AGENT_UP.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding agentUpBind() { |
| | | return BindingBuilder.bind(agentUpQueue()).to(agentUpExchange()).with(QueueEnum.BNB_AGENT_UP.getRoute()); |
| | | } |
| | | // === 代理升级 end === |
| | | |
| | | |
| | | |
| | | // === 消息测试 start === |
| | | @Bean |
| | | public DirectExchange bnbTransferTestExchange() { |
| | | return new DirectExchange(QueueEnum.BNB_TRANSFER_TEST.getExchange()); |
| | | } |
| | | |
| | | @Bean |
| | | public Queue bnbTransferTestQueue() { |
| | | return new Queue(QueueEnum.BNB_TRANSFER_TEST.getQueue()); |
| | | } |
| | | |
| | | @Bean |
| | | public Binding bnbTransferTestBind() { |
| | | return BindingBuilder.bind(bnbTransferTestQueue()).to(bnbTransferTestExchange()).with(QueueEnum.BNB_TRANSFER_TEST.getRoute()); |
| | | } |
| | | // === 消息测试 end === |
| | | } |