Giter Club home page Giter Club logo

les-node-template's Introduction

les node template

Requirements

Getting started

Install node modules

yarn install

Start the api and web

yarn start

API are located at: http://localhost:3001/

Run the tests

yarn test

Configuration

EventStore

You can choose between: ges (Greg's EventStore) or memes (in-memory).

ges

You can configure the API to use EventStore.

Change the eventStore section of your config file to:

"eventStore": {
  "type": "ges",
  "endPoint": "tcp://localhost:1113",
  "credentials": {"username": "admin", "password": "changeit"}
}

Steps:

  • Download tar.gz archive from the website
  • Untar the archive (tar -zxvf thearchive.tar.gz) in the folder of your choice
  • CD into extracted subfolder (EventStore-OSS-XXX-vX.X.X)
  • Start the eventstore
    • ./run-node.sh --memdb --run-projections=all (start event store)
  • Web interface at http://localhost:2113
    • login: admin pass: changeit (defaults)

memes

You can configure the API to store events in memory.

Change the eventStore section of your config file to:

"eventStore": {
  "type": "memes"
}

Read model storage

You can choose between: memdb (In memory), LevelDB, Postgres

memdb

You can configure the API to store read models in memory.

Change the readModelStore value of your config file to:

"readModelStore": "memdb"

LevelDB

You can configure the API to store read models with LevelDB.

Change the readModelStore value and add leveldb section in your config file to:

"readModelStore": "leveldb",
"leveldb": {
  "dbDir": "/path/to/leveldb/storage/dir"
}

Postgres

You can configure the API to store read models with Postgres.

Change the readModelStore value and add postgres section in your config file to:

"readModelStore": "postgres",
"postgres": {
  "host": "localhost",
  "port": 5432,
  "database": "vanillacqrs",
  "user": "vanillacqrs",
  "password": "vanillacqrs"
}

les-node-template's People

Contributors

nicdex avatar robertreppel avatar

Watchers

 avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.