mirror of
https://github.com/actions/runner.git
synced 2025-12-11 04:46:58 +00:00
Cleanup
This commit is contained in:
13
.vscode/launch.json
vendored
13
.vscode/launch.json
vendored
@@ -12,10 +12,7 @@
|
||||
],
|
||||
"cwd": "${workspaceFolder}/src",
|
||||
"console": "integratedTerminal",
|
||||
"requireExactSource": false,
|
||||
"env": {
|
||||
"USE_BROKER_FLOW": "1"
|
||||
}
|
||||
"requireExactSource": false
|
||||
},
|
||||
{
|
||||
"name": "Run",
|
||||
@@ -27,10 +24,7 @@
|
||||
],
|
||||
"cwd": "${workspaceFolder}/src",
|
||||
"console": "integratedTerminal",
|
||||
"requireExactSource": false,
|
||||
"env": {
|
||||
"USE_BROKER_FLOW": "1"
|
||||
}
|
||||
"requireExactSource": false
|
||||
},
|
||||
{
|
||||
"name": "Configure",
|
||||
@@ -60,4 +54,5 @@
|
||||
"requireExactSource": false
|
||||
},
|
||||
],
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -25,7 +25,6 @@ namespace GitHub.Runner.Listener
|
||||
private TaskAgentStatus runnerStatus = TaskAgentStatus.Online;
|
||||
private CancellationTokenSource _getMessagesTokenSource;
|
||||
private IBrokerServer _brokerServer;
|
||||
private string lastRunnerRequestId;
|
||||
|
||||
public override void Initialize(IHostContext hostContext)
|
||||
{
|
||||
@@ -80,20 +79,7 @@ namespace GitHub.Runner.Listener
|
||||
continue;
|
||||
}
|
||||
|
||||
if (MessageUtil.IsRunServiceJob(message.MessageType))
|
||||
{
|
||||
var messageRef = StringUtil.ConvertFromJson<RunnerJobRequestRef>(message.Body);
|
||||
|
||||
if (messageRef.RunnerRequestId != lastRunnerRequestId)
|
||||
{
|
||||
lastRunnerRequestId = messageRef.RunnerRequestId;
|
||||
return message;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return message;
|
||||
}
|
||||
return message;
|
||||
}
|
||||
catch (OperationCanceledException) when (_getMessagesTokenSource.Token.IsCancellationRequested && !token.IsCancellationRequested)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user