eggjs-elasticsearch
TypeScript icon, indicating that this package has built-in type declarations

0.0.6 • Public • Published

eggjs-elasticsearch

Version Downloads

eggjs elasticsearch plugin use elasticsearch@8

install

npm install eggjs-elasticsearch

eggjs plugin config

plugin.js

{
  elasticsearch: {
    enable: true,
    package: "eggjs-elasticsearch"
  }
}

plugin config

config.default.ts single client

{
 elasticsearch: {
  client: {
    node: "http://localhost:9200"
  }
 }
}

config.default.ts multi clients

{
 elasticsearch: {
  clients: {
    foo: {
      node: "http://localhost:9200"
    },
    bar: {
      node: "http://localhost:9201"
    }
  }
 }
}

more options see @elastic/elasticsearch

learn how to use elasticsearch client

https://www.elastic.co/guide/en/elasticsearch/client/javascript-api/current/index.html

Readme

Keywords

Package Sidebar

Install

npm i eggjs-elasticsearch

Weekly Downloads

31

Version

0.0.6

License

MIT

Unpacked Size

6.64 kB

Total Files

13

Last publish

Collaborators

  • beace