尝试给上报到elasticsearch的文档加_id

This commit is contained in:
zhangkun 2024-12-04 12:37:24 +08:00
parent d84d4f5adf
commit 270aa9effe
3 changed files with 2 additions and 2 deletions

@ -288,7 +288,7 @@ func (core *Core) SaveUniKey(period string, keyName string, extt time.Duration,
wg := WriteLog{
Content: cd,
Tag: "sardine.log.candle." + cl.Period,
// Id: hashString(did),
Id: hashString(did),
}
// go func() {
core.WriteLogChan <- &wg

@ -87,7 +87,7 @@ func WriteLogProcess(cr *Core) {
for {
wg := <-cr.WriteLogChan
go func(wg *WriteLog) {
fmt.Println("start writelog")
fmt.Println("start writelog: " + wg.Id)
wg.Process(cr)
}(wg)
}

BIN
tunas

Binary file not shown.