diff --git a/datanode/data_partition_repair.go b/datanode/data_partition_repair.go index 57f1cbb67..fc5849f6f 100644 --- a/datanode/data_partition_repair.go +++ b/datanode/data_partition_repair.go @@ -478,7 +478,7 @@ func (dp *DataPartition) streamRepairExtent(remoteExtentInfo *storage.ExtentInfo reply := repl.NewPacket() // read 64k streaming repair packet - if err = reply.ReadFromConn(conn, proto.ReadDeadlineTime); err != nil { + if err = reply.ReadFromConn(conn, 60); err != nil { err = errors.Trace(err, "streamRepairExtent receive data error") log.LogErrorf("action[streamRepairExtent] err(%v).", err) return diff --git a/util/exporter/timepoint.go b/util/exporter/timepoint.go index 8362e4835..11e2157bb 100644 --- a/util/exporter/timepoint.go +++ b/util/exporter/timepoint.go @@ -71,20 +71,14 @@ func (tp *TimePoint) Set() { func NewTPCnt(name string) (tpc *TimePointCount) { tpc = new(TimePointCount) - if !enabled { - tpc.to = ump.BeforeTP(fmt.Sprintf("%v_%v_%v", clustername, modulename, name)) - return - } + tpc.to = ump.BeforeTP(fmt.Sprintf("%v_%v_%v", clustername, modulename, name)) tpc.tp = NewTP(name) tpc.cnt = NewCounter(fmt.Sprintf("%s_count", name)) return } func (tpc *TimePointCount) Set(err error) { - if !enabled { - ump.AfterTP(tpc.to, err) - return - } + ump.AfterTP(tpc.to, err) tpc.tp.Set() tpc.cnt.Add(1) }