feat: Initial Code Task Runners support (no-changelog) (#10698)

Co-authored-by: Iván Ovejero <ivov.src@gmail.com>
Co-authored-by: Tomi Turtiainen <10324676+tomi@users.noreply.github.com>
This commit is contained in:
Val
2024-10-02 09:31:56 +01:00
committed by GitHub
parent bdaadf10e0
commit 27d83e0d91
39 changed files with 3763 additions and 234 deletions

View File

@@ -31,6 +31,7 @@ import { isApiEnabled, loadPublicApiVersions } from '@/public-api';
import { setupPushServer, setupPushHandler, Push } from '@/push';
import type { APIRequest } from '@/requests';
import * as ResponseHelper from '@/response-helper';
import { setupRunnerServer, setupRunnerHandler } from '@/runners/runner-ws-server';
import type { FrontendService } from '@/services/frontend.service';
import { OrchestrationService } from '@/services/orchestration.service';
@@ -201,6 +202,10 @@ export class Server extends AbstractServer {
const { restEndpoint, app } = this;
setupPushHandler(restEndpoint, app);
if (!this.globalConfig.taskRunners.disabled) {
setupRunnerHandler(restEndpoint, app);
}
const push = Container.get(Push);
if (push.isBidirectional) {
const { CollaborationService } = await import('@/collaboration/collaboration.service');
@@ -400,4 +405,9 @@ export class Server extends AbstractServer {
const { restEndpoint, server, app } = this;
setupPushServer(restEndpoint, server, app);
}
protected setupRunnerServer(): void {
const { restEndpoint, server, app } = this;
setupRunnerServer(restEndpoint, server, app);
}
}