Class: VFabricAdministrationServer

Inherits:
Object
  • Object
show all
Defined in:
lib/vas/vfabric_administration_server.rb

Overview

The main entry point to the vFabric Administration Server API.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(configuration = {}) ⇒ VFabricAdministrationServer

Creates an entry point that will connect to a vFabric Administration Server.

Parameters:

  • configuration (Hash) (defaults to: {})

    the connection configuration

Options Hash (configuration):

  • :username (String) — default: 'admin'

    The username to use to authenticate with the server

  • :password (String) — default: 'vmware'

    The password to use to authenticate with the server

  • :host (String) — default: 'localhost'

    The host of the server

  • :port (Integer) — default: 8443

    The HTTPS port of the server



38
39
40
41
42
43
44
45
46
47
48
# File 'lib/vas/vfabric_administration_server.rb', line 38

def initialize(configuration = {})
  @client = Util::Client.new(configuration[:username] || "admin", configuration[:password] || "vmware")

  host = configuration[:host] || "localhost"
  port = configuration[:port] || 8443

  @tc_server = TcServer::TcServer.new("https://#{host}:#{port}/tc-server/v1", @client)
  @vfabric = VFabric::VFabric.new("https://#{host}:#{port}/vfabric/v1", @client)
  @rabbitmq = RabbitMq::RabbitMq.new("https://#{host}:#{port}/rabbitmq/v1", @client)
  @gemfire = Gemfire::Gemfire.new("https://#{host}:#{port}/gemfire/v1", @client)
end

Instance Attribute Details

#gemfireGemfire::Gemfire (readonly)

Returns the GemFire API.

Returns:



21
22
23
# File 'lib/vas/vfabric_administration_server.rb', line 21

def gemfire
  @gemfire
end

#rabbitmqRabbitMq::RabbitMq (readonly)

Returns the RabbitMQ API.

Returns:



24
25
26
# File 'lib/vas/vfabric_administration_server.rb', line 24

def rabbitmq
  @rabbitmq
end

#tc_serverTcServer::TcServer (readonly)

Returns the tc Server API.

Returns:



27
28
29
# File 'lib/vas/vfabric_administration_server.rb', line 27

def tc_server
  @tc_server
end

#vfabricVFabric::VFabric (readonly)

Returns the vFabric API.

Returns:



30
31
32
# File 'lib/vas/vfabric_administration_server.rb', line 30

def vfabric
  @vfabric
end