mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
workspace: bump package version
This commit is contained in:
1 parent
bb288cb960
commit
c394378dba
22 files changed
+32
-42
No files matched your search
@@ -40,11 +40,15 @@ function getHandler(type: string, that: any) {
|
||||
};
|
||||
}
|
||||
|
||||
class SonicService extends Service {
|
||||
export class SonicService extends Service {
|
||||
public search: Search;
|
||||
public ingest: Ingest;
|
||||
public error = '';
|
||||
|
||||
constructor(ctx: Context) {
|
||||
super(ctx, 'sonic', true);
|
||||
}
|
||||
|
||||
async start() {
|
||||
const [host, port, auth] = SystemModel.getMany(['sonic.host', 'sonic.port', 'sonic.auth']);
|
||||
const cfg = {
|
||||
@@ -54,10 +58,6 @@ class SonicService extends Service {
|
||||
};
|
||||
this.search = new Search(cfg);
|
||||
this.ingest = new Ingest(cfg);
|
||||
await this.connect();
|
||||
}
|
||||
|
||||
async connect() {
|
||||
try {
|
||||
this.search.connect(getHandler('search', this));
|
||||
this.ingest.connect(getHandler('ingest', this));
|
||||
@@ -107,7 +107,3 @@ class SonicService extends Service {
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
export function apply() {
|
||||
Context.service('sonic', SonicService);
|
||||
}
|
||||
Reference in new issue
Block a user