Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore: remove ssh background config#97

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
fioan89 merged 2 commits intomainfromremove-bg-ssh-config
Apr 28, 2025
Merged

Conversation

fioan89
Copy link
Collaborator

From my testing, Toolbox forwards through SSH (i.e. through Coder) a remote port associated with the IDE
running in server mode, to localhost in order for the server (i.e. the remote IDE) to communicate with
JBClient. Unlike with Gateway, Toolbox manages to reuse the SSH connection, and it doesn't open a separate
one for port forwarding.

From Gateway we inherited two ssh hostnames per each workspace, one for background connections that did not
involve running IDEs. Coder discards the bg. connection from the collected metrics in order to
avoid double counting. Since Toolbox manages to re-use the connection we don't need to worry
about double counting.

For this particular change, I deployed the latest Coder version with prometheus metrics and experiments
enabled (i.e. --prometheus-enable --prometheus-collect-agent-stats --experiments=workspace-usage) and made the following experiment:

  1. Opened up Toolbox, logged into Coder. At this point:
  • agent_sessions_total and coderd_agentstats_session_count_jetbrains were missing from prometheus metrics
  • jetbrains session count from api/v2/deployment/stats showed 0
  1. Opened up a Workspace at which point Toolbox established the SSH connection:
  • agent_sessions_total and coderd_agentstats_session_count_jetbrains increased to 1
  • jetbrains session count from api/v2/deployment/stats increased to 1 as well
  1. Hit the install button on RustRover, everything stayed unchanged

  2. Open RustRover, nothing changes in the stats.

From my testing, Toolbox forwards through SSH (i.e. through Coder) a remote port associated with the IDErunning in server mode, to localhost in order for the server (i.e. the remote IDE) to communicate withJBClient. Unlike with Gateway, Toolbox manages to reuse the SSH connection, and it doesn't open a separateone for port forwarding.From Gateway we inherited two ssh hostnames per each workspace, one for background connections that did notinvolve running IDEs. Coder discards the bg. connection from the collected metrics in order toavoid double counting. Since Toolbox manages to re-use the connection we don't need to worryabout double counting.For this particular change, I deployed the latest Coder version with prometheus metrics and experimentsenabled (i.e. --prometheus-enable --prometheus-collect-agent-stats --experiments=workspace-usage) and made the following experiment:1. Opened up Toolbox, logged into Coder. At this point:- agent_sessions_total and coderd_agentstats_session_count_jetbrains were missing from prometheus metrics- jetbrains session count from api/v2/deployment/stats showed 02. Opened up a Workspace at which point Toolbox established the SSH connection:- agent_sessions_total and coderd_agentstats_session_count_jetbrains increased to 1- jetbrains session count from api/v2/deployment/stats increased to 1 as well3. Hit the install button on RustRover, everything stayed unchanged4. Open RustRover, nothing changes in the stats.
Copy link
Member

@code-ashercode-asher left a comment
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Great news on Toolbox using a single connection!

I tried running Toolbox 2.6.1 on my Windows VM (for some reason I cannot seem to get it running on Linux) but I keep getting "exit code: 7" and blank stderr, so I have not been able to test, but the code change looks good to me.

@fioan89
Copy link
CollaboratorAuthor

I'll have to get my hands on Windows machine/VM, honestly I only tested on macOS.

@fioan89fioan89 mentioned this pull requestApr 28, 2025
@fioan89fioan89 merged commit970f4c5 intomainApr 28, 2025
5 checks passed
@fioan89fioan89 deleted the remove-bg-ssh-config branchApril 28, 2025 21:46
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@code-ashercode-ashercode-asher approved these changes

@matifalimatifaliAwaiting requested review from matifali

@f0sself0sselAwaiting requested review from f0ssel

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@fioan89@code-asher

[8]ページ先頭

©2009-2025 Movatter.jp