0.1.0 • Published 8 years ago

volvox-restify v0.1.0

Weekly downloads
1
License
MIT
Repository
-
Last release
8 years ago

volvox-restify

npm.io npm.io

Restify.js provider for volvox.js Microservice framework

Build Status Coverage Status

Preview

Sample code Consul

import Volvox from 'volvox-core';
import vconsul from 'volvox-consul';
import vrestify from 'volvox-restify';

import restify from 'restify'

async function main() {
    let server = restify.createServer();
    server.get('/customers', (req, res, next) => {
        res.send({
            customerName: "Test customer",
            customerId: 666
        })
    })
    
    let volvox = new Volvox(vconsul(), vrestify());
    await volvox.bootstrap(server, "customers", "v1");
}

main();
0.1.0

8 years ago