Browse Source

update 由于原本的tools.anxinyun.cn/iot/es-router 外部无法访问 更新新地址

dev
lucas 1 week ago
parent
commit
d70c615014
  1. 33
      configFiles/config_承德金隅水泥_河北矿山_冀东承德.json
  2. 0
      configFiles/弃用备份/config_安心云深基坑数据上报.yaml
  3. 2
      configFiles/弃用备份/config_承德金隅水泥_河北矿山_冀东唐山.json
  4. 0
      configFiles/弃用备份/config_爆闪es数据上报http.yaml
  5. 6
      consumers/consumerCDJYSN.go
  6. 6
      models/EsAggTop.go

33
configFiles/config_承德金隅水泥_河北矿山_冀东承德.json

@ -0,0 +1,33 @@
{
"consumer": "consumerCDJYSN",
"ioConfig": {
"in": {
"http": {
"url": "http://117.89.29.14:39200/axy_themes/_search"
},
"cronStr": "01 0/1 * * *"
},
"out": {
"file": {
"directory": "G:\\工作记录\\每月任务需求\\202402需求\\河北矿山数据本地数据工具开发\\saveTxts2",
"fileNameExtension": ".txt"
}
}
},
"info": {
"structureId": "4326",
"structUploadCode": "130821030006",
"fileNamePrefix": "130821030006_LTCDSS",
"fileContentHeader": "130821030006;承德冀东水泥股份有限公司石灰石矿;"
},
"sensorMap": {
"GnssSensorMap": {
"BMWY_G1": "100001",
"BMWY_G2": "100002",
"BMWY_G3": "100003"
},
"RainSensorMap": {
"JYL": "200001"
}
}
}

0
configFiles/config_安心云深基坑数据上报.yaml → configFiles/弃用备份/config_安心云深基坑数据上报.yaml

2
configFiles/config_承德金隅水泥_河北矿山_冀东唐山.json → configFiles/弃用备份/config_承德金隅水泥_河北矿山_冀东唐山.json

@ -5,7 +5,7 @@
"http": { "http": {
"url": "https://tools.anxinyun.cn/iot/es-router/anxincloud_themes/_search" "url": "https://tools.anxinyun.cn/iot/es-router/anxincloud_themes/_search"
}, },
"cronStr": "39 0/1 * * *" "cronStr": "04 0/1 * * *"
}, },
"out": { "out": {
"file": { "file": {

0
configFiles/config_爆闪es数据上报http.yaml → configFiles/弃用备份/config_爆闪es数据上报http.yaml

6
consumers/consumerCDJYSN.go

@ -301,9 +301,9 @@ func (the *consumerCDJYSN) getEsData() {
} }
} }
`, structureId, start, end) `, structureId, start, end)
auth := map[string]string{"Authorization": "Basic YWRtaW46RnJlZXN1bl8xMjM="} //auth := map[string]string{"Authorization": "Basic YWRtaW46cV4hNXV5WEY1c2JJ"}
//the.InHttp.HttpClient.SetAuth("admin", "Freesun_123") the.InHttp.HttpClient.SetAuth("admin", "q^!5uyXF5sbI")
esAggResult := the.InHttp.HttpClient.HttpGetWithHeader(esQuery, auth) esAggResult := the.InHttp.HttpClient.HttpGet(esQuery)
var needPush []byte var needPush []byte
adaptor := the.getAdaptor() adaptor := the.getAdaptor()

6
models/EsAggTop.go

@ -36,7 +36,7 @@ type EsAggTop struct {
Failed int `json:"failed"` Failed int `json:"failed"`
} `json:"_shards"` } `json:"_shards"`
Hits struct { Hits struct {
Total int `json:"total"` //Total int `json:"total"`
MaxScore float64 `json:"max_score"` MaxScore float64 `json:"max_score"`
} `json:"hits"` } `json:"hits"`
Aggregations struct { Aggregations struct {
@ -53,8 +53,8 @@ type Bucket struct {
DocCount int `json:"doc_count"` DocCount int `json:"doc_count"`
Last struct { Last struct {
Hits struct { Hits struct {
Total int `json:"total"` //Total int `json:"total"`
Hits []struct { Hits []struct {
Index string `json:"_index"` Index string `json:"_index"`
Type string `json:"_type"` Type string `json:"_type"`
Id string `json:"_id"` Id string `json:"_id"`

Loading…
Cancel
Save