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

TestGetTSOImmediately is unstable #6761

Closed
lhy1024 opened this issue Jul 5, 2023 · 1 comment · Fixed by #6767
Closed

TestGetTSOImmediately is unstable #6761

lhy1024 opened this issue Jul 5, 2023 · 1 comment · Fixed by #6767
Labels
type/ci The issue is related to CI.

Comments

@lhy1024
Copy link
Contributor

lhy1024 commented Jul 5, 2023

Flaky Test

Which jobs are failing

2023-07-05T10:46:38.9667482Z     keyspace_group_manager_test.go:744: 
2023-07-05T10:46:38.9667990Z         	Error Trace:	/home/runner/work/pd/pd/tests/integrations/mcs/tso/keyspace_group_manager_test.go:744
2023-07-05T10:46:38.9668660Z         	            				/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/asm_amd64.s:1598
2023-07-05T10:46:38.9668912Z         	Error:      	Received unexpected error:
2023-07-05T10:46:38.9669363Z         	            	primary of keyspace group does not exist
2023-07-05T10:46:38.9669779Z         	            	github.com/tikv/pd/pkg/keyspace.init
2023-07-05T10:46:38.9670451Z         	            		/home/runner/work/pd/pd/pkg/keyspace/util.go:99
2023-07-05T10:46:38.9670701Z         	            	runtime.doInit
2023-07-05T10:46:38.9671376Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/proc.go:6506
2023-07-05T10:46:38.9672047Z         	            	runtime.doInit
2023-07-05T10:46:38.9673325Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/proc.go:6483
2023-07-05T10:46:38.9673629Z         	            	runtime.doInit
2023-07-05T10:46:38.9674388Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/proc.go:6483
2023-07-05T10:46:38.9674679Z         	            	runtime.doInit
2023-07-05T10:46:38.9675580Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/proc.go:6483
2023-07-05T10:46:38.9675938Z         	            	runtime.doInit
2023-07-05T10:46:38.9677071Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/proc.go:6483
2023-07-05T10:46:38.9677332Z         	            	runtime.doInit
2023-07-05T10:46:38.9678012Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/proc.go:6483
2023-07-05T10:46:38.9678276Z         	            	runtime.doInit
2023-07-05T10:46:38.9679131Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/proc.go:6483
2023-07-05T10:46:38.9679492Z         	            	runtime.main
2023-07-05T10:46:38.9680180Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/proc.go:233
2023-07-05T10:46:38.9680538Z         	            	runtime.goexit
2023-07-05T10:46:38.9681180Z         	            		/opt/hostedtoolcache/go/1.20.1/x64/src/runtime/asm_amd64.s:1598
2023-07-05T10:46:38.9681415Z         	Test:       	TestGetTSOImmediately

CI link

https://github.com/tikv/pd/actions/runs/5463258824/jobs/9943718192

Reason for failure (if possible)

Anything else

@lhy1024 lhy1024 added the type/ci The issue is related to CI. label Jul 5, 2023
@lhy1024
Copy link
Contributor Author

lhy1024 commented Jul 5, 2023

	testutil.Eventually(re, func() bool {
		p0, err := kgm.GetKeyspaceGroupPrimaryByID(0)
		re.NoError(err)
		p1, err := kgm.GetKeyspaceGroupPrimaryByID(1)
		re.NoError(err)
		return p0 == kg0.Members[0].Address && p1 == kg1.Members[1].Address
	}, testutil.WithWaitFor(5*time.Second), testutil.WithTickInterval(50*time.Millisecond))

Maybe we can skip error check for kgm.GetKeyspaceGroupPrimaryByID(1) in testutil.Eventually

@ti-chi-bot ti-chi-bot bot closed this as completed in #6767 Jul 6, 2023
ti-chi-bot bot pushed a commit that referenced this issue Jul 6, 2023
close #6761

Signed-off-by: Ryan Leung <[email protected]>
rleungx added a commit to rleungx/pd that referenced this issue Aug 2, 2023
rleungx added a commit to rleungx/pd that referenced this issue Aug 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/ci The issue is related to CI.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant