From 4c04ca51321d4d112fa7e2c45a444e9dd65e786b Mon Sep 17 00:00:00 2001 From: crusader Date: Wed, 5 Sep 2018 15:56:04 +0900 Subject: [PATCH] ing --- package.json | 2 +- src/commons/service/probe.service.ts | 11 ++++++++++- yarn.lock | 6 +++--- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 0429418..a0a8433 100644 --- a/package.json +++ b/package.json @@ -39,7 +39,7 @@ "@ngrx/schematics": "^6.1.0", "@ngrx/store": "^6.1.0", "@ngrx/store-devtools": "^6.1.0", - "@overflow/rpc-js": "0.0.4", + "@overflow/rpc-js": "0.0.5", "@types/fs-extra": "^5.0.4", "@types/jasmine": "~2.8.6", "@types/jasminewd2": "~2.0.3", diff --git a/src/commons/service/probe.service.ts b/src/commons/service/probe.service.ts index 3c0dc98..5fca86e 100644 --- a/src/commons/service/probe.service.ts +++ b/src/commons/service/probe.service.ts @@ -24,6 +24,9 @@ export class ProbeService extends Client { public constructor() { super(codec, rwc); + + this.connect(); + this.notiSubscription = this.notification() .subscribe((notiCodec: ClientNotificationCodec) => { console.log(notiCodec.method()); @@ -35,6 +38,12 @@ export class ProbeService extends Client { }); } }); - + this.connectionStatus().subscribe(isConnected => { + if (!isConnected) { + console.log('disconnected'); + } else { + console.log('connected'); + } + }); } } diff --git a/yarn.lock b/yarn.lock index fe7dc26..524f427 100644 --- a/yarn.lock +++ b/yarn.lock @@ -224,9 +224,9 @@ tree-kill "^1.0.0" webpack-sources "^1.1.0" -"@overflow/rpc-js@0.0.4": - version "0.0.4" - resolved "https://nexus.loafle.net/repository/npm-all/@overflow/rpc-js/-/rpc-js-0.0.4.tgz#0d0fe3919551ab60b784825f612290c6003148c7" +"@overflow/rpc-js@0.0.5": + version "0.0.5" + resolved "https://nexus.loafle.net/repository/npm-all/@overflow/rpc-js/-/rpc-js-0.0.5.tgz#9b406d90a7b034cbd679985c1f7a117d17a8983e" "@schematics/angular@0.7.3": version "0.7.3"