Giter Club home page Giter Club logo

datomic-peer-svc's Introduction

Datomic Peer Buildpack

Datomic Peer Buildpack installs Datomic REST service bound to localhost:${DATOMIC_REST_PORT:-8777} running as a daemon on the same dyno as the app. This is useful for non-JVM Heroku apps that wish to use Datomic.

Naturally, the app and the datomic peer (REST service) will compete for resources of a dyno. The buildpack addresses that by restricting memory resources dedicated to Datomic REST service based on Heroku dyno size.

Add this buildpack to your APP like so:

heroku buildpacks:add https://github.com/upworthy/datomic-peer-svc.git -a APP

Ensure your app has Datomic-related configuration, mutatis mutandis:

heroku config:set -a APP \
  [email protected] \
  DATOMIC_DOWNLOAD_KEY=secret \
  DATOMIC_VERSION=0.9.5302 \
  DATOMIC_STORAGE_SPECS="alias1 datomic:ddb://<YOUR-AWS-REGION>/<YOUR-STORAGE-TABLE>/"

You may specify more than one Datomic storage using the command line syntax of Datomic's bin/console program: DATOMIC_STORAGE_SPECS="alias1 uri1 alias2 uri2 ..."

For example: DATOMIC_STORAGE_SPECS="db1 datomic:ddb://us-east-1/abc db2 datomic:ddb://us-west-2/xyz"

Datomic Peer Service

Datomic Peer Service allows you to run Datomic Console or REST API as a Heroku app. It consists of two components:

  • oauth2_proxy, a proxy that ensures only authorized Google-authenticated users may access your Datomic infrastructure (aka OA2P).
  • Datomic Console, a graphical UI that makes it easy to work with Datomic databases. It provides tools for exploring schema, building and executing queries, examining transactions and more.

Deploy

Dynamo DB Storage

You must specify AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY credentials of an AWS IAM user with the following statement among its policies:

{
    "Statement": [
        {
            "Effect": "Allow",
            "Action": [
                "dynamodb:GetItem",
                "dynamodb:BatchGetItem",
                "dynamodb:Scan",
                "dynamodb:Query"
            ],
            "Resource": "arn:aws:dynamodb:*:<YOUR-AWS-ACCOUNT>:table/<YOUR-STORAGE-TABLE>"
        }
    ]
}

Limitations

So far only Dynamo DB storage had been tested/used by the author.

datomic-peer-svc's People

Contributors

paxan avatar

Stargazers

anton avatar Justin Kramer avatar Gert Goet avatar Ethan Sherbondy avatar Gurdas Nijor avatar Randy Terbush avatar Oliver Martell Núñez avatar Mathieu Ravaux avatar Orlin M Bozhinov avatar Ben Fitzgerald avatar Jordan Leigh avatar  avatar Lauri Oherd avatar

Watchers

Orlin M Bozhinov avatar Josh French avatar Anders Conbere avatar  avatar Daniel Christopher avatar Lev Kanter avatar Ryan Resella avatar Gabriel Stein avatar James Cloos avatar Ian Lord avatar Austin Teer avatar Josh Click avatar Alex Shilen avatar April Goldman avatar Daniel Mintz avatar Peter Koechley avatar  avatar Eric Bauerfeld avatar Deveon Fisher avatar Erin Ozmat avatar Sean Wojcik avatar Nicole Moore avatar Megan Kelley 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.