Skip to content

Commit 3966395

Browse files
committed
Merge remote-tracking branch 'origin/master' into pr/5435
2 parents 250eb9d + 1205326 commit 3966395

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+2336
-486
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ basic-test: install-tools
214214

215215
ci-test-job: install-tools dashboard-ui
216216
@$(FAILPOINT_ENABLE)
217-
CGO_ENABLED=1 go test -tags deadlock -race -covermode=atomic -coverprofile=covprofile -coverpkg=./... $(shell ./scripts/ci-subtask.sh $(JOB_COUNT) $(JOB_INDEX))
217+
CGO_ENABLED=1 go test -timeout=15m -tags deadlock -race -covermode=atomic -coverprofile=covprofile -coverpkg=./... $(shell ./scripts/ci-subtask.sh $(JOB_COUNT) $(JOB_INDEX))
218218
@$(FAILPOINT_DISABLE)
219219

220220
ci-test-job-submod: install-tools dashboard-ui

client/client.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,7 @@ const (
321321
updateMemberTimeout = time.Second // Use a shorter timeout to recover faster from network isolation.
322322
tsLoopDCCheckInterval = time.Minute
323323
defaultMaxTSOBatchSize = 10000 // should be higher if client is sending requests in burst
324-
retryInterval = 1 * time.Second
324+
retryInterval = time.Second
325325
maxRetryTimes = 5
326326
)
327327

