elasticsearch-adapter
A library that implements the Read Model Adapter interface for storing projections on AWS ElasticSearch.

Methods

build

build({ entityName }, { endpoint )
builds a read-model adapter

Parameters

attribute
type
description
entityName
string
the name of the entity
endpoint
string
the ElasticSearch instance endpoint url

Returns

an object with read model methods

Example

adapter.js
1
const elasticAdapterBuilder = require('serverless-cqrs.elasticsearch-adapter')
2
module.exports = elasticAdapterBuilder.build({
3
entityName: 'todo'
4
}, {
5
endpoint: 'https://xxxxxx.yyy/zzzz/1234',
6
})
Copied!
Last modified 2yr ago
Copy link