Skip to content
This repository has been archived by the owner on Dec 7, 2018. It is now read-only.

Information Service

tarcieri edited this page Apr 17, 2012 · 1 revision

By default, DCell runs a service which collects information about your hardware, OS, and Ruby interpreter. It registers itself under :info:

>> node = DCell::Node["wintermute.local"]
 => #<DCell::Node[wintermute.local] @addr="tcp://127.0.0.1:7777">
>> info_service = node[:info]
 => #<Celluloid::Actor(DCell::InfoService:0x3fd847dd26d8) @cpu_arch="x86_64" @os="darwin" @os_version="11.3.0" @hostname="wintermute.local" @platform="x86_64-darwin11.3.0" @ruby_version="1.9.3" @ruby_engine="ruby" @cpu_type="Intel(R) Core(TM) i7-2635QM CPU" @cpu_vendor=:intel @cpu_speed=2.0 @cpu_count=8 @distribution="Mac OS X 10.7.3 (11D50b)" @ruby_platform="ruby 1.9.3"> 
>> info_service.load_averages
 => [0.71, 0.74, 0.79] 
Clone this wiki locally