Skip to content

Commit

Permalink
feat(db): 支持带密码的es
Browse files Browse the repository at this point in the history
  • Loading branch information
jiawei397 committed Sep 10, 2021
1 parent fa6bb5c commit 6bf3ced
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { delay } from "../deps.ts";
import { limit } from "../src/utils/task.ts";

const client = new Client();
// await client.connect("http://elastic:pwd@localhost:9200/"); // with password
await client.connect("http://localhost:9200/");

const count = async () => {
Expand Down
2 changes: 2 additions & 0 deletions mod.ts
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
export { Client } from "./src/client.ts";

export const version = '0.0.8';
6 changes: 0 additions & 6 deletions src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ import { Ajax, ajax } from "./utils/ajax.ts";
import { serializer } from "./utils/serializer.ts";
import { generateId } from "./utils/tools.ts";

const VERSION = "0.0.8";

const type = "_doc";

class BaseClient {
Expand Down Expand Up @@ -73,10 +71,6 @@ class BaseClient {
this.#connectionCache.clear();
this.connectedCount = 0;
}

get version() {
return VERSION;
}
}

export class Client extends BaseClient {
Expand Down

0 comments on commit 6bf3ced

Please sign in to comment.