Skip to content

Commit

Permalink
Make client list function use the traffic-managers WatchWorkloads
Browse files Browse the repository at this point in the history
Let the `telepresence list` command use a workload collection that is
backed by the traffic-managers `WatchWorkloads` function.

The client will use local shared informers to watch the workloads when
connecting to an older traffic-manager that doesn't support the
`WatchWorkloads` call.

Signed-off-by: Thomas Hallgren <thomas@tada.se>
  • Loading branch information
thallgren committed Oct 28, 2024
1 parent 9d1d859 commit 5de70fa
Show file tree
Hide file tree
Showing 3 changed files with 256 additions and 426 deletions.
1 change: 0 additions & 1 deletion pkg/client/userd/trafficmgr/intercept.go
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,6 @@ func (s *session) ensureNoInterceptConflict(ir *rpc.CreateInterceptRequest) *rpc
// only if the returned rpc.InterceptResult is nil. The returned runtime.Object is either nil, indicating a local
// intercept, or the workload for the intercept.
func (s *session) CanIntercept(c context.Context, ir *rpc.CreateInterceptRequest) (userd.InterceptInfo, *rpc.InterceptResult) {
s.waitForSync(c)
spec := ir.Spec
if spec.Namespace == "" {
spec.Namespace = s.Namespace
Expand Down
Loading

0 comments on commit 5de70fa

Please sign in to comment.