Bläddra i källkod

update bidding_temporary

wcc 1 år sedan
förälder
incheckning
5519a054ac
3 ändrade filer med 236 tillägg och 4 borttagningar
  1. 230 0
      createEsIndex/common-pro.toml
  2. 3 3
      createEsIndex/common.toml
  3. 3 1
      createEsIndex/main.go

+ 230 - 0
createEsIndex/common-pro.toml

@@ -0,0 +1,230 @@
+
+[udp]
+locport = ":1783"
+jyaddr = "172.17.145.178"
+jyport = 11118
+# neaddr = "127.0.0.1" ## 下个 es地址
+# neport = 1784
+
+[db]
+[db.mongoB]
+addr = "172.17.4.187:27082,172.17.145.163:27083"
+dbname = "qfw"
+coll = "bidding"
+size = 15
+user = "SJZY_RWbid_ES"
+password = "SJZY@B4i4D5e6S"
+
+[db.mongoP]
+addr = "172.17.4.85:27080"
+dbname = "qfw"
+coll = "projectset_20230904"
+size = 15
+user = ""
+password = ""
+
+[db.mongoQ]
+addr = "172.17.4.187:27082,172.17.145.163:27083"
+dbname = "mixdata"
+coll = ""
+size = 15
+user = "SJZY_RWbid_ES"
+password = "SJZY@B4i4D5e6S"
+
+[db.mongoS] ##  181 特殊企业,采购单位验证
+    # addr = "127.0.0.1:27001"
+    addr = "172.17.4.181:27001"
+    dbname = "mixdata"
+    coll = ""
+    size = 15
+    user = ""
+    password = ""
+
+
+[db.mysqlB]  ## buyer 采购单位
+    addr = "172.17.4.242:4000"
+    dbname = "global_common_data"
+    username = "wangchengcheng"
+    password = "Wcc#20221209P"
+
+[db.oss]
+   endpoint = "oss-cn-beijing-internal.aliyuncs.com"## 正式环境
+    # endpoint = "oss-cn-beijing.aliyuncs.com"## 测试环境
+    accesskey = "LTAI4G5x9aoZx8dDamQ7vfZi"
+    accesssecret = "Bk98FsbPYXcJe72n1bG3Ssf73acuNh"
+    bucketname = "topjy"
+    filesize = 500000  ## 单位字节,附件总字节长度限制;超过就不再读取。不配置默认500000
+
+    
+[db.es]
+addr = "http://172.17.4.184:19805"
+# addr = "http://172.17.4.184:19805,http://172.17.148.50:19805,http://172.17.145.164:19805"
+addrp = "http://172.17.145.178:9200" ## 9200单机版,已经切换7.1
+size = 5
+username = "es_all"
+password = "TopJkO2E_d1x"
+indexb = "bidding"
+indextmp = "bidding_temporary" ## 临时索引,其他程序需要
+typeb = "bidding"
+indexp = "projectset"
+typep = "projectset"
+indexwinner = "winner"
+typewinner = "winner"
+indexbuyer = "buyer"
+typebuyer = "buyer"
+detailfilter = ["(招标网|千里马|采招网|招标采购导航网|招标与采购网|中国招投标网|中国采购与招标网|中国采购与招标|优质采)[\\w\\W]{0,15}[http|https|htpps]?[a-z0-9:\\/\\/.]{0,20}(qianlima|zhaobiao|okcis|zbytb|infobidding|bidcenter|youzhicai|chinabidding|Chinabidding|CHINABIDDING)[a-z0-9.\\/\\/]{0,40}",
+    "招标网[\\w\\W]{0,15}[http|https|htpps]?[a-z0-9:\\/\\/.]{0,20}zhaobiao[a-z0-9.\\/\\/]{0,40}",
+    "千里马[\\w\\W]{0,15}[a-z0-9:\\/\\/.]{0,20}qianlima[a-z0-9.\\/\\/]{0,10}",
+    "[\\((]?(网址)?[::;;]?(http|https|htpps)*[::]?(\\/\\/)?(www|jinan|WWW)?.(zhaobiao|chinabidding|Chinabidding|CHINABIDDING|infobidding|zbytb|okcis|qianlima|youzhicai).(com|cn|COM|CN)?(.cn|.CN)?\\/?[\\))]?",
+    "[\\((]?(网址)?(::)?(http|https|htpps)*(:|:)?\\/\\/www.bidcenter.com.cn\\/",
+    "千里马(平台|网站)+", "[“\"]?优质采(平台|电子交易平台|云采购平台|交易平台)?[”\"]?", "《?(中国采购与|中国)?招(投)?标(与采购|采购导航)?网》?",
+    "《?元博网(采购与招标网)?》?", "《?(中国)?招标采购导航网》?", "中\\W{0,3}国采\\W{0,3}招\\W{0,3}网\\W*[((]?(bidcenter.com.cn)?[))]?", "已方宝", "中国招标与采购"]
+addr2 = "http://172.17.4.184:19905"
+username2 = "jybid"
+password2 = "Top2023_JEB01i@31"
+indexb2 = "bidding"
+
+[mail]
+send = true
+to = "wangjianghan@topnet.net.cn,wangchengcheng@topnet.net.cn,zhangjinkun@topnet.net.cn,zhengkun@topnet.net.cn"
+api = "http://172.17.145.179:19281/_send/_mail"
+
+[env]
+    stype = 0 ## 默认0 正式环境;1测试环境。测试环境不会执行定时任务更新采购单位、中标单位、数据检测
+
+# 日志
+[log]
+# 日志路径,为空将输出控制台
+logpath = "./log/log.out"
+# logpath = ""
+# log size (M)
+maxsize = 10
+# compress log
+compress = true
+# log save  time (day)
+maxage =  7
+# save total log file total
+maxbackups = 10
+# log level
+loglevel  = "debug"
+# text or json output
+format = "text"
+
+[db.es.fieldes]
+"_id" = ""
+"buyerzipcode" = "string"
+"winnertel" = "string"
+"winnerperson" = "string"
+"contractcode" = "string"
+"winneraddr" = "string"
+"agencyaddr" = "string"
+"buyeraddr" = "string"
+"signaturedate" = "int64"
+"projectperiod" = "string"
+"projectaddr" = "string"
+"agencytel" = "string"
+"agencyperson" = "string"
+"buyerperson" = "string"
+"agency" = "string"
+"projectscope" = "string"
+"projectcode" = "string"
+"bidopentime" = "int64"
+"supervisorrate" = "float64"
+"buyertel" = "string"
+"bidamount" = "float64"
+"winner" = "string"
+"buyer" = "string"
+"budget" = "float64"
+"projectname" = "string"
+"bidstatus" = "string"
+"buyerclass" = "string"
+"topscopeclass" = ""
+"s_topscopeclass" = "string"
+"s_subscopeclass" = "string"
+"area" = "string"
+"city" = "string"
+"district" = "string"
+"s_winner" = "string"
+"title" = "string"
+"detail" = "string"
+"site" = "string"
+"comeintime" = "int64"
+"href" = "string"
+"infoformat" = "int32"
+"publishtime" = "int64"
+"s_sha" = "string"
+"spidercode" = "string"
+"subtype" = "string"
+"toptype" = "string"
+"projectinfo" = ""
+"purchasing" = "string"
+"purchasinglist" = ""
+"channel" = "string"
+"winnerorder" = ""
+"project_scale" = "string"
+"project_duration" = "int32"
+"project_timeunit" = "string"
+"project_startdate" = "int64"
+"project_completedate" = "int64"
+"payway" = "string"
+"contract_guarantee" = "bool"
+"bid_guarantee" = "bool"
+"qualifies" = ""
+"entidlist" = ""
+"funds" = "string"
+"review_experts" = "string"
+"bidmethod" = "string"
+"bidendtime" = "int64"
+"bidopenaddress" = "string"
+"docamount" = "float64"
+"agencyrate" = "float64"
+"agencyfee" = "float64"
+"bidway" = "string"
+"getdocmethod" = "string"
+"china_bidding" = "string"
+"purchasing_tag" = "string"
+"multipackage" = "int32"
+"isValidFile" = "bool"
+"bid_field" = "string"
+"bidstarttime" = "int64"
+"docendtime" = "int64"
+"docstarttime" = "int64"
+"signendtime" = "int64"
+"signstarttime" = "int64"
+"issue_quota" = "float64"
+"bidopen_shape" = "string"
+"quote_mode" = "string"
+"is_acquire_tender" = "bool"
+"is_payment_deposit" = "bool"
+"is_joint_bidding" = "bool"
+"procurementlist" = ""
+"object_type"="string"  ##针对中国政府采购网,添加字段,区分货物、服务和工程
+[db.es.fieldprojectinfo]
+"approvecode" = "string"
+"approvecontent" = "string"
+"approvestatus" = "string"
+"approvetime" = "string"
+"approvedept" = "string"
+"approvenumber" = "string"
+"projecttype" = "string"
+"approvecity" = "string"
+[db.es.fieldpurchasinglist]
+"itemname" = "string"
+"item" = "string"
+"brandname" = "string"
+"model" = "string"
+"unitname" = "string"
+"number" = "float64"
+"unitprice" = "float64"
+"totalprice" = "float64"
+[db.es.fieldprocurementlist]
+"projectname" = "string"
+"buyer" = "string"
+"item" = "string"
+"projectscope" = "string"
+"expurasingtime" = "int64"
+"totalprice" = "float64"
+[db.es.fieldwinnerorder]
+"sort" = "int"
+"sortstr" = "string"
+"entname" = "string"

