mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-11-12 23:09:33 +01:00
s3api: fix TestRoutedMultipartFinalize flake from a reused fake filer port (#12571)
* s3api: drop cached gRPC channels when a fake filer takes a port A test that dials a dead owner leaves its failed channel in the process-wide gRPC connection cache. When a later test's fake filer is given the same port, its first RPC fails at once with the cached connection refused, which is how TestRoutedMultipartFinalize failed on the 32-bit job. The fake filer helpers now share fakeFilerAddress, which invalidates any cached channel for the new address. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * s3api: test a fake filer on a dead owner's reused port Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * s3api: drop cached channels for dead test filer addresses too closedFilerAddress can be handed a port whose cached channel belonged to a fake filer that just stopped and may still look ready; then the dead owner's transaction is sent on it instead of failing over. Build its address with fakeFilerAddress as well. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
6c1eec8703
commit
a0f95e16bc
3 files changed
+49
-8
No files matched your search
@@ -537,8 +537,7 @@ func startFakeCacheFiler(t *testing.T, impl *fakeCacheFiler) pb.ServerAddress {
|
||||
filer_pb.RegisterSeaweedFilerServer(srv, impl)
|
||||
go srv.Serve(lis)
|
||||
t.Cleanup(srv.Stop)
|
||||
port := lis.Addr().(*net.TCPAddr).Port
|
||||
return pb.ServerAddress(fmt.Sprintf("127.0.0.1:1.%d", port))
|
||||
return fakeFilerAddress(lis)
|
||||
}
|
||||
|
||||
func newRemoteCacheTestServer(filerAddr pb.ServerAddress) *S3ApiServer {
|
||||
|
||||
Reference in new issue
Block a user