Skip to content

REST API server with built in auth, interface to ScyllaDB/Cassandra

License

Notifications You must be signed in to change notification settings

megamsys/verticegateway

Folders and files

NameName
Last commit message
Last commit date

Latest commit

56b18ac · Aug 18, 2017
Aug 18, 2017
May 9, 2017
Jun 13, 2017
Jun 13, 2017
Aug 13, 2016
Nov 21, 2016
Mar 24, 2017
Nov 17, 2015
Jul 28, 2016
Jun 29, 2017
Aug 18, 2017
Aug 18, 2017
Oct 17, 2015
Oct 13, 2016

Repository files navigation

Vertice Gateway

This is our API server for MegamVertice 1.5.x or < 2.0 release.

Roadmap for 2.0

API server for 2.0 is based on rust connecting to cockroachdb.

Where is the code for 2.0

We have moved the development to private gitlab as it will have enterprise features.

When can i get it in my anxious hands

2.0 will be released on Sep 30 2017 or less.

Requirements to compile from source

  1. SBT 0.13.11 >
  2. NSQ 0.3.x
  3. OpenJDK 8.0
  4. Cassandra 3 +

The API server protects the RESTful resources using

  • HMAC based authorization.
  • PASSWORD based on PBKDF2
  • Master key

Compile from source

You'll need sbt build tool. and OpenJDK8.0

Fork

After you have forked a copy of https://github.com/megamsys/vertice_gateway.git

Steps


* git clone https://github.com/<your_github_id>/vertice_gateway.git

* cd vertice_gateway

* sbt

* clean

* compile


Running

Install Cassandra

Install NSQ.io

Setup cassandra keyspace

* cd vertice_gateway/db

* cqlsh -f base.cql

* cqlsh -f 1.5.cql

* cqlsh -f 1.5.1.cql

* cqlsh -f 1.5.2.cql

* cqlsh -f ee.cql

* cqlsh -f me.cql

MEGAM_HOME

Create a home directory to store configuration files for MegamVertice


$ cd ~

$ mkdir -p megam/home/verticegateway

Edit your .bashrc

In your .bashrc file add the following line


export MEGAM_HOME=$HOME/megam/home

After this enter save the .bashrc file.Use the following command

source ~/.bashrc

Configuration

Copy configuration files to $MEGAM_HOME/verticegateway


$ cd vertice_gateway (your cloned location)

$ cp conf/gateway.conf $MEGAM_HOME/verticegateway

$ cp conf/logger.xml $MEGAM_HOME/verticegateway


Start Vertice Gateway

* cd vertice_gateway

* sbt

* clean

* compile

* run

Gateway

Type the url http://localhost:9000

You'll see this in your browser.

{
  "status" : {
    "casssandra" : "up",
    "nsq" : "down"
  },
  "runtime" : {
    "total_mem" : "975 MB",
    "freemem" : "649 MB",
    "cores" : "4",
    "freespace" : "399 of 450 GB"
  }
}

Now you are all set.

API Documentation

Refer [docs](https://docs.megam.io] and we'll publish vertice.raml shortly.

To generate the html docs.


npm install -g raml2html

raml2html vertice.raml

Contribution

As this is heavy on memory, we have a work in progress 2.0 code which is based on rust.

Documentation

For [documentation] (http://docs.megam.io) [devkit] (https://github.com/megamsys/vertice_dev_kit)

License

MIT

Authors

Megam - Humans (humans@megam.io)