-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathBazClientService.ts
More file actions
25 lines (17 loc) · 814 Bytes
/
Copy pathBazClientService.ts
File metadata and controls
25 lines (17 loc) · 814 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import TYPES from "src/config/types";
import { inject } from "../../core/di";
import type ProtoService from "../base/ProtoService";
import type LoggerService from "../base/LoggerService";
export class BazClientService implements GRPC.IBazService {
private readonly protoService = inject<ProtoService>(TYPES.protoService);
private readonly loggerService = inject<LoggerService>(TYPES.loggerService);
private _bazClient: GRPC.IBazService = null as never;
Execute = async (...args: any) => {
this.loggerService.log("remote-grpc bazClientService Execute", { args });
return await this._bazClient.Execute(...args);
};
protected init = () => {
this._bazClient = this.protoService.makeClient<GRPC.IBazService>("BazService")
}
}
export default BazClientService;