Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

ibetitsmike
Copy link
Contributor

@ibetitsmike ibetitsmike commented Aug 12, 2025

Added support for immortal streams to maintain persistent TCP connections to workspace services that automatically reconnect when interrupted.

What changed?

  • Implemented a new immortal streams feature that provides persistent TCP connections to workspace services
  • Created CLI commands for managing immortal streams (coder exp immortal-stream list/delete)
  • Added support for using immortal streams with SSH and port forwarding connections
  • Implemented server-side API endpoints for creating, listing, and deleting immortal streams
  • Added fallback mechanism to regular connections when immortal streams are unavailable

How to test?

  1. Use the experimental CLI commands to manage immortal streams:

    coder exp immortal-stream list <workspace-name>
    coder exp immortal-stream delete <workspace-name> <stream-name>
    
  2. Test SSH with immortal streams:

    coder ssh --immortal <workspace-name>
    
  3. Test port forwarding with immortal streams:

    coder port-forward --immortal <workspace-name> <local-port>:<remote-port>
    
  4. Verify automatic reconnection by temporarily disrupting the network connection

Why make this change?

Immortal streams provide a more resilient connection mechanism for workspace services, automatically reconnecting when network interruptions occur. This improves the user experience by maintaining persistent connections to SSH and port-forwarded services, reducing the need for manual reconnection and preventing session loss during temporary network issues.

Copy link
Contributor Author

ibetitsmike commented Aug 12, 2025

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch 3 times, most recently from 9099850 to 992740a Compare August 13, 2025 14:52
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch 2 times, most recently from 2fbfcb1 to b4276f8 Compare August 15, 2025 00:51
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch 2 times, most recently from 59b4c90 to 32b88ff Compare August 15, 2025 08:48
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from b4276f8 to 42450ba Compare August 15, 2025 08:48
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 32b88ff to 405d3d1 Compare August 16, 2025 11:06
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch 2 times, most recently from 0b6e27e to 9bcaa2f Compare August 19, 2025 06:52
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 405d3d1 to 5f740d4 Compare August 19, 2025 06:52
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from 9bcaa2f to e256a4a Compare August 19, 2025 12:01
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 5f740d4 to 9a3fc9f Compare August 19, 2025 12:01
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from e256a4a to 5c50940 Compare August 20, 2025 11:42
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 9a3fc9f to e73338d Compare August 20, 2025 11:42
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from 5c50940 to c0cba16 Compare August 20, 2025 12:38
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch 2 times, most recently from 4996ebe to 5ed4b5d Compare August 20, 2025 13:17
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from 57b8912 to fd99a7f Compare August 25, 2025 20:32
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 5ed4b5d to 5e5d5b5 Compare August 25, 2025 20:32
@github-actions github-actions bot added the stale This issue is like stale bread. label Sep 2, 2025
@github-actions github-actions bot closed this Sep 5, 2025
@ibetitsmike ibetitsmike reopened this Sep 8, 2025
@ibetitsmike ibetitsmike removed the stale This issue is like stale bread. label Sep 8, 2025
@ibetitsmike ibetitsmike changed the title chore: added support for immortal streams to cli and agent chore: add support for immortal streams to cli and agent Sep 8, 2025
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 5e5d5b5 to 1aab8a9 Compare September 8, 2025 08:42
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from fd99a7f to 4c46fea Compare September 8, 2025 08:42
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 1aab8a9 to cbde135 Compare September 8, 2025 08:54
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from 4c46fea to e81618b Compare September 8, 2025 08:54
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from cbde135 to 9f2715f Compare September 8, 2025 09:18
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from e81618b to 0f58377 Compare September 8, 2025 09:18
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 9f2715f to 34a68fe Compare September 8, 2025 10:01
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from 0f58377 to 2173bc4 Compare September 8, 2025 10:01
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch 2 times, most recently from 75f3712 to 947c75e Compare September 8, 2025 10:37
@ibetitsmike ibetitsmike marked this pull request as ready for review September 8, 2025 10:58
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 387f151 to 72aa4cf Compare September 9, 2025 11:01
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from c00f439 to dafdb32 Compare September 12, 2025 12:55
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 72aa4cf to 8d68a4f Compare September 12, 2025 12:55
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-agent-api branch from dafdb32 to be330a4 Compare September 12, 2025 12:59
@ibetitsmike ibetitsmike force-pushed the mike/immortal-streams-cli branch from 8d68a4f to 0a3a1b6 Compare September 12, 2025 12:59
@ibetitsmike ibetitsmike changed the title chore: add support for immortal streams to cli and agent feat: add support for immortal streams to cli and agent Sep 12, 2025
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.

1 participant