Giter VIP home page Giter VIP logo

mesomatic's Introduction

mesomatic: the cluster is a library

Build Status

Mesomatic provides facilities to interact with Apache Mesos from clojure. It provides a simple and idiomatic facade around the Mesos JAVA API and facilities to help when writing mesos frameworks.

Mesomatic versions match the API version they target, a trailing minor indicates the patch release number, for instance version 1.0.1-r0 will target mesos 1.0.1.

Usage

Add this to your leiningen profile.

:dependencies [[org.spootnik/mesomatic "1.0.1-r0"]]

If you want to use the core.async facade, you will need to pull it in as well:

:dependencies [[org.spootnik/mesomatic       "1.0.1-r0"]
               [org.spootnik/mesomatic-async "1.0.1-r0"]]

Examples

See example frameworks built with mesomatic at https://github.com/clojusc/mesomatic-examples

Namespaces

  • mesomatic.types: contains a facade to and from all protobuf types.
  • mesomatic.scheduler: facades for schedulers and scheduler-drivers
  • mesomatic.executor: facades for executors and executor-drivers
  • mesomatic.async.executor: produce executor callbacks on a channel
  • mesomatic.async.scheduler: produce scheduler callbacks on a channel
  • mesomatic.helpers: utility helpers for cluster decisions

Type conversions

To go to and from protobuf types, mesomatic uses two simple functions:

  • pb->data: yields a data structure from a mesos type, usually in the form of a record.
  • data->pb: converts a data structure to a mesos type.
  • ->pb: convert a plain map to a mesos type hinted at by a keyword

By yielding records, mesomatic provides elements which are homomorphic to maps and can easily be converted back to protobuf.

Special cases

A few cases do not yield records:

  • Scalar values (Protos.Value.Scalar) yield doubles.
  • All enums yield keywords.
  • Set values (Protos.Value.Set) yield sets.
  • Some types containing a single repeated field are unrolled as a seq of their content, such as Protos.Value.Ranges.

Changelog

1.0.1-r0

  • Target mesos 1.0.1
  • Support for GPU resources

This release was built with help from:

  • @oubiwan
  • @munk
  • @mforsyth
  • @dgrnbg
  • @alexandergunnarson

mesomatic's People

Contributors

pyr avatar oubiwann avatar munk avatar alexandergunnarson avatar dgrnbrg avatar mforsyth avatar

Stargazers

Eric Bailey avatar

Watchers

James Cloos avatar  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.