Skip to content

Commit

Permalink
GUI BugFix => On mini, get EUS serviceInstance correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
EduJGURJC committed Apr 9, 2019
1 parent a20ba1f commit dc51074
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 7 deletions.
2 changes: 1 addition & 1 deletion elastest-torm-gui/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>io.elastest.etm</groupId>
<artifactId>elastest-torm-gui</artifactId>
<version>1.4.0</version>
<version>1.4.1</version>
<packaging>jar</packaging>
<build>
<plugins>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,11 @@
<etm-monitoring-view #logsAndMetrics [live]="true" [showConfigBtn]="false"></etm-monitoring-view>

<!-- TSS Services Instances -->
<div *ngIf="this.elastestMode && this.elastestMode === 'mini' && serviceInstances.length > 0; else tSServices">
<div *ngIf="this.elastestMode && this.elastestMode === 'mini' && serviceInstances.length > 0 && eusInstance; else tSServices">
<app-elastest-eus
[eusUrl]="serviceInstances[0].urls.api"
[eusHost]="serviceInstances[0].ip"
[eusPort]="serviceInstances[0].port"
[eusUrl]="eusInstance.urls.api"
[eusHost]="eusInstance.ip"
[eusPort]="eusInstance.port"
[standalone]="false"
[isNested]="true"
[abstractTJobExec]="tJobExec"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ export class LiveTjobExecManagerComponent implements OnInit, AfterViewInit, OnDe

serviceInstances: EsmServiceInstanceModel[] = [];
instancesNumber: number;
eusInstance: EsmServiceInstanceModel;

tJobExecMultiConfigs: ParameterModel[] = [];
tJobExecParameters: ParameterModel[] = [];
Expand Down Expand Up @@ -165,6 +166,7 @@ export class LiveTjobExecManagerComponent implements OnInit, AfterViewInit, OnDe
if (serviceInstances.length === this.instancesNumber || this.tJobExec.finished()) {
this.unsubscribeCheckTssInstances();
this.serviceInstances = [...serviceInstances];
this.searchForEUS();
}
},
(error: Error) => console.log(error),
Expand All @@ -173,6 +175,17 @@ export class LiveTjobExecManagerComponent implements OnInit, AfterViewInit, OnDe
}
}

searchForEUS(): void {
if (this.serviceInstances && this.serviceInstances.length > 0) {
for (let instance of this.serviceInstances) {
if (instance && instance.serviceName && instance.serviceName.toLowerCase() === 'eus') {
this.eusInstance = instance;
break;
}
}
}
}

unsubscribeCheckTssInstances(): void {
if (this.checkTSSInstancesSubscription !== undefined) {
this.checkTSSInstancesSubscription.unsubscribe();
Expand Down
2 changes: 1 addition & 1 deletion elastest-torm/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<groupId>io.elastest.etm</groupId>
<artifactId>elastest-torm</artifactId>
<packaging>jar</packaging>
<version>1.4.0</version>
<version>1.4.1</version>

<name>${project.groupId}:${project.artifactId}</name>
<description>This artifact contains the Elastest Torm project, part of the Elastest platform.</description>
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<groupId>io.elastest</groupId>
<artifactId>torm</artifactId>
<packaging>pom</packaging>
<version>1.4.0</version>
<version>1.4.1</version>

<name>${project.groupId}:${project.artifactId}</name>
<description>Test Orchestration and Recommendation Manager (TORM) reactor</description>
Expand Down

0 comments on commit dc51074

Please sign in to comment.