mirror of
https://github.com/actions/runner.git
synced 2025-12-10 12:36:23 +00:00
Compare commits
4 Commits
v2.292.0
...
releases/m
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f9ce10da6d | ||
|
|
c3649406e8 | ||
|
|
f954835f54 | ||
|
|
512cd2b4f8 |
@@ -1,20 +1,14 @@
|
||||
## Features
|
||||
|
||||
- Support the `--ephemeral` flag (#660)
|
||||
- This optional flag will configure the runner to only take one job, and let the service un-configure the runner after that job finishes.
|
||||
- Expect to see more info in the Github API documentation soon. We'll link to those docs directly as they become generally available!
|
||||
N/A
|
||||
|
||||
## Bugs
|
||||
|
||||
- Fix a bug in `script/delete` wherein a repo with multiple runners would be unable to find the correct runner (#1268) (#1269)
|
||||
- Mitigate a race condition when requesting an OIDC `Id_token` (#1320)
|
||||
- Make client retries more resilient in JobServer (#1316)
|
||||
- Revert "More resilient VssConnection client retries in JobServer" (#1343)
|
||||
|
||||
## Misc
|
||||
|
||||
- Increase readability of colored console output (#1295) (#1319)
|
||||
- Add more network troubleshooting to the docs (#1325)
|
||||
- Bump [path-parse](https://github.com/jbgutierrez/path-parse) from 1.0.6 to 1.0.7 (#1256)
|
||||
N/A
|
||||
|
||||
## Windows x64
|
||||
We recommend configuring the runner in a root folder of the Windows drive (e.g. "C:\actions-runner"). This will help avoid issues related to service identity folder permissions and long file path restrictions on Windows.
|
||||
|
||||
@@ -1 +1 @@
|
||||
<Update to ./src/runnerversion when creating release>
|
||||
2.282.1
|
||||
|
||||
@@ -2,19 +2,16 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Net.Http;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using GitHub.Runner.Sdk;
|
||||
using GitHub.Services.WebApi;
|
||||
using GitHub.Services.Common;
|
||||
|
||||
namespace GitHub.Runner.Common
|
||||
{
|
||||
[ServiceLocator(Default = typeof(JobServer))]
|
||||
public interface IJobServer : IRunnerService
|
||||
{
|
||||
Task ConnectAsync(Uri jobServerUrl, VssCredentials jobServerCredential, DelegatingHandler[] delegatingHandler = null);
|
||||
Task ConnectAsync(VssConnection jobConnection);
|
||||
|
||||
// logging and console
|
||||
Task<TaskLog> AppendLogContentAsync(Guid scopeIdentifier, string hubName, Guid planId, int logId, Stream uploadStream, CancellationToken cancellationToken);
|
||||
@@ -35,21 +32,20 @@ namespace GitHub.Runner.Common
|
||||
private VssConnection _connection;
|
||||
private TaskHttpClient _taskClient;
|
||||
|
||||
public async Task ConnectAsync(Uri jobServerUrl, VssCredentials jobServerCredential, DelegatingHandler[] delegatingHandler = null)
|
||||
public async Task ConnectAsync(VssConnection jobConnection)
|
||||
{
|
||||
Trace.Info($"Establishing connection for JobServer");
|
||||
_connection = jobConnection;
|
||||
int attemptCount = 5;
|
||||
|
||||
while (attemptCount-- > 0)
|
||||
while (!_connection.HasAuthenticated && attemptCount-- > 0)
|
||||
{
|
||||
try
|
||||
{
|
||||
await RefreshConnectionAsync(jobServerUrl, jobServerCredential, delegatingHandler);
|
||||
await _connection.ConnectAsync();
|
||||
break;
|
||||
}
|
||||
catch (Exception ex) when (attemptCount > 0)
|
||||
{
|
||||
Trace.Info($"Catch exception during connect. {attemptCount} attempts left.");
|
||||
Trace.Info($"Catch exception during connect. {attemptCount} attemp left.");
|
||||
Trace.Error(ex);
|
||||
}
|
||||
|
||||
@@ -57,15 +53,6 @@ namespace GitHub.Runner.Common
|
||||
}
|
||||
|
||||
_taskClient = _connection.GetClient<TaskHttpClient>();
|
||||
}
|
||||
|
||||
private async Task RefreshConnectionAsync(Uri jobServerUrl, VssCredentials jobServerCredential, DelegatingHandler[] delegatingHandler)
|
||||
{
|
||||
Trace.Info($"Refresh JobServer VssConnection to get on a different AFD node.");
|
||||
_hasConnection = false;
|
||||
_connection?.Dispose();
|
||||
_connection = VssUtil.CreateConnection(jobServerUrl, jobServerCredential, delegatingHandler);
|
||||
await _connection.ConnectAsync();
|
||||
_hasConnection = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -510,8 +510,9 @@ namespace GitHub.Runner.Listener
|
||||
|
||||
var jobServer = HostContext.GetService<IJobServer>();
|
||||
VssCredentials jobServerCredential = VssUtil.GetVssCredential(systemConnection);
|
||||
VssConnection jobConnection = VssUtil.CreateConnection(systemConnection.Url, jobServerCredential);
|
||||
await jobServer.ConnectAsync(jobConnection);
|
||||
|
||||
await jobServer.ConnectAsync(systemConnection.Url, jobServerCredential);
|
||||
await LogWorkerProcessUnhandledException(jobServer, message, detailInfo);
|
||||
|
||||
// Go ahead to finish the job with result 'Failed' if the STDERR from worker is System.IO.IOException, since it typically means we are running out of disk space.
|
||||
@@ -790,8 +791,9 @@ namespace GitHub.Runner.Listener
|
||||
|
||||
var jobServer = HostContext.GetService<IJobServer>();
|
||||
VssCredentials jobServerCredential = VssUtil.GetVssCredential(systemConnection);
|
||||
VssConnection jobConnection = VssUtil.CreateConnection(systemConnection.Url, jobServerCredential);
|
||||
|
||||
await jobServer.ConnectAsync(systemConnection.Url, jobServerCredential);
|
||||
await jobServer.ConnectAsync(jobConnection);
|
||||
|
||||
var timeline = await jobServer.GetTimelineAsync(message.Plan.ScopeIdentifier, message.Plan.PlanType, message.Plan.PlanId, message.Timeline.Id, CancellationToken.None);
|
||||
|
||||
|
||||
@@ -48,8 +48,8 @@ namespace GitHub.Runner.Worker
|
||||
Trace.Info($"Creating job server with URL: {jobServerUrl}");
|
||||
// jobServerQueue is the throttling reporter.
|
||||
_jobServerQueue = HostContext.GetService<IJobServerQueue>();
|
||||
|
||||
await jobServer.ConnectAsync(jobServerUrl, jobServerCredential, new DelegatingHandler[] { new ThrottlingReportHandler(_jobServerQueue) });
|
||||
VssConnection jobConnection = VssUtil.CreateConnection(jobServerUrl, jobServerCredential, new DelegatingHandler[] { new ThrottlingReportHandler(_jobServerQueue) });
|
||||
await jobServer.ConnectAsync(jobConnection);
|
||||
|
||||
_jobServerQueue.Start(message);
|
||||
HostContext.WritePerfCounter($"WorkerJobServerQueueStarted_{message.RequestId.ToString()}");
|
||||
|
||||
@@ -1 +1 @@
|
||||
2.282.0
|
||||
2.282.1
|
||||
|
||||
Reference in New Issue
Block a user