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

[Bug]: data race #16331

Closed
1 task done
sukki37 opened this issue May 22, 2024 · 3 comments
Closed
1 task done

[Bug]: data race #16331

sukki37 opened this issue May 22, 2024 · 3 comments
Assignees
Labels
kind/bug Something isn't working phase/testing resolved/v1.2.1 severity/s0 Extreme impact: Cause the application to break down and seriously affect the use
Milestone

Comments

@sukki37
Copy link
Contributor

sukki37 commented May 22, 2024

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Branch Name

main

Commit ID

ed279e6

Other Environment Information

- Hardware parameters:
- OS type:
- Others:

Actual Behavior

https://github.com/matrixorigin/matrixone/actions/runs/9180238142

==================
WARNING: DATA RACE
Read at 0x00c01f4a31a8 by goroutine 9918:
  github.com/matrixorigin/matrixone/pkg/txn/client.(*txnOperator).CloneSnapshotOp()
      /home/runner/_work/matrixone/matrixone/head/pkg/txn/client/operator.go:285 +0x465
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Compile).expandRanges()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/compile.go:3778 +0x5f7
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).handleRuntimeFilter()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:418 +0x13d0
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).ParallelRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:453 +0x426
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).RemoteRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:296 +0x11c
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun.func1()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:230 +0x31b
  github.com/panjf2000/ants/v2.(*goWorker).run.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:67 +0x1a5

Previous write at 0x00c01f4a31a8 by goroutine 9858:
  github.com/matrixorigin/matrixone/pkg/txn/client.(*txnOperator).CloneSnapshotOp()
      /home/runner/_work/matrixone/matrixone/head/pkg/txn/client/operator.go:285 +0x5ed
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Compile).expandRanges()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/compile.go:3778 +0x5f7
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).handleRuntimeFilter()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:418 +0x13d0
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).ParallelRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:453 +0x426
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).RemoteRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:296 +0x11c
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun.func1()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:230 +0x31b
  github.com/panjf2000/ants/v2.(*goWorker).run.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:67 +0x1a5

Goroutine 9918 (running) created at:
  github.com/panjf2000/ants/v2.(*goWorker).run()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:48 +0xe9
  github.com/panjf2000/ants/v2.(*Pool).retrieveWorker.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:337 +0xed
  github.com/panjf2000/ants/v2.(*Pool).retrieveWorker()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:348 +0x286
  github.com/panjf2000/ants/v2.(*Pool).Submit()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:222 +0x96
  github.com/panjf2000/ants/v2.Submit()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/ants.go:103 +0x56
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:213 +0x3ec
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).JoinRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:668 +0x5f7
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).ParallelRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:444 +0x2f0
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).RemoteRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:296 +0x11c
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun.func1()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:230 +0x31b
  github.com/panjf2000/ants/v2.(*goWorker).run.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:67 +0x1a5

Goroutine 9858 (running) created at:
  github.com/panjf2000/ants/v2.(*goWorker).run()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:48 +0xe9
  github.com/panjf2000/ants/v2.(*Pool).retrieveWorker.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:337 +0xed
  github.com/panjf2000/ants/v2.(*Pool).retrieveWorker()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:348 +0x286
  github.com/panjf2000/ants/v2.(*Pool).Submit()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:222 +0x96
  github.com/panjf2000/ants/v2.Submit()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/ants.go:103 +0x56
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:213 +0x3ec
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun.func1()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:228 +0x45d
  github.com/panjf2000/ants/v2.(*goWorker).run.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:67 +0x1a5
==================
==================
WARNING: DATA RACE
Write at 0x00c01f4a31a8 by goroutine 9918:
  github.com/matrixorigin/matrixone/pkg/txn/client.(*txnOperator).CloneSnapshotOp()
      /home/runner/_work/matrixone/matrixone/head/pkg/txn/client/operator.go:285 +0x5ed
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Compile).expandRanges()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/compile.go:3778 +0x5f7
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).handleRuntimeFilter()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:418 +0x13d0
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).ParallelRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:453 +0x426
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).RemoteRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:296 +0x11c
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun.func1()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:230 +0x31b
  github.com/panjf2000/ants/v2.(*goWorker).run.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:67 +0x1a5

