Class: Flor::Message

Inherits:
FlorModel show all
Defined in:
lib/flor/unit/models/message.rb

Instance Method Summary collapse

Methods inherited from FlorModel

#data, #execution, from_h, #node, #refresh, #storage, #to_h, #unit

Instance Method Details

#feiObject



28
# File 'lib/flor/unit/models/message.rb', line 28

def fei; [ exid, nid ].join('-') rescue nil; end

#nidObject

create_table :flor_messages do

primary_key :id, type: :Integer
String :domain, null: false
String :exid, null: false
String :point, null: false # 'execute', 'task', 'receive', ...
File :content # JSON
String :status, null: false
String :ctime, null: false
String :mtime, null: false
String :cunit
String :munit

index :exid

end



24
# File 'lib/flor/unit/models/message.rb', line 24

def nid; data['nid']; end

#taskerObject



25
# File 'lib/flor/unit/models/message.rb', line 25

def tasker; data['tasker']; end