KEMBAR78
Throw NonRetryableException on GetNextMessage from broker as needed. by TingluoHuang · Pull Request #2828 · actions/runner · GitHub
Skip to content

Conversation

@TingluoHuang
Copy link
Member

@TingluoHuang TingluoHuang commented Sep 5, 2023

The runner exit itself as expected instead of a infinite restart loop.

@TingluoHuang ➜ /workspaces/actions/runner/_layout $ ./run.sh 
Current runner version: '2.308.0'
2023-09-05 18:10:10Z: Listening for Jobs
2023-09-05 18:10:56Z: Runner connect error: Failed to get job message: Error: Not Found. Retrying until reconnected.
An error occurred: Get next message failed with non-retryable error.
Runner listener exit with terminated error, stop the service, no retry needed.
Exiting runner...

@TingluoHuang TingluoHuang requested a review from a team as a code owner September 5, 2023 20:59
if (!IsGetNextMessageExceptionRetriable(ex))
{
throw;
throw new NonRetryableException("Get next message failed with non-retryable error.", ex);
Copy link
Member Author

Choose a reason for hiding this comment

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

We didn't do this with the other Listener since we are preventing the loop during CreateSeesion.

Since the broker listener doesn't really have a concept for create session, i need to break out the loop at here for now.

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