1.0.1 • Published 7 years ago
oodebe-gateway v1.0.1
OODEBE Gateway
A Proxy Gateway written in Node.js for OODEBE Engines.
Features
- Persistence engine alive checking
- Indexing engine alive checking
- Dynamic configuration allocation
- Dynamic Routing
Instance information in seperate API
How to use
var oodebe = require('oodebe-gateway'); // define configuration var mongoConfig = { "host": "localhost", "port": 27017, "database": "oodebe", "topic" : "oodebe_queue" } var elasticConfig = { "host": "localhost", "port": 9200, "database": "oodebe_elastic", "index_topic": "oodebe_queue", "indexers" : [{ "persistenceDatabase": "oodebe", "persistenceCollection": "website", "syncTo": { "indexDatabase": "oodebe_elastic", "indexType" : "website", "indexFields": ["firstName"] } }] }
// Engine host information var persistenceConfig = { "host": "localhost:3000" }
var indexerConfig = { "host": "localhost:5000" }
// setting the persistenc engine and indexer oodebe.setEngine('persistence',persistenceConfig,JSON.stringify(mongoConfig)); oodebe.setEngine('indexer',indexerConfig,JSON.stringify(elasticConfig));
// starting the server oodebe.start(2000);
## TODO
* Load balancing
* SSL Authentication
* Fail safe