Exemple #1
0
func TestTraceMgr(t *testing.T) {
	redis.Init("127.0.0.1:6379", 1)
	tt := New()
	tt.Trace("test1")
	id := tt.Identify()

	Find(id).Trace("test2")

	fmt.Println(tt.String())

	tt.Save()

	ttt := Load(tt.Identify())

	Trace(ttt.ID, "test3")
	fmt.Println(ttt)
}
Exemple #2
0
//=====================redis common====================
func RedisInit(addrs string) {
	redis.Init(addrs, 10)
}