Skip to content

Neopallium/lua-nanomsg

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
src
 
 
 
 
 
 

About

Lua bindings to NanoMsg.

Installation

It is recommended to either compile Lua with the "-pthread" flag or preload libpthread.so on Linux when using this module (see this glibc bug report):

$ LD_PRELOAD=/lib/libpthread.so lua

Latest Git revision

With LuaRocks:

$ sudo luarocks install https://raw.github.com/Neopallium/lua-nanomsg/master/rockspecs/lua-nanomsg-scm-1.rockspec

For threads support:

$ sudo luarocks install https://raw.github.com/Neopallium/lua-llthreads/master/rockspecs/lua-llthreads-scm-0.rockspec
$ sudo luarocks install https://raw.github.com/Neopallium/lua-nanomsg/master/rockspecs/lua-nanomsg-threads-scm-0.rockspec

With CMake:

$ git clone git://github.com/Neopallium/lua-nanomsg.git
$ cd lua-nanomsg ; mkdir build ; cd build
$ cmake ..
$ make
$ sudo make install

Running benchmarks

When running the benchmarks you will need run two different scripts (one 'local' and one 'remote'). Both scripts can be run on the same computer or on different computers. Make sure to start the 'local' script first.

Throughput benchmark:

# first start local script
$ luajit-2 perf/local_thr.lua "tcp://lo:5555" 30 1000000

# then in another window start remote script
$ luajit-2 perf/remote_thr.lua "tcp://localhost:5555" 30 1000000

Latency benchmark:

# first start local script
$ luajit-2 perf/local_lat.lua "tcp://lo:5555" 1 100000

# then in another window start remote script
$ luajit-2 perf/remote_lat.lua "tcp://localhost:5555" 1 100000

About

Lua bindings to NanoMsg

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages