Class: Gizzard::ShardInfo

Inherits:
Object
  • Object
show all
Defined in:
lib/gizzard/thrift.rb

Instance Method Summary collapse

Instance Method Details

#busy?Boolean

Returns:

  • (Boolean)


48
49
50
# File 'lib/gizzard/thrift.rb', line 48

def busy?
  busy && busy > 0
end

#inspect(short = false) ⇒ Object



52
53
54
# File 'lib/gizzard/thrift.rb', line 52

def inspect(short = false)
  "#{id.inspect}" + (busy? ? " (BUSY)" : "")
end

#to_unixObject



56
57
58
# File 'lib/gizzard/thrift.rb', line 56

def to_unix
  [id.to_unix, class_name, busy? ? "busy" : "ok"].join("\t")
end