From ecd21990ac50938c131431a1832d48da04288104 Mon Sep 17 00:00:00 2001 From: shenjiachi Date: Tue, 31 Dec 2024 19:03:14 +0800 Subject: [PATCH] update --- consume/init.go | 76 +++++++++---------- .../temporary_egg_energy_deal_user_ecpm.go | 4 +- etc/cfg.yml | 30 ++++---- 3 files changed, 55 insertions(+), 55 deletions(-) diff --git a/consume/init.go b/consume/init.go index 86ff65d..3798b98 100644 --- a/consume/init.go +++ b/consume/init.go @@ -17,45 +17,45 @@ func Init() { // 增加消费任务队列 func initConsumes() { - jobs[consumeMd.EggSlowAutoUpLvConsume] = EggSlowAutoUpLvConsume //缓慢 自动升级 - jobs[consumeMd.EggEnergyUserActivityConsume] = EggEnergyUserActivityConsume //监听 自动升级 - jobs[consumeMd.EggCanalUserConsume] = EggCanalUserConsume //监听 自动升级 - - jobs[consumeMd.AliyunSmsRecordFunName] = AliyunSmsRecordConsume //阿里云短信 - jobs[consumeMd.JpushRecordFunName] = JpushRecordConsume //极光推送 - jobs[consumeMd.UserDeleteFunName] = UserDeleteConsume // 用户注销处理 - - jobs[consumeMd.EggEnergyNewUserRegisterDataFunName] = EggEnergyNewUserRegisterDataConsume // 新用户注册 - jobs[consumeMd.IMEggEnergyBatchSendMessageDataFunName] = IMEggEnergyBatchSendMessageDataConsume // 批量发送信息 - jobs[consumeMd.IMEggEnergyDelFriendCircleDataFunName] = IMEggEnergyDelFriendCircleDataConsume // 删除朋友圈 - jobs[consumeMd.EggFinWithdrawApplyDataConsumeFunName] = EggFinWithdrawApplyDataConsume // 提现 - - jobs[consumeMd.EggEnergyDealUserECPMFunName] = EggEnergyDealUserECPMConsume // 处理给用户Ecpm值 + //jobs[consumeMd.EggSlowAutoUpLvConsume] = EggSlowAutoUpLvConsume //缓慢 自动升级 + //jobs[consumeMd.EggEnergyUserActivityConsume] = EggEnergyUserActivityConsume //监听 自动升级 + //jobs[consumeMd.EggCanalUserConsume] = EggCanalUserConsume //监听 自动升级 + // + //jobs[consumeMd.AliyunSmsRecordFunName] = AliyunSmsRecordConsume //阿里云短信 + //jobs[consumeMd.JpushRecordFunName] = JpushRecordConsume //极光推送 + //jobs[consumeMd.UserDeleteFunName] = UserDeleteConsume // 用户注销处理 + // + //jobs[consumeMd.EggEnergyNewUserRegisterDataFunName] = EggEnergyNewUserRegisterDataConsume // 新用户注册 + //jobs[consumeMd.IMEggEnergyBatchSendMessageDataFunName] = IMEggEnergyBatchSendMessageDataConsume // 批量发送信息 + //jobs[consumeMd.IMEggEnergyDelFriendCircleDataFunName] = IMEggEnergyDelFriendCircleDataConsume // 删除朋友圈 + //jobs[consumeMd.EggFinWithdrawApplyDataConsumeFunName] = EggFinWithdrawApplyDataConsume // 提现 + // + //jobs[consumeMd.EggEnergyDealUserECPMFunName] = EggEnergyDealUserECPMConsume // 处理给用户Ecpm值 jobs[consumeMd.EggEnergyTemporaryDealUserECPMFunName] = TemporaryEggEnergyDealUserECPMConsume // 临时处理给用户Ecpm值 - jobs[consumeMd.EggCanalInviteUserNumsFunName] = EggCanalInviteUserNumsConsume // 处理拉新人数 - jobs[consumeMd.EggCanalViolateNumsFunName] = EggCanalViolateNumsConsume // 处理违规次数 - jobs[consumeMd.IMEggEnergySendRedPackageFunName] = IMEggEnergySendRedPackageConsume // 处理用户发送红包次数 - jobs[consumeMd.EggCanalPersonAddActivityValueFunName] = EggCanalPersonAddActivityValueConsume // 用户活跃积分变更时更新es - jobs[consumeMd.EggRecordActiveDataFunName] = EggRecordActiveDataConsume // 用户签到后更新活跃数据 - jobs[consumeMd.EggEnergyAutoScoreDataFunName] = EggEnergyAutoScoreConsume // 自动打分 - jobs[consumeMd.EggSendFriendCircleDataFunName] = EggSendFriendCircleDataConsume // 用户发送朋友圈后更新es - jobs[consumeMd.EggCommentDataFunName] = EggCommentDataConsume // 用户评论后更新es - jobs[consumeMd.EggCanalEnergyExchangeAccountFunName] = EggCanalEnergyExchangeAccountConsume // 蛋蛋能量兑换为余额的时候更新es - - jobs[consumeMd.VideoRewardFunName] = VideoRewardConsume // 短视频奖励 - jobs[consumeMd.PlayletRewardFunName] = PlayletRewardConsume // 短剧奖励 - - jobs[consumeMd.EggEnergyDealPlatformRevenueDataFunName] = EggEnergyDealPlatformRevenueDataConsume // 平台营收 - jobs[consumeMd.EggEnergyDealFundDataFunName] = EggEnergyDealFundDataConsume // 资金数据 - jobs[consumeMd.EggEnergyDealUserVirtualCoinDataFunName] = EggEnergyDealUserVirtualCoinDataConsume // 视频奖励给相应团队发放积分 - - jobs[consumeMd.PublicPlatoonUserRelationCommissionConsumeFunName] = AddPublicPlatoonUserRelationCommissionConsume - jobs[consumeMd.EggEnergyStartLevelDividendFunName] = EggEnergyStartLevelDividendConsume - jobs[consumeMd.EggEnergySettlementPublicGiveActivityCoinFunName] = EggEnergySettlementPublicGiveActivityCoinConsume - jobs[consumeMd.EggEnergyStartExchangeGreenEnergyFunName] = EggEnergyStartExchangeGreenEnergyConsume - jobs[consumeMd.EggEnergyAutoExchangeGreenEnergyFunName] = EggEnergyAutoExchangeGreenEnergyConsume - jobs[consumeMd.EggEnergyTeamAssistanceConsumeFunName] = EggEnergyTeamAssistanceConsume // 更新团队助力数据 - jobs[consumeMd.EggCanalUserVirtualCoinFlowAggregationConsumeFunName] = EggCanalUserVirtualCoinFlowAggregationConsume // 聚合流水数据 + //jobs[consumeMd.EggCanalInviteUserNumsFunName] = EggCanalInviteUserNumsConsume // 处理拉新人数 + //jobs[consumeMd.EggCanalViolateNumsFunName] = EggCanalViolateNumsConsume // 处理违规次数 + //jobs[consumeMd.IMEggEnergySendRedPackageFunName] = IMEggEnergySendRedPackageConsume // 处理用户发送红包次数 + //jobs[consumeMd.EggCanalPersonAddActivityValueFunName] = EggCanalPersonAddActivityValueConsume // 用户活跃积分变更时更新es + //jobs[consumeMd.EggRecordActiveDataFunName] = EggRecordActiveDataConsume // 用户签到后更新活跃数据 + //jobs[consumeMd.EggEnergyAutoScoreDataFunName] = EggEnergyAutoScoreConsume // 自动打分 + //jobs[consumeMd.EggSendFriendCircleDataFunName] = EggSendFriendCircleDataConsume // 用户发送朋友圈后更新es + //jobs[consumeMd.EggCommentDataFunName] = EggCommentDataConsume // 用户评论后更新es + //jobs[consumeMd.EggCanalEnergyExchangeAccountFunName] = EggCanalEnergyExchangeAccountConsume // 蛋蛋能量兑换为余额的时候更新es + // + //jobs[consumeMd.VideoRewardFunName] = VideoRewardConsume // 短视频奖励 + //jobs[consumeMd.PlayletRewardFunName] = PlayletRewardConsume // 短剧奖励 + // + //jobs[consumeMd.EggEnergyDealPlatformRevenueDataFunName] = EggEnergyDealPlatformRevenueDataConsume // 平台营收 + //jobs[consumeMd.EggEnergyDealFundDataFunName] = EggEnergyDealFundDataConsume // 资金数据 + //jobs[consumeMd.EggEnergyDealUserVirtualCoinDataFunName] = EggEnergyDealUserVirtualCoinDataConsume // 视频奖励给相应团队发放积分 + // + //jobs[consumeMd.PublicPlatoonUserRelationCommissionConsumeFunName] = AddPublicPlatoonUserRelationCommissionConsume + //jobs[consumeMd.EggEnergyStartLevelDividendFunName] = EggEnergyStartLevelDividendConsume + //jobs[consumeMd.EggEnergySettlementPublicGiveActivityCoinFunName] = EggEnergySettlementPublicGiveActivityCoinConsume + //jobs[consumeMd.EggEnergyStartExchangeGreenEnergyFunName] = EggEnergyStartExchangeGreenEnergyConsume + //jobs[consumeMd.EggEnergyAutoExchangeGreenEnergyFunName] = EggEnergyAutoExchangeGreenEnergyConsume + //jobs[consumeMd.EggEnergyTeamAssistanceConsumeFunName] = EggEnergyTeamAssistanceConsume // 更新团队助力数据 + //jobs[consumeMd.EggCanalUserVirtualCoinFlowAggregationConsumeFunName] = EggCanalUserVirtualCoinFlowAggregationConsume // 聚合流水数据 } func Run() { diff --git a/consume/temporary_egg_energy_deal_user_ecpm.go b/consume/temporary_egg_energy_deal_user_ecpm.go index 3e3d6b4..8472c14 100644 --- a/consume/temporary_egg_energy_deal_user_ecpm.go +++ b/consume/temporary_egg_energy_deal_user_ecpm.go @@ -23,7 +23,7 @@ import ( ) func TemporaryEggEnergyDealUserECPMConsume(queue md.MqQueue) { - fmt.Println(">>>>>>>>>>>>EggEnergyDealUserECPMConsume>>>>>>>>>>>>") + fmt.Println(">>>>>>>>>>>>TemporaryEggEnergyDealUserECPMConsume>>>>>>>>>>>>") ch, err := rabbit.Cfg.Pool.GetChannel() if err != nil { logx.Error(err) @@ -33,7 +33,7 @@ func TemporaryEggEnergyDealUserECPMConsume(queue md.MqQueue) { //1、将自己绑定到交换机上 ch.Bind(queue.Name, queue.ExchangeName, queue.RoutKey) //2、取出数据进行消费 - ch.Qos(1) + ch.Qos(200) delivery := ch.Consume(queue.Name, false) egg_system_rules.Init(cfg.RedisAddr) diff --git a/etc/cfg.yml b/etc/cfg.yml index cae636e..e08bbf2 100644 --- a/etc/cfg.yml +++ b/etc/cfg.yml @@ -81,26 +81,26 @@ log: file_name: 'debug.log' # 连接RabbitMq -mq: - host: '120.77.153.180' - port: '5672' - user: 'guest' - pwd: 'guest' #mq: -# host: '116.62.62.35' +# host: '120.77.153.180' # port: '5672' -# user: 'zhios' -# pwd: 'ZHIoscnfnuo123' - -#es: -# url: 'http://120.55.48.175:9200' -# user: 'elastic' -# pwd: 'fnuo123' +# user: 'guest' +# pwd: 'guest' +mq: + host: '116.62.62.35' + port: '5672' + user: 'zhios' + pwd: 'ZHIoscnfnuo123' es: - url: 'http://123.57.140.192:9200' + url: 'http://120.55.48.175:9200' user: 'elastic' - pwd: 'se4BxqYyGhHyPWPA3w8Q' + pwd: 'fnuo123' + +#es: +# url: 'http://123.57.140.192:9200' +# user: 'elastic' +# pwd: 'se4BxqYyGhHyPWPA3w8Q' im_business_rpc: url: im-rpc-business.izhim.com