Previous write at 0x00c01f4a31a8 by goroutine 10116:
  github.com/matrixorigin/matrixone/pkg/txn/client.(*txnOperator).CloneSnapshotOp()
      /home/runner/_work/matrixone/matrixone/head/pkg/txn/client/operator.go:285 +0x5ed
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Compile).expandRanges()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/compile.go:3778 +0x5f7
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).handleRuntimeFilter()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:418 +0x13d0
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).ParallelRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:453 +0x426
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).RemoteRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:296 +0x11c
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun.func1()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:230 +0x31b
  github.com/panjf2000/ants/v2.(*goWorker).run.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:67 +0x1a5

Goroutine 9918 (running) created at:
  github.com/panjf2000/ants/v2.(*goWorker).run()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:48 +0xe9
  github.com/panjf2000/ants/v2.(*Pool).retrieveWorker.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:337 +0xed
  github.com/panjf2000/ants/v2.(*Pool).retrieveWorker()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:348 +0x286
  github.com/panjf2000/ants/v2.(*Pool).Submit()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:222 +0x96
  github.com/panjf2000/ants/v2.Submit()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/ants.go:103 +0x56
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:213 +0x3ec
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).JoinRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:668 +0x5f7
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).ParallelRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:444 +0x2f0
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).RemoteRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:296 +0x11c
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun.func1()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:230 +0x31b
  github.com/panjf2000/ants/v2.(*goWorker).run.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:67 +0x1a5

Goroutine 10116 (running) created at:
  github.com/panjf2000/ants/v2.(*goWorker).run()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:48 +0xe9
  github.com/panjf2000/ants/v2.(*Pool).retrieveWorker.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:337 +0xed
  github.com/panjf2000/ants/v2.(*Pool).retrieveWorker()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:348 +0x286
  github.com/panjf2000/ants/v2.(*Pool).Submit()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/pool.go:222 +0x96
  github.com/panjf2000/ants/v2.Submit()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/ants.go:103 +0x56
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:213 +0x3ec
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).JoinRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:668 +0x5f7
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).ParallelRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:444 +0x2f0
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).RemoteRun()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:296 +0x11c
  github.com/matrixorigin/matrixone/pkg/sql/compile.(*Scope).MergeRun.func1()
      /home/runner/_work/matrixone/matrixone/head/pkg/sql/compile/scope.go:230 +0x31b
  github.com/panjf2000/ants/v2.(*goWorker).run.func1()
      /home/runner/go/pkg/mod/github.com/panjf2000/ants/v2@v2.7.4/worker.go:67 +0x1a5
==================

multi-cn-e2e-with-race-linux-x86-reports.zip

Expected Behavior

No response

Steps to Reproduce

run bvt with race-enabled mo

Additional information

No response

@sukki37 sukki37 added kind/bug Something isn't working severity/s0 Extreme impact: Cause the application to break down and seriously affect the use labels May 22, 2024
@matrix-meow matrix-meow added this to the 1.2.0 milestone May 22, 2024
@sukki37 sukki37 assigned qingxinhome and unassigned matrix-meow May 22, 2024
@qingxinhome
Copy link
Contributor

处理中....

@qingxinhome
Copy link
Contributor

main分支pr已经合并, 1.2-dev待合并

@qingxinhome
Copy link
Contributor

This feature has been implemented and verified through @sukki37 @aunjgr @aressu1985 @Ariznawlll @badboynt1 @daviszhen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working phase/testing resolved/v1.2.1 severity/s0 Extreme impact: Cause the application to break down and seriously affect the use
Projects
None yet
Development

No branches or pull requests

5 participants