Show new columns with result code etc.
Change-Id: If7d9b7a10b3702954455fb4055369caa189a0fdc
Issue-Id: RICPLT-954
Signed-off-by: Sarkar, Anand (as0481) <asarkar@research.att.com>
Signed-off-by: Lott, Christopher (cl778h) <cl778h@att.com>
RIC Dashboard Release Notes
===========================
-Version 1.0.2, 9 May 2019
--------------------------
+Version 1.0.2, 10 May 2019
+--------------------------
* Update A1 mediator client to version 0.4.0
* Add E2 response message with timestamp and status code
* Fetch xAPP instance status information from xAPP Manager and display in dashboard
+* Allow the user to initiate an E2 (X2) connection between RIC and gNB/eNB
Version 1.0.1, 6 May 2019
-------------------------
/.settings
/target/
/.mvn/wrapper/maven-wrapper.jar
+/.vscode
### STS ###
.apt_generated
}
},
"rxjs-compat": {
- "version": "6.4.0",
- "resolved": "https://registry.npmjs.org/rxjs-compat/-/rxjs-compat-6.4.0.tgz",
- "integrity": "sha512-eo/O8RS83hJdJukCtA+IF6qnqa8FPOuVo+OPCzgVi+dbTle9KCdNv97IcQO0WwNVik7DJLKmf0F8uwzc0q40vw=="
+ "version": "6.3.3",
+ "resolved": "https://registry.npmjs.org/rxjs-compat/-/rxjs-compat-6.3.3.tgz",
+ "integrity": "sha512-caGN7ixiabHpOofginKEquuHk7GgaCrC7UpUQ9ZqGp80tMc68msadOeP/2AKy2R4YJsT1+TX5GZCtxO82qWkyA=="
},
"safe-buffer": {
"version": "5.1.2",
"ng2-charts": "^1.6.0",
"ng2-completer": "^2.0.8",
"ng2-smart-table": "1.3.5",
- "rxjs": "~6.3.3",
- "rxjs-compat": "^6.4.0",
+ "rxjs": "6.3.3",
+ "rxjs-compat": "6.3.3",
"tslib": "^1.9.0",
"zone.js": "~0.8.26"
},
"ts-node": "~7.0.0",
"tslint": "~5.11.0",
"typescript": "~3.2.2"
+ },
+ "comments": {
+ "dependencies": {
+ "rxjs": "Its version needs to be same with rxjs-compat, otherwise apparently build is failing"
+ }
}
}
import { LoginComponent } from './login/login.component';
import { CatalogComponent } from './catalog/catalog.component';
import { ControlComponent } from './control/control.component';
+import { SignalComponent } from './signal/signal.component';
import { StatsComponent } from './stats/stats.component';
import { AdminComponent } from './admin/admin.component';
import { XappComponent } from './xapp/xapp.component';
{path: 'login', component: LoginComponent},
{path: 'catalog', component: CatalogComponent},
{path: 'control', component: ControlComponent},
+ {path: 'signal', component: SignalComponent},
{path: 'stats', component: StatsComponent},
{path: 'admin', component: AdminComponent},
{path: 'xapp', component: XappComponent},
// tslint:disable-next-line:max-line-length
import { MatIconModule, MatCardModule, MatListModule, MatSidenavModule,
MatButtonToggleModule, MatSliderModule, MatGridListModule, MatSlideToggleModule,
- MatExpansionModule, MatTabsModule } from '@angular/material';
+ MatExpansionModule, MatTabsModule, MatDialogModule, MatFormFieldModule, MatButtonModule, MatInputModule} from '@angular/material';
import { BrowserAnimationsModule} from '@angular/platform-browser/animations';
import { NgModule } from '@angular/core';
import { Ng2SmartTableModule } from 'ng2-smart-table';
import { AdminService} from './services/admin/admin.service';
import { CatalogService} from './services/catalog/catalog.service';
import { ControlService} from './services/control/control.service';
+import { SignalService} from './services/signal/signal.service';
import { SidenavListComponent } from './navigation/sidenav-list/sidenav-list.component';
import { ControlComponent } from './control/control.component';
+import { SignalComponent, AppRANConnectDialog} from './signal/signal.component';
import { StatsComponent } from './stats/stats.component';
import { AdminComponent } from './admin/admin.component';
import { CatalogCardComponent} from './ui/catalog-card/catalog-card.component';
import { ModalEventComponent } from './ui/modal-event/modal-event.component';
import { XappComponent } from './xapp/xapp.component';
import { ConfigEventComponent } from './ui/config-event/config-event.component';
-import { MatDialogModule } from '@angular/material';
+
@NgModule({
declarations: [
ControlCardComponent,
StatCardComponent,
ControlComponent,
+ SignalComponent,
StatsComponent,
AdminComponent,
ModalEventComponent,
XappComponent,
ConfigEventComponent,
AppCatalogDeployDialog,
+ AppRANConnectDialog
],
imports: [
BrowserModule,
ChartsModule,
AppRoutingModule,
FormsModule,
+ MatDialogModule,
ReactiveFormsModule,
MatButtonToggleModule,
MatExpansionModule,
MatSidenavModule,
MatSlideToggleModule,
MatTabsModule,
+ MatFormFieldModule,
+ MatButtonModule,
+ MatInputModule,
Ng2SmartTableModule,
MDBBootstrapModule.forRoot(),
],
exports: [
- MatDialogModule,
+ FormsModule,
+ MatDialogModule,
MatButtonToggleModule,
MatExpansionModule,
MatSliderModule,
MatSidenavModule,
MatSlideToggleModule,
MatTabsModule,
+ MatFormFieldModule,
+ MatButtonModule,
+ MatInputModule
],
entryComponents: [
AppCatalogDeployDialog,
+ AppRANConnectDialog
],
providers: [
UiService,
AdminService,
CatalogService,
ControlService,
+ SignalService
],
bootstrap: [AppComponent]
})
-export class AppModule { }
+export class AppModule { };
+
<a mat-list-item routerLink="/stats" (click)="onSidenavClose()">
<mat-icon>assessment</mat-icon> <span class="nav-caption">Stats</span>
</a>
+ <a mat-list-item routerLink="/signal" (click)="onSidenavClose()">
+ <mat-icon>cast_connected</mat-icon> <span class="nav-caption">RAN Connection</span>
+ </a>
<a mat-list-item routerLink="/admin" (click)="onSidenavClose()">
- <mat-icon>assignment_ind</mat-icon> <span class="nav-caption">Admin</span>
+ <mat-icon>assignment_ind</mat-icon> <span class="nav-caption">Admin</span>
</a>
</mat-nav-list>
--- /dev/null
+/*-
+ * ========================LICENSE_START=================================
+ * O-RAN-SC
+ * %%
+ * Copyright (C) 2019 AT&T Intellectual Property and Nokia
+ * %%
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ========================LICENSE_END===================================
+ */
+import { TestBed } from '@angular/core/testing';
+
+import { SignalService } from './signal.service';
+
+describe('CatalogService', () => {
+ beforeEach(() => TestBed.configureTestingModule({}));
+
+ it('should be created', () => {
+ const service: SignalService = TestBed.get(SignalService);
+ expect(service).toBeTruthy();
+ });
+});
--- /dev/null
+/*-
+ * ========================LICENSE_START=================================
+ * O-RAN-SC
+ * %%
+ * Copyright (C) 2019 AT&T Intellectual Property and Nokia
+ * %%
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ========================LICENSE_END===================================
+ */
+import { Injectable } from '@angular/core';
+import { HttpClient } from '@angular/common/http';
+import { Observable } from 'rxjs';
+
+@Injectable()
+export class SignalService {
+
+ constructor(private http: HttpClient) {
+ }
+
+ getAll() {
+ return this.http.get('api/e2mgr/setup');
+ }
+
+ x2Setup(req) {
+ return this.http.post('api/e2mgr/x2Setup', req);
+ }
+
+ endcSetup(req) {
+ return this.http.post('api/e2mgr/endcSetup', req);
+ }
+
+}
--- /dev/null
+/*-
+ * ========================LICENSE_START=================================
+ * O-RAN-SC
+ * %%
+ * Copyright (C) 2019 AT&T Intellectual Property and Nokia
+ * %%
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ========================LICENSE_END===================================
+ */
+.control__section {
+ position: relative;
+ top: -50px;
+}
+
+.control__header {
+ text-align: center;
+ color: #432c85;
+ font-size: 50px;
+ font-weight: 200;
+ letter-spacing: .1em;
+ transform: translate(149 56);
+}
+
+:host /deep/ ng2-smart-table tbody > tr > td{
+ text-align: left;
+}
+
+:host /deep/ ng2-smart-table thead th{
+ text-align: left;
+}
+
+/* used to place form fields on separate lines/rows in dialog */
+.input-display-block {
+ display: block;
+}
--- /dev/null
+<!--
+ ========================LICENSE_START=================================
+ O-RAN-SC
+ %%
+ Copyright (C) 2019 AT&T Intellectual Property and Nokia
+ %%
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ========================LICENSE_END===================================
+ -->
+<div class="control__section">
+ <h3 class="control__header">RAN Connection</h3>
+ <button mat-raised-button (click)="openRanConnectDialog()">Connect</button>
+ <ng2-smart-table [settings]="settings" [source]="source">
+ </ng2-smart-table>
+ <app-modal-event hidden></app-modal-event>
+</div>
--- /dev/null
+<!--
+ ========================LICENSE_START=================================
+ O-RAN-SC
+ %%
+ Copyright (C) 2019 AT&T Intellectual Property and Nokia
+ %%
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ========================LICENSE_END===================================
+ -->
+
+<div mat-dialog-title>
+ Setup RAN Connection
+</div>
+
+<div mat-dialog-content>
+ <mat-form-field class="input-display-block">
+ <input matInput placeholder="eNB/gNB Name" [(ngModel)]="data.ranName">
+ </mat-form-field>
+ <mat-form-field class="input-display-block">
+ <input matInput placeholder="IP" [(ngModel)]="data.ranIp">
+ </mat-form-field>
+ <mat-form-field class="input-display-block">
+ <input matInput placeholder="Port" [(ngModel)]="data.ranPort">
+ </mat-form-field>
+</div>
+
+ <div mat-dialog-actions class="modal-footer justify-content-center">
+ <button class="mat-raised-button" (click)="close()">Cancel</button>
+ <button class="mat-raised-button mat-primary" (click)="connectRAN()">Connect</button>
+</div>
--- /dev/null
+/*-
+ * ========================LICENSE_START=================================
+ * O-RAN-SC
+ * %%
+ * Copyright (C) 2019 AT&T Intellectual Property and Nokia
+ * %%
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ========================LICENSE_END===================================
+ */
+import { async, ComponentFixture, TestBed } from '@angular/core/testing';
+
+import { SignalComponent } from './signal.component';
+
+describe('SignalComponent', () => {
+ let component: SignalComponent;
+ let fixture: ComponentFixture<SignalComponent>;
+
+ beforeEach(async(() => {
+ TestBed.configureTestingModule({
+ declarations: [ SignalComponent ]
+ })
+ .compileComponents();
+ }));
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(SignalComponent);
+ component = fixture.componentInstance;
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+});
--- /dev/null
+/*-
+ * ========================LICENSE_START=================================
+ * O-RAN-SC
+ * %%
+ * Copyright (C) 2019 AT&T Intellectual Property and Nokia
+ * %%
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ========================LICENSE_END===================================
+ */
+import { Component, OnInit, Inject } from '@angular/core';
+import { LocalDataSource } from 'ng2-smart-table';
+import { SignalService } from '../services/signal/signal.service';
+import { Router } from '@angular/router';
+import { MatDialog, MatDialogConfig, MatDialogRef, MAT_DIALOG_DATA} from '@angular/material/dialog';
+import {MatFormFieldModule} from '@angular/material';
+import { FormGroup, FormControl, FormBuilder } from '@angular/forms';
+import { HttpClient } from '@angular/common/http';
+import { Observable } from 'rxjs/Rx';
+
+export interface DialogData {
+ ranName: string;
+ ranIp: number;
+ ranPort: number;
+}
+
+@Component({
+ selector: 'app-signal',
+ templateUrl: 'signal.component.html',
+ styleUrls: ['signal.component.css']
+})
+export class SignalComponent {
+
+ settings = {
+ hideSubHeader: true,
+ actions: {
+ columnTitle: 'Actions',
+ add: false,
+ edit: false,
+ delete: false,
+ position: 'right'
+ },
+ columns: {
+ requestType: {
+ title: 'Request Type',
+ type: 'string',
+ },
+ ranName: {
+ title: 'eNodeB/gNodeB Name',
+ type: 'string',
+ },
+ ranIp: {
+ title: 'IP',
+ type: 'number',
+ },
+ ranPort: {
+ title: 'Port',
+ type: 'number',
+ },
+ responseCode: {
+ title: 'Response',
+ type: 'number',
+ },
+ timeStamp: {
+ title: 'Time Stamp',
+ type: 'string',
+ }
+ }
+ };
+
+ source: LocalDataSource = new LocalDataSource();
+
+ ranName: string;
+
+ ranIp: number;
+
+ ranPort: number;
+
+ constructor(private service: SignalService, public dialog: MatDialog, private http: HttpClient) {
+ this.service.getAll().subscribe((val: any[]) => this.source.load(val));
+ }
+
+ openRanConnectDialog() {
+
+ const dialogRef = this.dialog.open(AppRANConnectDialog, {
+ width: '450px',
+ data: {ranName: this.ranName, ranIp: this.ranIp, ranPort: this.ranPort}
+ })
+
+ dialogRef.afterClosed().subscribe(result => {
+ this.service.getAll().subscribe((val: any[]) => this.source.load(val));
+ });
+
+ }
+}
+
+@Component({
+ selector: 'app-signal-ranconnect-dialog',
+ templateUrl: 'signal.component.ranconnect-dialog.html',
+ styleUrls: ['signal.component.css']
+})
+
+export class AppRANConnectDialog implements OnInit {
+
+ constructor(public dialogRef: MatDialogRef<AppRANConnectDialog>,
+ private service: SignalService,
+ @Inject(MAT_DIALOG_DATA) public data: DialogData) {
+ }
+
+ ngOnInit() {
+ }
+
+ close() {
+ this.dialogRef.close();
+ }
+
+ connectRAN(): void {
+ this.service.x2Setup(this.data).subscribe((val: any[]) => {});
+ this.dialogRef.close();
+ }
+
+}