Version 7 by Kazuki Ohta
on Apr 03, 2011 18:30.

compared with
Current by Tim Lossen
on Jan 05, 2012 20:16.

(show comment)
This line was removed.
This word was removed. This word was added.
This line was added.

Changes (7)

View Page History

h1. Install

You can install MessagePack for Ruby using RubyGems. Ruby 1.8.6 or higher (including Ruby 1.9) is required.


There is also a version for JRuby, which uses native Java:
$ gem install msgpack-jruby
You can install MessagePack-RPC for Ruby using RubyGems.

src = ["Hello", "World", 1, 2, 3]
binary = MessagePack.pack(src)

dst = MessagePack.unpack(binary)
p dst #=> ["Hello", "World", 1, 2, 3]
require 'msgpack'

# Open the log file for write."log.mpac", "w") do |f|

# Open the log file for read."log.mpac") do |f|
require 'msgpack/rpc'

class MyHandler
def add(a, b)

svr =
svr.listen('', 9090,