mirror of
https://github.com/duanhf2012/origin.git
synced 2026-02-04 06:54:45 +08:00
增加自定义接口
This commit is contained in:
@@ -69,6 +69,18 @@ func RegProfiler(profilerName string) *Profiler {
|
||||
return pProfiler
|
||||
}
|
||||
|
||||
func (slf *Profiler) SetMaxOverTime(tm time.Duration){
|
||||
slf.maxOverTime = tm
|
||||
}
|
||||
|
||||
func (slf *Profiler) SetOverTime(tm time.Duration){
|
||||
slf.overTime = tm
|
||||
}
|
||||
|
||||
func (slf *Profiler) SetMaxRecordNum(num int){
|
||||
slf.maxRecordNum = num
|
||||
}
|
||||
|
||||
func (slf *Profiler) Push(tag string) *Analyzer{
|
||||
slf.stackLocker.Lock()
|
||||
defer slf.stackLocker.Unlock()
|
||||
|
||||
Reference in New Issue
Block a user