Skip to content

refactor: remove unused tsm rr fallback#1054

Merged
jranson merged 2 commits into
trickstercache:mainfrom
houyuwushang:refactor-tsm-nonmerge-fallback-1009
Jul 8, 2026
Merged

refactor: remove unused tsm rr fallback#1054
jranson merged 2 commits into
trickstercache:mainfrom
houyuwushang:refactor-tsm-nonmerge-fallback-1009

Conversation

@houyuwushang

@houyuwushang houyuwushang commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Description

Fixes #1009.

TSM was still constructing a round-robin fallback handler, but ServeHTTP no longer uses it. Non-merge paths, missing request resources, and the single-member fast path already dispatch directly to the first live pool target.

This removes the unused rr dependency, adds a test that pins the current non-merge fallback behavior, and documents that fallback in the ALB TSM docs.

Type of Change

    • Bug fix
    • New feature
    • Optimization
    • Test coverage
    • Documentation
    • Infrastructure

AI Disclosure

    • This contribution DOES NOT include AI-generated changes
    • This contribution DOES include AI-generated changes, and I have reviewed the relevant contributing guidelines.

Tests

  • go test ./pkg/backends/alb/mech/tsm -run 'Test(New|HandlerStopPool|TSMNonMergePathUsesFirstLiveMember|HandleResponseMerge)$' -count=1
  • go test ./pkg/backends/alb/mech/tsm -count=1
  • go test ./pkg/backends/alb/... -count=1
  • go tool golangci-lint run --timeout 5m ./pkg/backends/alb/mech/tsm
  • git diff --check (only local Windows autocrlf warnings)

Signed-off-by: houyuwushang <liuluoqianqiu@outlook.com>
@houyuwushang houyuwushang requested a review from a team as a code owner July 8, 2026 03:55
@jranson

jranson commented Jul 8, 2026

Copy link
Copy Markdown
Member

@houyuwushang in this change it would be good to describe the non-merge fallback behavior (dispatching to the first live pool target) in the ALB TSM Documentation. Otherwise, looks good.

Signed-off-by: houyuwushang <liuluoqianqiu@outlook.com>
@houyuwushang

houyuwushang commented Jul 8, 2026

Copy link
Copy Markdown
Contributor Author

Thanks, added that note to the TSM docs. The local TSM/ALB package tests still pass, and CI is green.

@jranson jranson merged commit e4d8aa1 into trickstercache:main Jul 8, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

tsm imports rr directly for its non-merge fallback -- investigate

2 participants