Crobisaur / quickmsg

A small layer to facilitate open messaging between a set of components.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Quickmsg

Quickmsg is meant to be a thin application utility layer on top of Zyre/ZeroMQ and MessagePack, supporting simple group messaging. The primary message type (for now) is a JSON string, transformed to a compact binary format using MessagePack before transmission to a Zyre group. The API is being initially developed in C++, and is intended to be wrapped using a tool such as SWIG for use by multiple target languages.

The following components have initial implementations:

  • Publisher: publishes messages to a topic
  • Subscriber: receives messages from a topic (can be used synchronously and asynchronously / with a callback)
  • Service: provide an RPC-like service interface for…
  • Client: issues requests to a Service and blocks for a reply
  • GroupNode: low-level implementation allowing alternative patterns and supporting a promiscuous message handling mode.

Dependencies

  • ZeroMQ stack: libsodium, libzmq, czmq, and zyre*.
    • OSX/Linux: Installed from source using autotools (the CMakeLists are autogenerated and have been known to be stale/incorrect), with the procedure outlined in the czmq docs
    • *Recent versions of zyre have led to build errors in quickmsg. We are currently building against an older version
  • jsoncpp, from source or pkg-manager
  • Google logging, from source or pkg-manager
  • Swig 3.0
  • Python 2.7
  • TBB (Intel Threading Building Blocks)
  • Boost libraries

SWIG Wrapping

SWIG is a tool to generate wrappers for C/C++ code to a variety of high-level langauges, including Python, Java and Common Lisp.

Although there are pages indicating SWIG support for Common Lisp, there is contrary evidence that in fact Common Lisp support is not active or maintained.

Therefore, we do not use SWIG to generate the Common Lisp bindings, but instead implement a simple C wrapper that can be called directly with CFFI.

See the test directory for simple language tests and usage examples for C, C++, Java, Python, and Common Lisp.

The Common Lisp examples were tested with sbcl. The required common lisp packages, such as cl-json, were installed using quicklisp

About

A small layer to facilitate open messaging between a set of components.


Languages

Language:C++ 48.8%Language:CMake 31.6%Language:Common Lisp 6.2%Language:C 5.1%Language:Java 3.5%Language:C# 1.4%Language:Python 1.4%Language:Batchfile 1.4%Language:PowerShell 0.5%Language:Shell 0.3%