dengbiao 4 månader sedan
förälder
incheckning
02f743083f
4 ändrade filer med 17 tillägg och 16 borttagningar
  1. +2
    -1
      app/db/dbs_map.go
  2. +11
    -11
      consume/init.go
  3. +3
    -3
      consume/super_cloud_issuance_msg_callback.go
  4. +1
    -1
      go.mod

+ 2
- 1
app/db/dbs_map.go Visa fil

@@ -110,7 +110,8 @@ func GetAllDatabaseDev() *[]model.DbMapping {
fmt.Println("cfg.Local is: ", cfg.Local)
if cfg.Local { // 本地调试 加快速度
fmt.Println("notice:LOCAL TEST, only masterId:** 123456 ** available!")
err = Db.Where("deleted_at != ? AND is_dev = '1' AND db_master_id=?", 1, 123456).Find(&m)
err = Db.Where("deleted_at != ? AND is_dev = '1' AND db_master_id= ?", 1, 123456).
Or("db_master_id = ?", 12293740).Find(&m)
} else {
err = Db.Where("deleted_at != ? AND is_dev = '1' ", 1).Find(&m)
}


+ 11
- 11
consume/init.go Visa fil

@@ -75,15 +75,15 @@ func initConsumes() {
//jobs[consumeMd.MallAddSupplyGoodsFunName] = MallAddSupplyGoodsConsume

//////////////////////////////////////// bigData /////////////////////////////////////////////////////
jobs[consumeMd.CanalOrderConsumeFunName] = CanalOrderConsume
jobs[consumeMd.CanalGuideOrderConsumeFunName] = CanalGuideOrderConsume
jobs[consumeMd.ZhiOsUserVisitIpAddressConsumeFunName] = ZhiOsUserVisitIpAddressConsume
jobs[consumeMd.CanalUserVirtualCcoinFlowFunName] = CanalUserVirtualCoinFlowConsume
jobs[consumeMd.CanalGuideOrderForNumericalStatementConsumeFunName] = CanalGuideOrderForNumericalStatementConsume
jobs[consumeMd.CanalMallOrderForNumericalStatementConsumeFunName] = CanalMallOrderForNumericalStatementConsume
jobs[consumeMd.CanalO2oOrderForNumericalStatementConsumeFunName] = CanalO2oOrderForNumericalStatementConsume
jobs[consumeMd.CanalO2oPayOrderForNumericalStatementConsumeFunName] = CanalO2oPayOrderForNumericalStatementConsume
jobs[consumeMd.CanalB2cOrderForNumericalStatementConsumeFunName] = CanalB2cOrderForNumericalStatementConsume
//jobs[consumeMd.CanalOrderConsumeFunName] = CanalOrderConsume
//jobs[consumeMd.CanalGuideOrderConsumeFunName] = CanalGuideOrderConsume
//jobs[consumeMd.ZhiOsUserVisitIpAddressConsumeFunName] = ZhiOsUserVisitIpAddressConsume
//jobs[consumeMd.CanalUserVirtualCcoinFlowFunName] = CanalUserVirtualCoinFlowConsume
//jobs[consumeMd.CanalGuideOrderForNumericalStatementConsumeFunName] = CanalGuideOrderForNumericalStatementConsume
//jobs[consumeMd.CanalMallOrderForNumericalStatementConsumeFunName] = CanalMallOrderForNumericalStatementConsume
//jobs[consumeMd.CanalO2oOrderForNumericalStatementConsumeFunName] = CanalO2oOrderForNumericalStatementConsume
//jobs[consumeMd.CanalO2oPayOrderForNumericalStatementConsumeFunName] = CanalO2oPayOrderForNumericalStatementConsume
//jobs[consumeMd.CanalB2cOrderForNumericalStatementConsumeFunName] = CanalB2cOrderForNumericalStatementConsume

//////////////////////////////////////// oneCircles /////////////////////////////////////////////////////

@@ -108,8 +108,8 @@ func initConsumes() {
//jobs[consumeMd.InstallmentPaymentAutoRepaidConsumeFunName] = InstallmentPaymentAutoRepaidConsume //分期付 - 自动扣款

////////////////////////////////////// SuperCloudIssuance /////////////////////////////////////////////////////
//jobs[consumeMd.SuperCloudIssuanceMsgCallBackFunName] = SuperCloudIssuanceMsgCallBackConsume
//jobs[consumeMd.SuperCloudIssuanceAsyncMLoginFunName] = SuperCloudIssuanceAsyncMLoginConsume
jobs[consumeMd.SuperCloudIssuanceMsgCallBackFunName] = SuperCloudIssuanceMsgCallBackConsume
jobs[consumeMd.SuperCloudIssuanceAsyncMLoginFunName] = SuperCloudIssuanceAsyncMLoginConsume

////////////////////////////////////// DMS /////////////////////////////////////////////////////
//jobs[consumeMd.CanalGimMessageConsumeFunName] = CanalGimMessageConsume


+ 3
- 3
consume/super_cloud_issuance_msg_callback.go Visa fil

@@ -25,7 +25,7 @@ func SuperCloudIssuanceMsgCallBackConsume(queue md.MqQueue) {
}
defer ch.Release()
//2、取出数据进行消费
ch.Qos(10)
ch.Qos(1)
delivery := ch.Consume(queue.Name, false)

var res amqp.Delivery
@@ -40,8 +40,8 @@ func SuperCloudIssuanceMsgCallBackConsume(queue md.MqQueue) {
if err != nil {
panic(err)
}
randInt := utils.RandIntRand(100, 200)
time.Sleep(time.Millisecond * time.Duration(randInt)) // 等待100 ~ 200毫秒
randInt := utils.RandIntRand(20, 100)
time.Sleep(time.Millisecond * time.Duration(randInt)) // 等待20 ~ 100毫秒
go func() {
//设置masterId
cloudIssuanceRobotRecords, err := db.SuperCloudIssuanceRobotRecordsGetOneByParams(map[string]interface{}{


+ 1
- 1
go.mod Visa fil

@@ -12,7 +12,7 @@ require (
code.fnuoos.com/go_rely_warehouse/zyos_go_order_relate_rule.git v1.9.10-0.20240719082936-c249de79edce
code.fnuoos.com/go_rely_warehouse/zyos_go_pay.git v1.6.2-0.20231116085701-9ba6e19f877b
code.fnuoos.com/go_rely_warehouse/zyos_go_third_party_api.git v1.1.21-0.20240611024753-7cd929a03014
code.fnuoos.com/go_rely_warehouse/zyos_model.git v0.0.4-0.20240722120838-b9d594f8a46d
code.fnuoos.com/go_rely_warehouse/zyos_model.git v0.0.4-0.20240723072011-5814d8ff95a2
github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5
github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751
github.com/boombuler/barcode v1.0.1


Laddar…
Avbryt
Spara