Class: Moleculer::Packets::Heartbeat

Inherits:
Base
  • Object
show all
Defined in:
lib/moleculer/packets/heartbeat.rb

Overview

Represents a DISCOVER packet

Instance Attribute Summary

Attributes inherited from Base

#config

Instance Method Summary collapse

Methods inherited from Base

inherited, packet_accessors, packet_attr, packet_name, #sender, #to_h, #topic, #ver

Constructor Details

#initialize(config, data = {}) ⇒ Heartbeat

Returns a new instance of Heartbeat.



10
11
12
13
14
# File 'lib/moleculer/packets/heartbeat.rb', line 10

def initialize(config, data = {})
  super(config, data)

  @cpu = 0
end