-
Notifications
You must be signed in to change notification settings - Fork 686
Add support for multiple Unix domain socket connections to enable aspire log
command
#11188
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: davidfowl <[email protected]>
Co-authored-by: davidfowl <[email protected]>
Co-authored-by: davidfowl <[email protected]>
aspire log <resource-name>
CLI command for resource log streaming
@copilot The apphost needs to support multiple unix domain socket connections to the same apphost based on a stable backchannel name |
…lService Co-authored-by: davidfowl <[email protected]>
I've modified the BackchannelService to support multiple Unix domain socket connections. The service now accepts connections in a loop, handling each one in a separate background task while maintaining the same AppHostRpcTarget instance. This allows the main |
…s work Co-authored-by: davidfowl <[email protected]>
aspire log <resource-name>
CLI command for resource log streamingaspire log
command
🚀 Dogfood this PR with: curl -fsSL https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 11188 Or
iex "& { $(irm https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 11188" |
This PR modifies the BackchannelService to support multiple Unix domain socket connections, enabling the new
aspire log <resource-name>
CLI command to work alongside a runningaspire run
session.Problem
The original implementation only accepted a single connection to the backchannel Unix domain socket. This meant that when
aspire run
was active and connected, transient commands likeaspire log
could not establish their own connection to retrieve logs.Solution
Modified the BackchannelService to:
aspire run
behaviorKey Changes
Usage
The
aspire run
session remains active whileaspire log
connects, retrieves logs, and disconnects without disrupting the main session.Backward Compatibility
All existing functionality remains unchanged. The socket path generation and first connection behavior are preserved, ensuring compatibility with existing
aspire run
workflows.This pull request was created as a result of the following prompt from Copilot chat.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.