X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=webapp%2Fsrc%2Fapp%2Fbuild%2Fbuild.component.ts;fp=webapp%2Fsrc%2Fapp%2Fbuild%2Fbuild.component.ts;h=a99a1fe64d7e2c03b8902a88cac2a52f50f2a078;hb=2c9ae6a5a27ae2f2e23495c613e7a53aed8e786c;hp=a1a965bfd1405e77e631b38a9b3953490299adb6;hpb=51da3506a296b7d5d4185b17364f188292136888;p=src%2Fxds%2Fxds-server.git diff --git a/webapp/src/app/build/build.component.ts b/webapp/src/app/build/build.component.ts index a1a965b..a99a1fe 100644 --- a/webapp/src/app/build/build.component.ts +++ b/webapp/src/app/build/build.component.ts @@ -8,6 +8,7 @@ import 'rxjs/add/operator/startWith'; import { XDSServerService, ICmdOutput } from "../common/xdsserver.service"; import { ConfigService, IConfig, IProject } from "../common/config.service"; import { AlertService, IAlert } from "../common/alert.service"; +import { SdkService } from "../common/sdk.service"; @Component({ selector: 'build', @@ -32,8 +33,11 @@ export class BuildComponent implements OnInit, AfterViewChecked { private startTime: Map = new Map(); // I initialize the app component. - constructor(private configSvr: ConfigService, private sdkSvr: XDSServerService, - private fb: FormBuilder, private alertSvr: AlertService + constructor(private configSvr: ConfigService, + private xdsSvr: XDSServerService, + private fb: FormBuilder, + private alertSvr: AlertService, + private sdkSvr: SdkService ) { this.cmdOutput = ""; this.confValid = false; @@ -54,12 +58,12 @@ export class BuildComponent implements OnInit, AfterViewChecked { }); // Command output data tunneling - this.sdkSvr.CmdOutput$.subscribe(data => { + this.xdsSvr.CmdOutput$.subscribe(data => { this.cmdOutput += data.stdout + "\n"; }); // Command exit - this.sdkSvr.CmdExit$.subscribe(exit => { + this.xdsSvr.CmdExit$.subscribe(exit => { if (this.startTime.has(exit.cmdID)) { this.cmdInfo = 'Last command duration: ' + this._computeTime(this.startTime.get(exit.cmdID)); this.startTime.delete(exit.cmdID); @@ -93,7 +97,9 @@ export class BuildComponent implements OnInit, AfterViewChecked { let t0 = performance.now(); this.cmdInfo = 'Start build of ' + prjID + ' at ' + t0; - this.sdkSvr.make(prjID, this.buildForm.value.subpath, args) + let sdkid = this.sdkSvr.getCurrentId(); + + this.xdsSvr.make(prjID, this.buildForm.value.subpath, args, sdkid) .subscribe(res => { this.startTime.set(String(res.cmdID), t0); },