update go mod
This commit is contained in:
@@ -3,7 +3,6 @@ package notify
|
||||
import (
|
||||
"b612.me/starcrypto"
|
||||
"b612.me/stario"
|
||||
"b612.me/starnet"
|
||||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
@@ -23,7 +22,7 @@ type ClientCommon struct {
|
||||
conn net.Conn
|
||||
mu sync.Mutex
|
||||
msgID uint64
|
||||
queue *starnet.StarQueue
|
||||
queue *stario.StarQueue
|
||||
stopFn context.CancelFunc
|
||||
stopCtx context.Context
|
||||
parallelNum int
|
||||
@@ -55,7 +54,7 @@ func (c *ClientCommon) Connect(network string, addr string) error {
|
||||
return errors.New("client already run")
|
||||
}
|
||||
c.stopCtx, c.stopFn = context.WithCancel(context.Background())
|
||||
c.queue = starnet.NewQueueCtx(c.stopCtx, 4, math.MaxUint32)
|
||||
c.queue = stario.NewQueueCtx(c.stopCtx, 4, math.MaxUint32)
|
||||
conn, err := net.Dial(network, addr)
|
||||
if err != nil {
|
||||
return err
|
||||
@@ -84,7 +83,7 @@ func (c *ClientCommon) ConnectTimeout(network string, addr string, timeout time.
|
||||
return errors.New("client already run")
|
||||
}
|
||||
c.stopCtx, c.stopFn = context.WithCancel(context.Background())
|
||||
c.queue = starnet.NewQueueCtx(c.stopCtx, 4, math.MaxUint32)
|
||||
c.queue = stario.NewQueueCtx(c.stopCtx, 4, math.MaxUint32)
|
||||
conn, err := net.DialTimeout(network, addr, timeout)
|
||||
if err != nil {
|
||||
return err
|
||||
@@ -289,7 +288,7 @@ func (c *ClientCommon) loadMessage() {
|
||||
continue
|
||||
}
|
||||
c.wg.Add(1)
|
||||
go func(data starnet.MsgQueue) {
|
||||
go func(data stario.MsgQueue) {
|
||||
defer c.wg.Done()
|
||||
//fmt.Println("c received:", float64(time.Now().UnixNano()-nowd)/1000000)
|
||||
now := time.Now()
|
||||
|
||||
Reference in New Issue
Block a user