client/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ require (
66
github.com/opentracing/opentracing-go v1.2.0
77
github.com/pingcap/errors v0.11.5-0.20211224045212-9687c2b0f87c
88
github.com/pingcap/failpoint v0.0.0-20210918120811-547c13e3eb00
9-
github.com/pingcap/kvproto v0.0.0-20220805093305-ab1ee4d521ab
9+
github.com/pingcap/kvproto v0.0.0-20220818063303-5c20f55db5ad
1010
github.com/pingcap/log v0.0.0-20211215031037-e024ba4eb0ee
1111
github.com/prometheus/client_golang v1.11.0
1212
github.com/stretchr/testify v1.7.0

client/go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,8 @@ github.com/pingcap/errors v0.11.5-0.20211224045212-9687c2b0f87c h1:xpW9bvK+HuuTm
104104
github.com/pingcap/errors v0.11.5-0.20211224045212-9687c2b0f87c/go.mod h1:X2r9ueLEUZgtx2cIogM0v4Zj5uvvzhuuiu7Pn8HzMPg=
105105
github.com/pingcap/failpoint v0.0.0-20210918120811-547c13e3eb00 h1:C3N3itkduZXDZFh4N3vQ5HEtld3S+Y+StULhWVvumU0=
106106
github.com/pingcap/failpoint v0.0.0-20210918120811-547c13e3eb00/go.mod h1:4qGtCB0QK0wBzKtFEGDhxXnSnbQApw1gc9siScUl8ew=
107-
github.com/pingcap/kvproto v0.0.0-20220805093305-ab1ee4d521ab h1:rb720P/QawBTbC50fjwig1LIpu30ObIiThKokBt5mMk=
108-
github.com/pingcap/kvproto v0.0.0-20220805093305-ab1ee4d521ab/go.mod h1:OYtxs0786qojVTmkVeufx93xe+jUgm56GUYRIKnmaGI=
107+
github.com/pingcap/kvproto v0.0.0-20220818063303-5c20f55db5ad h1:lGKxsEwdE0pVXzHYD1SQ1vfa3t/bFVU/latrQz8b/w0=
108+
github.com/pingcap/kvproto v0.0.0-20220818063303-5c20f55db5ad/go.mod h1:OYtxs0786qojVTmkVeufx93xe+jUgm56GUYRIKnmaGI=
109109
github.com/pingcap/log v0.0.0-20211215031037-e024ba4eb0ee h1:VO2t6IBpfvW34TdtD/G10VvnGqjLic1jzOuHjUb5VqM=
110110
github.com/pingcap/log v0.0.0-20211215031037-e024ba4eb0ee/go.mod h1:DWQW5jICDR7UJh4HtxXSM20Churx4CQL0fwL/SoOSA4=
111111
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ require (
2525
github.com/pingcap/errcode v0.3.0
2626
github.com/pingcap/errors v0.11.5-0.20211224045212-9687c2b0f87c
2727
github.com/pingcap/failpoint v0.0.0-20200702092429-9f69995143ce
28-
github.com/pingcap/kvproto v0.0.0-20220805093305-ab1ee4d521ab
28+
github.com/pingcap/kvproto v0.0.0-20220818063303-5c20f55db5ad
2929
github.com/pingcap/log v0.0.0-20210906054005-afc726e70354
3030
github.com/pingcap/sysutil v0.0.0-20211208032423-041a72e5860d
3131
github.com/pingcap/tidb-dashboard v0.0.0-20220728104842-3743e533b594

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -417,8 +417,8 @@ github.com/pingcap/failpoint v0.0.0-20200702092429-9f69995143ce h1:Y1kCxlCtlPTMt
417417
github.com/pingcap/failpoint v0.0.0-20200702092429-9f69995143ce/go.mod h1:w4PEZ5y16LeofeeGwdgZB4ddv9bLyDuIX+ljstgKZyk=
418418
github.com/pingcap/kvproto v0.0.0-20191211054548-3c6b38ea5107/go.mod h1:WWLmULLO7l8IOcQG+t+ItJ3fEcrL5FxF0Wu+HrMy26w=
419419
github.com/pingcap/kvproto v0.0.0-20200411081810-b85805c9476c/go.mod h1:IOdRDPLyda8GX2hE/jO7gqaCV/PNFh8BZQCQZXfIOqI=
420-
github.com/pingcap/kvproto v0.0.0-20220805093305-ab1ee4d521ab h1:rb720P/QawBTbC50fjwig1LIpu30ObIiThKokBt5mMk=
421-
github.com/pingcap/kvproto v0.0.0-20220805093305-ab1ee4d521ab/go.mod h1:OYtxs0786qojVTmkVeufx93xe+jUgm56GUYRIKnmaGI=
420+
github.com/pingcap/kvproto v0.0.0-20220818063303-5c20f55db5ad h1:lGKxsEwdE0pVXzHYD1SQ1vfa3t/bFVU/latrQz8b/w0=
421+
github.com/pingcap/kvproto v0.0.0-20220818063303-5c20f55db5ad/go.mod h1:OYtxs0786qojVTmkVeufx93xe+jUgm56GUYRIKnmaGI=
422422
github.com/pingcap/log v0.0.0-20191012051959-b742a5d432e9/go.mod h1:4rbK1p9ILyIfb6hU7OG2CiWSqMXnp3JMbiaVJ6mvoY8=
423423
github.com/pingcap/log v0.0.0-20200511115504-543df19646ad/go.mod h1:4rbK1p9ILyIfb6hU7OG2CiWSqMXnp3JMbiaVJ6mvoY8=
424424
github.com/pingcap/log v0.0.0-20210625125904-98ed8e2eb1c7/go.mod h1:8AanEdAHATuRurdGxZXBz0At+9avep+ub7U1AGYLIMM=

pkg/audit/audit_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ func TestPrometheusHistogramBackend(t *testing.T) {
7777
re.True(backend.ProcessHTTPRequest(req))
7878

7979
// For test, sleep time needs longer than the push interval
80-
time.Sleep(1 * time.Second)
80+
time.Sleep(time.Second)
8181
req, _ = http.NewRequest(http.MethodGet, ts.URL, nil)
8282
resp, err := http.DefaultClient.Do(req)
8383
re.NoError(err)

pkg/autoscaling/calculation.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ var (
4545
// MetricsTimeDuration is used to get the metrics of a certain time period.
4646
// This must be long enough to cover at least 2 scrape intervals
4747
// Or you will get nothing when querying CPU usage
48-
MetricsTimeDuration = 60 * time.Second
48+
MetricsTimeDuration = time.Minute
4949
// MaxScaleOutStep is used to indicate the maximum number of instance for scaling out operations at once.
5050
MaxScaleOutStep uint64 = 1
5151
// MaxScaleInStep is used to indicate the maximum number of instance for scaling in operations at once.

pkg/autoscaling/prometheus_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ import (
3232
)
3333

3434
const (
35-
mockDuration = 1 * time.Second
35+
mockDuration = time.Second
3636
mockClusterName = "mock"
3737
mockTiDBInstanceNamePattern = "%s-tidb-%d"
3838
mockTiKVInstanceNamePattern = "%s-tikv-%d"
@@ -340,7 +340,7 @@ func TestGetDurationExpression(t *testing.T) {
340340
expectedExpression: "30s",
341341
},
342342
{
343-
duration: 60 * time.Second,
343+
duration: time.Minute,
344344
expectedExpression: "60s",
345345
},
346346
{

pkg/etcdutil/etcdutil.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ const (
4545

4646
// DefaultSlowRequestTime 1s for the threshold for normal request, for those
4747
// longer then 1s, they are considered as slow requests.
48-
DefaultSlowRequestTime = 1 * time.Second
48+
DefaultSlowRequestTime = time.Second
4949
)
5050

5151
// CheckClusterID checks etcd cluster ID, returns an error if mismatch.

0 commit comments

Comments
 (0)