sharingan: github.com/didi/sharingan Index | Examples | Files | Directories

package sharingan

import "github.com/didi/sharingan"

Code:

doneChan := make(chan bool)

go func(delegatedID int64) {
    sharingan.SetDelegatedFromGoRoutineID(delegatedID)
    defer sharingan.SetDelegatedFromGoRoutineID(0)

    http.Get("http://127.0.0.1:8888")

    doneChan <- true
}(sharingan.GetCurrentGoRoutineID())

<-doneChan

Index

Examples

Package Files

tag_with_origin.go

func GetCurrentGoRoutineID Uses

func GetCurrentGoRoutineID() int64

GetCurrentGoRoutineID get current goroutineID incase SetDelegatedFromGoRoutineID

func SetDelegatedFromGoRoutineID Uses

func SetDelegatedFromGoRoutineID(gID int64)

SetDelegatedFromGoRoutineID should be used when this goroutine is doing work for another goroutine

Directories

PathSynopsis
example
example/recorder
example/replayerReplayer demo for how to import package "github.com/didi/sharingan/replayer"
plugins
recorder
recorder-agent
recorder-agent/common/conf
recorder-agent/common/path
recorder-agent/common/zap
recorder-agent/record
recorder-agent/server
recorder/hook
recorder/internal
recorder/logger
recorder/recording
recorder/sut
recorder/utils
replayer
replayer-agent
replayer-agent/common/global
replayer-agent/common/handlers/conf
replayer-agent/common/handlers/httpclient
replayer-agent/common/handlers/httpserv
replayer-agent/common/handlers/ignore
replayer-agent/common/handlers/limit
replayer-agent/common/handlers/module
replayer-agent/common/handlers/outbound
replayer-agent/common/handlers/path
replayer-agent/common/handlers/template
replayer-agent/common/handlers/tlog
replayer-agent/controller
replayer-agent/idl
replayer-agent/logic/bind
replayer-agent/logic/match
replayer-agent/logic/outbound
replayer-agent/logic/replayed
replayer-agent/logic/search
replayer-agent/logic/worker
replayer-agent/model/esmodel
replayer-agent/model/nuwaplt
replayer-agent/model/originmodel
replayer-agent/model/pipe
replayer-agent/model/pool
replayer-agent/model/protocolPackage internal contains HTTP internals shared by net/http and net/http/httputil.
replayer-agent/model/recording
replayer-agent/model/replaying
replayer-agent/model/station
replayer-agent/model/trie
replayer-agent/router
replayer-agent/utils/helper
replayer-agent/utils/protocol/helper
replayer-agent/utils/protocol/pmysql
replayer-agent/utils/protocol/pmysql/command
replayer-agent/utils/protocol/pmysql/common
replayer-agent/utils/protocol/pmysql/handshake
replayer-agent/utils/protocol/pmysql/prepared
replayer-agent/utils/protocol/pthrift
replayer/fastmock
replayer/internal
replayer/monkey

Package sharingan is imported by 3 packages. Updated 2020-12-03. Refresh now. Tools for package owners.