webapi-eca/README.md
Dominic Bosch 8c115aa71d What a wonderful detour over docco, only to recognize that it was always possible to auto generate documentation.
... if one would just define the correct folder...
at least deep knowledge about docco now, plus that it doesn't use glob (leaves it a user task...) while groc does use glob to resolve file paths, yay!
2013-11-20 15:41:41 +01:00

2.1 KiB

README: webapi-eca

A Modular ECA Engine Server which acts as a middleware between WebAPI's. This folder continues examples of an ECA engine and how certain use cases could be implemented together with a rules language. Be sure the user which runs the server doesn't have ANY write rights on the server! Malicious modules could capture or destroy your server!

The server is started through the rules_server.js module by calling node rule_server.js.

Getting started

Prerequisites:

  • node.js & npm (find it here)

  • (optional) coffee, if you want to compile from coffee sources:

    sudo npm -g install coffee-script

Clone project:

    git clone https://github.com/dominicbosch/webapi-eca.git

Download and install dependencies:

cd webapi-eca
npm install

Get your redis instance up and running (and find the port for the config file below) or create your own js/db_interface.js.

Edit the configuration file:

vi config/config.json

Apply your settings, for example:

{
    "http_port": 8125,
    "db_port": 6379,
    "crypto_key": "[your key]",
    "session_secret": "[your secret]"
}

Start the server:

node js/server

Congratulations, your own WebAPI based ECA engine server is now up and running!

Optional command line tools:

Run test suite:

node run_tests

Create the doc (to be accessed via the webserver, e.g.: localhost:8125/doc/):

node create_doc

_

TODO

  • Redis queue
  • user handling (personal credentials)
  • security in terms of users (private key, login)
  • vm for modules, only give few libraries (no fs!)
  • rules generator (provide webpage that is used to create rules dependent on the existing modues)
  • geo location module, test on smartphone.

_

TODO per module

Testing | clean documentation | Clean error handling (Especially in loading of modules and their credentials):

  • DB Interface
  • Engine
  • Event Poller
  • HTTP Listener
  • Logging
  • Module Loader
  • Module Manager
  • Server