Class: Aggro::LocalNode

Inherits:
Struct
  • Object
show all
Defined in:
lib/aggro/local_node.rb

Overview

Public: Represents the local aggro server node.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#idObject

Returns the value of attribute id

Returns:

  • (Object)

    the current value of id



3
4
5
# File 'lib/aggro/local_node.rb', line 3

def id
  @id
end

Instance Method Details

#clientObject



4
5
6
# File 'lib/aggro/local_node.rb', line 4

def client
  @client ||= create_loopback_client
end

#endpointObject



8
9
10
# File 'lib/aggro/local_node.rb', line 8

def endpoint
  "tcp://*:#{Aggro.port}"
end

#publisher_endpointObject



12
13
14
# File 'lib/aggro/local_node.rb', line 12

def publisher_endpoint
  "tcp://*:#{Aggro.publisher_port}"
end

#to_sObject



16
17
18
# File 'lib/aggro/local_node.rb', line 16

def to_s
  id
end