+ 3 - 3
createEsIndex/common.toml

@@ -59,9 +59,9 @@
 [db.es]
 #    addr = "http://127.0.0.1:19805"      ## 正常bidding 链接
     addr = "http://192.168.3.149:9201"      ## 正常bidding 链接
-#    addrp = "http://192.168.3.149:9201"   ## 采集使用的单机版地址
-username = "es_all"
-password = "TopJkO2E_d1x"
+    addrp = "http://192.168.3.149:9201"    ##  采集使用的单机版地址
+    username = "es_all"
+    password = "TopJkO2E_d1x"
     size = 5
     indexb = "bidding"
     indextmp = "bidding_temporary"       ## 临时索引,其他程序需要

+ 3 - 1
createEsIndex/main.go

@@ -383,7 +383,8 @@ func SaveEsMethod() {
 					}()
 					Es.BulkSave(config.Conf.DB.Es.IndexB, arru)
 					if config.Conf.DB.Es.IndexTmp != "" {
-						Es2.BulkSave(config.Conf.DB.Es.IndexTmp, arru)
+						Es2.BulkSave(config.Conf.DB.Es.IndexTmp, arru) // 新集群
+						Es.BulkSave(config.Conf.DB.Es.IndexTmp, arru)  //老集群
 					}
 					if config.Conf.DB.Es.Addr2 != "" {
 						Es2.BulkSave(config.Conf.DB.Es.Indexb2, arru)
@@ -403,6 +404,7 @@ func SaveEsMethod() {
 					Es.BulkSave(config.Conf.DB.Es.IndexB, arru)
 					if config.Conf.DB.Es.IndexTmp != "" {
 						Es2.BulkSave(config.Conf.DB.Es.IndexTmp, arru)
+						Es.BulkSave(config.Conf.DB.Es.IndexTmp, arru)
 					}
 					if config.Conf.DB.Es.Addr2 != "" {
 						Es2.BulkSave(config.Conf.DB.Es.Indexb2, arru)