Add support of EventDomainFronting event

This commit is contained in:
9seconds
2021-03-29 11:56:05 +03:00
parent 36d695118e
commit bef14bd009
17 changed files with 317 additions and 53 deletions
+6 -4
View File
@@ -4,15 +4,17 @@ import "sync"
var streamInfoPool = sync.Pool{
New: func() interface{} {
return streamInfo{}
return &streamInfo{
tags: make(map[string]string),
}
},
}
func acquireStreamInfo() streamInfo {
return streamInfoPool.Get().(streamInfo)
func acquireStreamInfo() *streamInfo {
return streamInfoPool.Get().(*streamInfo)
}
func releaseStreamInfo(info streamInfo) {
func releaseStreamInfo(info *streamInfo) {
info.Reset()
streamInfoPool.Put(info)
}