Skip to content

bridge actor election and ttl - #354

Open
osleg wants to merge 1 commit into
zesty-co:mainfrom
osleg:0000-bridge-lease
Open

bridge actor election and ttl#354
osleg wants to merge 1 commit into
zesty-co:mainfrom
osleg:0000-bridge-lease

Conversation

@osleg

@osleg osleg commented Jul 16, 2026

Copy link
Copy Markdown

No description provided.

@Awish021

Copy link
Copy Markdown
Collaborator

are we doing leader-election for bridge? why?

@osleg

osleg commented Jul 16, 2026

Copy link
Copy Markdown
Author

are we doing leader-election for bridge? why?

Yeah after adding pprof Boris looked into it and figured that we might cause a leak with stale connections, leader required to prevent race conditions on clean-up only, it won't affect any other path

@Awish021

Copy link
Copy Markdown
Collaborator

I imagined the bridge being stateless. now it has "state" of a connection?
I even imagined it with HPA in the future to support spikes😆

@osleg

osleg commented Jul 16, 2026

Copy link
Copy Markdown
Author

Bad choice of words, but bridge, as stateless as it is, has a configmap of actors. Before pprof the list was stable. After pprof was added bridge got registrations from specific pods which made the configmap grow and keep stale actors on the list. So we need to clean the dead actors somehow.
On the bridge side I added a cleaner that does the job but since multiple bridges can run at the same time I needed an election to prevent multiple cleaner workers.

I bet we'll reach HPA too :P

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.

3 participants