Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

race detected test TestBatchDeleteObjectsOfS3 #4282

Closed
july2993 opened this issue Nov 30, 2021 · 1 comment
Closed

race detected test TestBatchDeleteObjectsOfS3 #4282

july2993 opened this issue Nov 30, 2021 · 1 comment
Labels
status/help-wanted Extra attention is needed

Comments

@july2993
Copy link
Contributor

july2993 commented Nov 30, 2021

https://pipelines.actions.githubusercontent.com/XmlGqt0jpH5ovEMHxNC2UKP0AhbomTmki7mJypwpILn8wVQr4g/_apis/pipelines/1/runs/16044/signedlogcontent/5?urlExpires=2021-11-30T08%3A01%3A02.4844462Z&urlSigningMethod=HMACV1&urlSignature=LktvTDQO8PdacczfUTkw4Lal4OuxdcukrTafvXBUrTA%3D

...
2021-11-30T07:48:06.8725050Z ==================
2021-11-30T07:48:06.8725417Z ==================
2021-11-30T07:48:06.8725820Z WARNING: DATA RACE
2021-11-30T07:48:06.8726498Z Read at 0x00c000a40918 by goroutine 24:
2021-11-30T07:48:06.8727532Z   sigs.k8s.io/controller-runtime/pkg/log.(*loggerPromise).Fulfill()
2021-11-30T07:48:06.8729164Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:78 +0x177
2021-11-30T07:48:06.8730694Z   sigs.k8s.io/controller-runtime/pkg/log.(*loggerPromise).Fulfill()
2021-11-30T07:48:06.8732218Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:79 +0x1d2
2021-11-30T07:48:06.8733622Z   sigs.k8s.io/controller-runtime/pkg/log.(*loggerPromise).Fulfill()
2021-11-30T07:48:06.8735152Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:79 +0x1d2
2021-11-30T07:48:06.8736533Z   sigs.k8s.io/controller-runtime/pkg/log.(*loggerPromise).Fulfill()
2021-11-30T07:48:06.8738053Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:79 +0x1d2
2021-11-30T07:48:06.8739477Z   sigs.k8s.io/controller-runtime/pkg/log.(*DelegatingLogger).Fulfill()
2021-11-30T07:48:06.8741041Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:124 +0x12e
2021-11-30T07:48:06.8742384Z   sigs.k8s.io/controller-runtime/pkg/log.init.0.func1()
2021-11-30T07:48:06.8743822Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/log.go:67 +0xbb
2021-11-30T07:48:06.8744572Z 
2021-11-30T07:48:06.8745100Z Previous write at 0x00c000a40918 by main goroutine:
2021-11-30T07:48:06.8745721Z   [failed to restore the stack]
2021-11-30T07:48:06.8746070Z 
2021-11-30T07:48:06.8746529Z Goroutine 24 (running) created at:
2021-11-30T07:48:06.8747410Z   sigs.k8s.io/controller-runtime/pkg/log.init.0()
2021-11-30T07:48:06.8748830Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/log.go:62 +0x44
2021-11-30T07:48:06.8749725Z ==================
2021-11-30T07:48:06.8750075Z ==================
2021-11-30T07:48:06.8750497Z WARNING: DATA RACE
2021-11-30T07:48:06.8751020Z Read at 0x00c0004f2ac0 by goroutine 24:
2021-11-30T07:48:06.8752034Z   sigs.k8s.io/controller-runtime/pkg/log.(*loggerPromise).Fulfill()
2021-11-30T07:48:06.8753554Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:78 +0x1a7
2021-11-30T07:48:06.8754952Z   sigs.k8s.io/controller-runtime/pkg/log.(*loggerPromise).Fulfill()
2021-11-30T07:48:06.8756762Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:79 +0x1d2
2021-11-30T07:48:06.8758314Z   sigs.k8s.io/controller-runtime/pkg/log.(*DelegatingLogger).Fulfill()
2021-11-30T07:48:06.8759890Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:124 +0x12e
2021-11-30T07:48:06.8761245Z   sigs.k8s.io/controller-runtime/pkg/log.init.0.func1()
2021-11-30T07:48:06.8762693Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/log.go:67 +0xbb
2021-11-30T07:48:06.8763456Z 
2021-11-30T07:48:06.8763993Z Previous write at 0x00c0004f2ac0 by main goroutine:
2021-11-30T07:48:06.8764613Z   [failed to restore the stack]
2021-11-30T07:48:06.8764960Z 
2021-11-30T07:48:06.8765421Z Goroutine 24 (running) created at:
2021-11-30T07:48:06.8766300Z   sigs.k8s.io/controller-runtime/pkg/log.init.0()
2021-11-30T07:48:06.8767714Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/log.go:62 +0x44
2021-11-30T07:48:06.8768561Z ==================
2021-11-30T07:48:06.8768927Z ==================
2021-11-30T07:48:06.8769347Z WARNING: DATA RACE
2021-11-30T07:48:06.8769951Z Read at 0x00c0003189e8 by goroutine 24:
2021-11-30T07:48:06.8770975Z   sigs.k8s.io/controller-runtime/pkg/log.(*loggerPromise).Fulfill()
2021-11-30T07:48:06.8772669Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:78 +0x1a7
2021-11-30T07:48:06.8774201Z   sigs.k8s.io/controller-runtime/pkg/log.(*DelegatingLogger).Fulfill()
2021-11-30T07:48:06.8775783Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/deleg.go:124 +0x12e
2021-11-30T07:48:06.8777109Z   sigs.k8s.io/controller-runtime/pkg/log.init.0.func1()
2021-11-30T07:48:06.8778561Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/log.go:67 +0xbb
2021-11-30T07:48:06.8779313Z 
2021-11-30T07:48:06.8779829Z Previous write at 0x00c0003189e8 by main goroutine:
2021-11-30T07:48:06.8780459Z   [failed to restore the stack]
2021-11-30T07:48:06.8780805Z 
2021-11-30T07:48:06.8781255Z Goroutine 24 (running) created at:
2021-11-30T07:48:06.8782148Z   sigs.k8s.io/controller-runtime/pkg/log.init.0()
2021-11-30T07:48:06.8783550Z       /home/runner/work/tidb-operator/tidb-operator/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.7.2/pkg/log/log.go:62 +0x44
2021-11-30T07:48:06.8784416Z ==================
2021-11-30T07:48:06.8785249Z --- FAIL: TestBatchDeleteObjectsOfS3 (54.91s)
2021-11-30T07:48:06.8786132Z     testing.go:1092: race detected during execution of test

ref kubernetes-sigs/controller-runtime#1359

@july2993 july2993 added the status/help-wanted Extra attention is needed label Nov 30, 2021
@july2993
Copy link
Contributor Author

just avoid import it in b5efcba,
hard to upgrade the version of controller-runtime..

➜  tidb-operator git:(gracefule-tikv2) ✗ go mod why sigs.k8s.io/controller-runtime/pkg/log
# sigs.k8s.io/controller-runtime/pkg/log
github.com/pingcap/tidb-operator/pkg/controller/tidbcluster
sigs.k8s.io/controller-runtime
sigs.k8s.io/controller-runtime/pkg/log

../log/log.go:

 60 func init() {
 61     // Init is blocking, so start a new goroutine
 62     go func() {
 63         time.Sleep(30 * time.Second)
 64         loggerWasSetLock.Lock()
 65         defer loggerWasSetLock.Unlock()
 66         if !loggerWasSet {
 67             Log.Fulfill(NullLogger{})
 68         }
 69     }()
 70 }

@july2993 july2993 closed this as completed Dec 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/help-wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant