Class List Method List File List

# Class: VertxConsul::ConsulClient

Inherits:
  Object
  - Object
  - VertxConsul::ConsulClient
  show all
Defined in:
  /Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb

## Overview

A Vert.x service used to interact with Consul.

## Direct Known Subclasses

ConsulService

## Constant Summary

@@j_api_type =

      Object.new

## Class Method Summary (collapse)

- + (Boolean) accept?(obj)
- + (::VertxConsul::ConsulClient) create(vertx = nil, options = nil)
  Create a Consul client.
- + (Object) j_api_type
- + (Object) j_class
- + (Object) unwrap(obj)
- + (Object) wrap(obj)

## Instance Method Summary (collapse)

- - (self) agent_info { ... }
  Returns the configuration and member information of the local agent.
- - (self) catalog_datacenters { ... }
  Return all the datacenters that are known by the Consul server.
- - (self) catalog_node_services(node = nil) { ... }
  Returns the node's registered services.
- - (self) catalog_node_services_with_options(node = nil, options = nil) { ... }
  Returns the node's registered services This is blocking query unlike #catalog_node_services.
- - (self) catalog_nodes { ... }
  Returns the nodes registered in a datacenter.
- - (self) catalog_nodes_with_options(options = nil) { ... }
  Returns the nodes registered in a datacenter.
- - (self) catalog_service_nodes(service = nil) { ... }
  Returns the nodes providing a service.
- - (self) catalog_service_nodes_with_options(service = nil, options = nil) { ... }
  Returns the nodes providing a service.
- - (self) catalog_services { ... }
  Returns the services registered in a datacenter.
- - (self) catalog_services_with_options(options = nil) { ... }
  Returns the services registered in a datacenter This is blocking query unlike #catalog_services.
- - (self) clone_acl_token(id = nil) { ... }
  Clone Acl token.
- - (void) close
  Close the client and release its resources.
- - (self) coordinate_datacenters { ... }
  Returns the WAN network coordinates for all Consul servers, organized by DCs.
- - (self) coordinate_nodes { ... }
  Returns the LAN network coordinates for all nodes in a given DC.
- - (self) coordinate_nodes_with_options(options = nil) { ... }
  Returns the LAN network coordinates for all nodes in a given DC This is blocking query unlike #coordinate_nodes.
- - (self) create_acl_token(token = nil) { ... }
  Create new Acl token.
- - (self) create_prepared_query(definition = nil) { ... }
- - (self) create_session { ... }
  Initialize a new session.
- - (self) create_session_with_options(options = nil) { ... }
  Initialize a new session.
- - (self) delete_prepared_query(id = nil) { ... }
  Deletes an existing prepared query.
- - (self) delete_value(key = nil) { ... }
  Remove the key/value pair that corresponding to the specified key.
- - (self) delete_values(keyPrefix = nil) { ... }
  Removes all the key/value pair that corresponding to the specified key prefix.
- - (self) deregister_check(checkId = nil) { ... }
  Remove a check from the local agent.
- - (self) deregister_service(id = nil) { ... }
  Remove a service from the local agent.
- - (self) destroy_acl_token(id = nil) { ... }
  Destroy Acl token.
- - (self) destroy_session(id = nil) { ... }
  Destroys the given session.
- - (self) execute_prepared_query(query = nil) { ... }
  Executes an existing prepared query.
- - (self) execute_prepared_query_with_options(query = nil, options = nil) { ... }
  Executes an existing prepared query.
- - (self) fail_check(checkId = nil) { ... }
  Set status of the check to "critical".
- - (self) fail_check_with_note(checkId = nil, note = nil) { ... }
  Set status of the check to "critical".
- - (self) fire_event(name = nil) { ... }
  Fires a new user event.
- - (self) fire_event_with_options(name = nil, options = nil) { ... }
  Fires a new user event.
- - (self) get_all_prepared_queries { ... }
  Returns a list of all prepared queries.
- - (self) get_keys(keyPrefix = nil) { ... }
  Returns the list of keys that corresponding to the specified key prefix.
- - (self) get_keys_with_options(keyPrefix = nil, options = nil) { ... }
  Returns the list of keys that corresponding to the specified key prefix.
- - (self) get_prepared_query(id = nil) { ... }
  Returns an existing prepared query.
- - (self) get_value(key = nil) { ... }
  Returns key/value pair that corresponding to the specified key.
- - (self) get_value_with_options(key = nil, options = nil) { ... }
  Returns key/value pair that corresponding to the specified key.
- - (self) get_values(keyPrefix = nil) { ... }
  Returns the list of key/value pairs that corresponding to the specified key prefix.
- - (self) get_values_with_options(keyPrefix = nil, options = nil) { ... }
  Returns the list of key/value pairs that corresponding to the specified key prefix.
- - (self) health_checks(service = nil) { ... }
  Returns the checks associated with the service.
- - (self) health_checks_with_options(service = nil, options = nil) { ... }
  Returns the checks associated with the service.
- - (self) health_service_nodes(service = nil, passing = nil) { ... }
  Returns the nodes providing the service.
- - (self) health_service_nodes_with_options(service = nil, passing = nil, options = nil) { ... }
  Returns the nodes providing the service.
- - (self) health_state(healthState = nil) { ... }
  Returns the checks in the specified status.
- - (self) health_state_with_options(healthState = nil, options = nil) { ... }
  Returns the checks in the specified status.
- - (self) info_acl_token(id = nil) { ... }
  Get info of Acl token.
- - (self) info_session(id = nil) { ... }
  Returns the requested session information.
- - (self) info_session_with_options(id = nil, options = nil) { ... }
  Returns the requested session information This is blocking query unlike #info_session.
- - (self) leader_status { ... }
  Get the Raft leader for the datacenter in which the agent is running.
- - (self) list_acl_tokens { ... }
  Get list of Acl token.
- - (self) list_events { ... }
  Returns the most recent events known by the agent.
- - (self) list_events_with_options(options = nil) { ... }
  Returns the most recent events known by the agent.
- - (self) list_node_sessions(nodeId = nil) { ... }
  Returns the active sessions for a given node.
- - (self) list_node_sessions_with_options(nodeId = nil, options = nil) { ... }
  Returns the active sessions for a given node This is blocking query unlike #list_node_sessions.
- - (self) list_sessions { ... }
  Returns the active sessions.
- - (self) list_sessions_with_options(options = nil) { ... }
  Returns the active sessions This is blocking query unlike #list_sessions.
- - (self) local_checks { ... }
  Return all the checks that are registered with the local agent.
- - (self) local_services { ... }
  Returns list of services registered with the local agent.
- - (self) maintenance_service(maintenanceOptions = nil) { ... }
  Places a given service into "maintenance mode".
- - (self) pass_check(checkId = nil) { ... }
  Set status of the check to "passing".
- - (self) pass_check_with_note(checkId = nil, note = nil) { ... }
  Set status of the check to "passing".
- - (self) peers_status { ... }
  Retrieves the Raft peers for the datacenter in which the the agent is running.
- - (self) put_value(key = nil, value = nil) { ... }
  Adds specified key/value pair.
- - (self) put_value_with_options(key = nil, value = nil, options = nil) { ... }
- - (self) register_check(checkOptions = nil) { ... }
  Add a new check to the local agent.
- - (self) register_service(serviceOptions = nil) { ... }
  Adds a new service, with an optional health check, to the local agent.
- - (self) renew_session(id = nil) { ... }
  Renews the given session.
- - (self) transaction(request = nil) { ... }
  Manages multiple operations inside a single, atomic transaction.
- - (self) update_acl_token(token = nil) { ... }
  Update Acl token.
- - (self) update_check(checkId = nil, status = nil) { ... }
  Set status of the check to given status.
- - (self) update_check_with_note(checkId = nil, status = nil, note = nil) { ... }
  Set status of the check to given status.
- - (self) update_prepared_query(definition = nil) { ... }
- - (self) warn_check(checkId = nil) { ... }
  Set status of the check to "warning".
- - (self) warn_check_with_note(checkId = nil, note = nil) { ... }
  Set status of the check to "warning".

## Class Method Details

### + (`Boolean`) accept?(obj)

Returns:

- (`Boolean`)

    18
    19
    20
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 18

    def @@j_api_type.accept?(obj)
      obj.class == ConsulClient
    end

### + (`::VertxConsul::ConsulClient`) create(vertx = nil, options = nil)

Create a Consul client.

Parameters:

- vertx (`::Vertx::Vertx`) (defaults to: `nil`) —
  the Vert.x instance
- options (`Hash`) (defaults to: `nil`) —
  the options

Returns:

- (`::VertxConsul::ConsulClient`) —
  the client

Raises:

- (`ArgumentError`)

    37
    38
    39
    40
    41
    42
    43
    44
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 37

    def self.create(vertx=nil,options=nil)
      if vertx.class.method_defined?(:j_del) && !block_given? && options == nil
        return ::Vertx::Util::Utils.safe_create(Java::IoVertxExtConsul::ConsulClient.java_method(:create, [Java::IoVertxCore::Vertx.java_class]).call(vertx.j_del),::VertxConsul::ConsulClient)
      elsif vertx.class.method_defined?(:j_del) && options.class == Hash && !block_given?
        return ::Vertx::Util::Utils.safe_create(Java::IoVertxExtConsul::ConsulClient.java_method(:create, [Java::IoVertxCore::Vertx.java_class,Java::IoVertxExtConsul::ConsulClientOptions.java_class]).call(vertx.j_del,Java::IoVertxExtConsul::ConsulClientOptions.new(::Vertx::Util::Utils.to_json_object(options))),::VertxConsul::ConsulClient)
      end
      raise ArgumentError, "Invalid arguments when calling create(#{vertx},#{options})"
    end

### + (`Object`) j_api_type

    27
    28
    29
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 27

    def self.j_api_type
      @@j_api_type
    end

### + (`Object`) j_class

    30
    31
    32
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 30

    def self.j_class
      Java::IoVertxExtConsul::ConsulClient.java_class
    end

### + (`Object`) unwrap(obj)

    24
    25
    26
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 24

    def @@j_api_type.unwrap(obj)
      obj.j_del
    end

### + (`Object`) wrap(obj)

    21
    22
    23
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 21

    def @@j_api_type.wrap(obj)
      ConsulClient.new(obj)
    end

## Instance Method Details

### - (`self`) agent_info { ... }

Returns the configuration and member information of the local agent

Yields:

- will be provided with the configuration and member information of the local agent

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    48
    49
    50
    51
    52
    53
    54
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 48

    def agent_info
      if block_given?
        @j_del.java_method(:agentInfo, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling agent_info()"
    end

### - (`self`) catalog_datacenters { ... }

Return all the datacenters that are known by the Consul server

Yields:

- will be provided with list of datacenters

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    395
    396
    397
    398
    399
    400
    401
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 395

    def catalog_datacenters
      if block_given?
        @j_del.java_method(:catalogDatacenters, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_datacenters()"
    end

### - (`self`) catalog_node_services(node = nil) { ... }

Returns the node's registered services

Parameters:

- node (`String`) (defaults to: `nil`) —
  node name

Yields:

- will be provided with list of services

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    522
    523
    524
    525
    526
    527
    528
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 522

    def catalog_node_services(node=nil)
      if node.class == String && block_given?
        @j_del.java_method(:catalogNodeServices, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(node,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_node_services(#{node})"
    end

### - (`self`) catalog_node_services_with_options(node = nil, options = nil) { ... }

Returns the node's registered services This is blocking query unlike #catalog_node_services

Parameters:

- node (`String`) (defaults to: `nil`) —
  node name
- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with list of services

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    535
    536
    537
    538
    539
    540
    541
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 535

    def catalog_node_services_with_options(node=nil,options=nil)
      if node.class == String && options.class == Hash && block_given?
        @j_del.java_method(:catalogNodeServicesWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(node,Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_node_services_with_options(#{node},#{options})"
    end

### - (`self`) catalog_nodes { ... }

Returns the nodes registered in a datacenter

Yields:

- will be provided with list of nodes

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    405
    406
    407
    408
    409
    410
    411
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 405

    def catalog_nodes
      if block_given?
        @j_del.java_method(:catalogNodes, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_nodes()"
    end

### - (`self`) catalog_nodes_with_options(options = nil) { ... }

Returns the nodes registered in a datacenter

Parameters:

- options (`Hash`) (defaults to: `nil`) —
  options used to request nodes

Yields:

- will be provided with list of nodes

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    416
    417
    418
    419
    420
    421
    422
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 416

    def catalog_nodes_with_options(options=nil)
      if options.class == Hash && block_given?
        @j_del.java_method(:catalogNodesWithOptions, [Java::IoVertxExtConsul::NodeQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::NodeQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_nodes_with_options(#{options})"
    end

### - (`self`) catalog_service_nodes(service = nil) { ... }

Returns the nodes providing a service

Parameters:

- service (`String`) (defaults to: `nil`) —
  name of service

Yields:

- will be provided with list of nodes providing given service

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    373
    374
    375
    376
    377
    378
    379
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 373

    def catalog_service_nodes(service=nil)
      if service.class == String && block_given?
        @j_del.java_method(:catalogServiceNodes, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(service,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_service_nodes(#{service})"
    end

### - (`self`) catalog_service_nodes_with_options(service = nil, options = nil) { ... }

Returns the nodes providing a service

Parameters:

- service (`String`) (defaults to: `nil`) —
  name of service
- options (`Hash`) (defaults to: `nil`) —
  options used to request services

Yields:

- will be provided with list of nodes providing given service

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    385
    386
    387
    388
    389
    390
    391
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 385

    def catalog_service_nodes_with_options(service=nil,options=nil)
      if service.class == String && options.class == Hash && block_given?
        @j_del.java_method(:catalogServiceNodesWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::ServiceQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(service,Java::IoVertxExtConsul::ServiceQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_service_nodes_with_options(#{service},#{options})"
    end

### - (`self`) catalog_services { ... }

Returns the services registered in a datacenter

Yields:

- will be provided with list of services

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    499
    500
    501
    502
    503
    504
    505
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 499

    def catalog_services
      if block_given?
        @j_del.java_method(:catalogServices, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_services()"
    end

### - (`self`) catalog_services_with_options(options = nil) { ... }

Returns the services registered in a datacenter This is blocking query unlike #catalog_services

Parameters:

- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with list of services

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    511
    512
    513
    514
    515
    516
    517
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 511

    def catalog_services_with_options(options=nil)
      if options.class == Hash && block_given?
        @j_del.java_method(:catalogServicesWithOptions, [Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling catalog_services_with_options(#{options})"
    end

### - (`self`) clone_acl_token(id = nil) { ... }

Clone Acl token

Parameters:

- id (`String`) (defaults to: `nil`) —
  the ID of token to be cloned

Yields:

- will be provided with ID of cloned token

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    245
    246
    247
    248
    249
    250
    251
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 245

    def clone_acl_token(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:cloneAclToken, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling clone_acl_token(#{id})"
    end

### - (`void`) close

This method returns an undefined value.

Close the client and release its resources

Raises:

- (`ArgumentError`)

    891
    892
    893
    894
    895
    896
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 891

    def close
      if !block_given?
        return @j_del.java_method(:close, []).call()
      end
      raise ArgumentError, "Invalid arguments when calling close()"
    end

### - (`self`) coordinate_datacenters { ... }

Returns the WAN network coordinates for all Consul servers, organized by DCs

Yields:

- will be provided with network coordinates for all Consul servers

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    80
    81
    82
    83
    84
    85
    86
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 80

    def coordinate_datacenters
      if block_given?
        @j_del.java_method(:coordinateDatacenters, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt != nil ? JSON.parse(elt.toJson.encode) : nil } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling coordinate_datacenters()"
    end

### - (`self`) coordinate_nodes { ... }

Returns the LAN network coordinates for all nodes in a given DC

Yields:

- will be provided with network coordinates of nodes in datacenter

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    58
    59
    60
    61
    62
    63
    64
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 58

    def coordinate_nodes
      if block_given?
        @j_del.java_method(:coordinateNodes, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling coordinate_nodes()"
    end

### - (`self`) coordinate_nodes_with_options(options = nil) { ... }

Returns the LAN network coordinates for all nodes in a given DC This is blocking query unlike #coordinate_nodes

Parameters:

- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with network coordinates of nodes in datacenter

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    70
    71
    72
    73
    74
    75
    76
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 70

    def coordinate_nodes_with_options(options=nil)
      if options.class == Hash && block_given?
        @j_del.java_method(:coordinateNodesWithOptions, [Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling coordinate_nodes_with_options(#{options})"
    end

### - (`self`) create_acl_token(token = nil) { ... }

Create new Acl token

Parameters:

- token (`Hash`) (defaults to: `nil`) —
  properties of the token

Yields:

- will be provided with ID of created token

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    223
    224
    225
    226
    227
    228
    229
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 223

    def create_acl_token(token=nil)
      if token.class == Hash && block_given?
        @j_del.java_method(:createAclToken, [Java::IoVertxExtConsul::AclToken.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::AclToken.new(::Vertx::Util::Utils.to_json_object(token)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling create_acl_token(#{token})"
    end

### - (`self`) create_prepared_query(definition = nil) { ... }

Parameters:

- definition (`Hash`) (defaults to: `nil`) —
  definition of the prepare query

Yields:

- will be provided with id of created prepare query

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    817
    818
    819
    820
    821
    822
    823
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 817

    def create_prepared_query(definition=nil)
      if definition.class == Hash && block_given?
        @j_del.java_method(:createPreparedQuery, [Java::IoVertxExtConsul::PreparedQueryDefinition.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::PreparedQueryDefinition.new(::Vertx::Util::Utils.to_json_object(definition)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling create_prepared_query(#{definition})"
    end

### - (`self`) create_session { ... }

Initialize a new session

Yields:

- will be provided with ID of new session

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    704
    705
    706
    707
    708
    709
    710
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 704

    def create_session
      if block_given?
        @j_del.java_method(:createSession, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling create_session()"
    end

### - (`self`) create_session_with_options(options = nil) { ... }

Initialize a new session

Parameters:

- options (`Hash`) (defaults to: `nil`) —
  options used to create session

Yields:

- will be provided with ID of new session

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    715
    716
    717
    718
    719
    720
    721
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 715

    def create_session_with_options(options=nil)
      if options.class == Hash && block_given?
        @j_del.java_method(:createSessionWithOptions, [Java::IoVertxExtConsul::SessionOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::SessionOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling create_session_with_options(#{options})"
    end

### - (`self`) delete_prepared_query(id = nil) { ... }

Deletes an existing prepared query

Parameters:

- id (`String`) (defaults to: `nil`) —
  the id of the query to delete

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    859
    860
    861
    862
    863
    864
    865
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 859

    def delete_prepared_query(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:deletePreparedQuery, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling delete_prepared_query(#{id})"
    end

### - (`self`) delete_value(key = nil) { ... }

Remove the key/value pair that corresponding to the specified key

Parameters:

- key (`String`) (defaults to: `nil`) —
  the key

Yields:

- will be called on complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    140
    141
    142
    143
    144
    145
    146
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 140

    def delete_value(key=nil)
      if key.class == String && block_given?
        @j_del.java_method(:deleteValue, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(key,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling delete_value(#{key})"
    end

### - (`self`) delete_values(keyPrefix = nil) { ... }

Removes all the key/value pair that corresponding to the specified key prefix

Parameters:

- keyPrefix (`String`) (defaults to: `nil`) —
  the prefix

Yields:

- will be called on complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    177
    178
    179
    180
    181
    182
    183
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 177

    def delete_values(keyPrefix=nil)
      if keyPrefix.class == String && block_given?
        @j_del.java_method(:deleteValues, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(keyPrefix,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling delete_values(#{keyPrefix})"
    end

### - (`self`) deregister_check(checkId = nil) { ... }

Remove a check from the local agent. The agent will take care of deregistering the check from the Catalog.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    578
    579
    580
    581
    582
    583
    584
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 578

    def deregister_check(checkId=nil)
      if checkId.class == String && block_given?
        @j_del.java_method(:deregisterCheck, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling deregister_check(#{checkId})"
    end

### - (`self`) deregister_service(id = nil) { ... }

Remove a service from the local agent. The agent will take care of deregistering the service with the Catalog. If there is an associated check, that is also deregistered.

Parameters:

- id (`String`) (defaults to: `nil`) —
  the ID of service

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    362
    363
    364
    365
    366
    367
    368
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 362

    def deregister_service(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:deregisterService, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling deregister_service(#{id})"
    end

### - (`self`) destroy_acl_token(id = nil) { ... }

Destroy Acl token

Parameters:

- id (`String`) (defaults to: `nil`) —
  the ID of token

Yields:

- will be called on complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    277
    278
    279
    280
    281
    282
    283
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 277

    def destroy_acl_token(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:destroyAclToken, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling destroy_acl_token(#{id})"
    end

### - (`self`) destroy_session(id = nil) { ... }

Destroys the given session

Parameters:

- id (`String`) (defaults to: `nil`) —
  the ID of session

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    807
    808
    809
    810
    811
    812
    813
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 807

    def destroy_session(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:destroySession, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling destroy_session(#{id})"
    end

### - (`self`) execute_prepared_query(query = nil) { ... }

Executes an existing prepared query.

Parameters:

- query (`String`) (defaults to: `nil`) —
  the ID of the query to execute. This can also be the name of an existing prepared query, or a name that matches a prefix name for a prepared query template.

Yields:

- will be provided with response

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    870
    871
    872
    873
    874
    875
    876
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 870

    def execute_prepared_query(query=nil)
      if query.class == String && block_given?
        @j_del.java_method(:executePreparedQuery, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(query,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling execute_prepared_query(#{query})"
    end

### - (`self`) execute_prepared_query_with_options(query = nil, options = nil) { ... }

Executes an existing prepared query.

Parameters:

- query (`String`) (defaults to: `nil`) —
  the ID of the query to execute. This can also be the name of an existing prepared query, or a name that matches a prefix name for a prepared query template.
- options (`Hash`) (defaults to: `nil`) —
  the options used to execute prepared query

Yields:

- will be provided with response

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    882
    883
    884
    885
    886
    887
    888
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 882

    def execute_prepared_query_with_options(query=nil,options=nil)
      if query.class == String && options.class == Hash && block_given?
        @j_del.java_method(:executePreparedQueryWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::PreparedQueryExecuteOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(query,Java::IoVertxExtConsul::PreparedQueryExecuteOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling execute_prepared_query_with_options(#{query},#{options})"
    end

### - (`self`) fail_check(checkId = nil) { ... }

Set status of the check to "critical". Used with a check that is of the TTL type. The TTL clock will be reset.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    635
    636
    637
    638
    639
    640
    641
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 635

    def fail_check(checkId=nil)
      if checkId.class == String && block_given?
        @j_del.java_method(:failCheck, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling fail_check(#{checkId})"
    end

### - (`self`) fail_check_with_note(checkId = nil, note = nil) { ... }

Set status of the check to "critical". Used with a check that is of the TTL type. The TTL clock will be reset.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check
- note (`String`) (defaults to: `nil`) —
  specifies a human-readable message. This will be passed through to the check's `Output` field.

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    647
    648
    649
    650
    651
    652
    653
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 647

    def fail_check_with_note(checkId=nil,note=nil)
      if checkId.class == String && note.class == String && block_given?
        @j_del.java_method(:failCheckWithNote, [Java::java.lang.String.java_class,Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,note,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling fail_check_with_note(#{checkId},#{note})"
    end

### - (`self`) fire_event(name = nil) { ... }

Fires a new user event

Parameters:

- name (`String`) (defaults to: `nil`) —
  name of event

Yields:

- will be provided with properties of event

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    288
    289
    290
    291
    292
    293
    294
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 288

    def fire_event(name=nil)
      if name.class == String && block_given?
        @j_del.java_method(:fireEvent, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(name,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling fire_event(#{name})"
    end

### - (`self`) fire_event_with_options(name = nil, options = nil) { ... }

Fires a new user event

Parameters:

- name (`String`) (defaults to: `nil`) —
  name of event
- options (`Hash`) (defaults to: `nil`) —
  options used to create event

Yields:

- will be provided with properties of event

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    300
    301
    302
    303
    304
    305
    306
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 300

    def fire_event_with_options(name=nil,options=nil)
      if name.class == String && options.class == Hash && block_given?
        @j_del.java_method(:fireEventWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::EventOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(name,Java::IoVertxExtConsul::EventOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling fire_event_with_options(#{name},#{options})"
    end

### - (`self`) get_all_prepared_queries { ... }

Returns a list of all prepared queries.

Yields:

- will be provided with list of definitions of the all prepare queries

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    838
    839
    840
    841
    842
    843
    844
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 838

    def get_all_prepared_queries
      if block_given?
        @j_del.java_method(:getAllPreparedQueries, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt != nil ? JSON.parse(elt.toJson.encode) : nil } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling get_all_prepared_queries()"
    end

### - (`self`) get_keys(keyPrefix = nil) { ... }

Returns the list of keys that corresponding to the specified key prefix.

Parameters:

- keyPrefix (`String`) (defaults to: `nil`) —
  the prefix

Yields:

- will be provided with keys list

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    91
    92
    93
    94
    95
    96
    97
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 91

    def get_keys(keyPrefix=nil)
      if keyPrefix.class == String && block_given?
        @j_del.java_method(:getKeys, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(keyPrefix,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling get_keys(#{keyPrefix})"
    end

### - (`self`) get_keys_with_options(keyPrefix = nil, options = nil) { ... }

Returns the list of keys that corresponding to the specified key prefix.

Parameters:

- keyPrefix (`String`) (defaults to: `nil`) —
  the prefix
- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with keys list

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    103
    104
    105
    106
    107
    108
    109
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 103

    def get_keys_with_options(keyPrefix=nil,options=nil)
      if keyPrefix.class == String && options.class == Hash && block_given?
        @j_del.java_method(:getKeysWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(keyPrefix,Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling get_keys_with_options(#{keyPrefix},#{options})"
    end

### - (`self`) get_prepared_query(id = nil) { ... }

Returns an existing prepared query

Parameters:

- id (`String`) (defaults to: `nil`) —
  the id of the query to read

Yields:

- will be provided with definition of the prepare query

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    828
    829
    830
    831
    832
    833
    834
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 828

    def get_prepared_query(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:getPreparedQuery, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling get_prepared_query(#{id})"
    end

### - (`self`) get_value(key = nil) { ... }

Returns key/value pair that corresponding to the specified key. An empty Hash object will be returned if no such key is found.

Parameters:

- key (`String`) (defaults to: `nil`) —
  the key

Yields:

- will be provided with key/value pair

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    115
    116
    117
    118
    119
    120
    121
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 115

    def get_value(key=nil)
      if key.class == String && block_given?
        @j_del.java_method(:getValue, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(key,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling get_value(#{key})"
    end

### - (`self`) get_value_with_options(key = nil, options = nil) { ... }

Returns key/value pair that corresponding to the specified key. An empty Hash object will be returned if no such key is found. This is blocking query unlike #get_value

Parameters:

- key (`String`) (defaults to: `nil`) —
  the key
- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with key/value pair

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    129
    130
    131
    132
    133
    134
    135
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 129

    def get_value_with_options(key=nil,options=nil)
      if key.class == String && options.class == Hash && block_given?
        @j_del.java_method(:getValueWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(key,Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling get_value_with_options(#{key},#{options})"
    end

### - (`self`) get_values(keyPrefix = nil) { ... }

Returns the list of key/value pairs that corresponding to the specified key prefix. An empty Hash object will be returned if no such key prefix is found.

Parameters:

- keyPrefix (`String`) (defaults to: `nil`) —
  the prefix

Yields:

- will be provided with list of key/value pairs

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    152
    153
    154
    155
    156
    157
    158
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 152

    def get_values(keyPrefix=nil)
      if keyPrefix.class == String && block_given?
        @j_del.java_method(:getValues, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(keyPrefix,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling get_values(#{keyPrefix})"
    end

### - (`self`) get_values_with_options(keyPrefix = nil, options = nil) { ... }

Returns the list of key/value pairs that corresponding to the specified key prefix. An empty Hash object will be returned if no such key prefix is found. This is blocking query unlike #get_values

Parameters:

- keyPrefix (`String`) (defaults to: `nil`) —
  the prefix
- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with list of key/value pairs

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    166
    167
    168
    169
    170
    171
    172
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 166

    def get_values_with_options(keyPrefix=nil,options=nil)
      if keyPrefix.class == String && options.class == Hash && block_given?
        @j_del.java_method(:getValuesWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(keyPrefix,Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling get_values_with_options(#{keyPrefix},#{options})"
    end

### - (`self`) health_checks(service = nil) { ... }

Returns the checks associated with the service

Parameters:

- service (`String`) (defaults to: `nil`) —
  the service name

Yields:

- will be provided with list of checks

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    427
    428
    429
    430
    431
    432
    433
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 427

    def health_checks(service=nil)
      if service.class == String && block_given?
        @j_del.java_method(:healthChecks, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(service,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling health_checks(#{service})"
    end

### - (`self`) health_checks_with_options(service = nil, options = nil) { ... }

Returns the checks associated with the service

Parameters:

- service (`String`) (defaults to: `nil`) —
  the service name
- options (`Hash`) (defaults to: `nil`) —
  options used to request checks

Yields:

- will be provided with list of checks

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    439
    440
    441
    442
    443
    444
    445
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 439

    def health_checks_with_options(service=nil,options=nil)
      if service.class == String && options.class == Hash && block_given?
        @j_del.java_method(:healthChecksWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::CheckQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(service,Java::IoVertxExtConsul::CheckQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling health_checks_with_options(#{service},#{options})"
    end

### - (`self`) health_service_nodes(service = nil, passing = nil) { ... }

Returns the nodes providing the service. This endpoint is very similar to the #catalog_service_nodes endpoint; however, this endpoint automatically returns the status of the associated health check as well as any system level health checks.

Parameters:

- service (`String`) (defaults to: `nil`) —
  the service name
- passing (`true`, `false`) (defaults to: `nil`) —
  if true, filter results to only nodes with all checks in the passing state

Yields:

- will be provided with list of services

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    475
    476
    477
    478
    479
    480
    481
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 475

    def health_service_nodes(service=nil,passing=nil)
      if service.class == String && (passing.class == TrueClass || passing.class == FalseClass) && block_given?
        @j_del.java_method(:healthServiceNodes, [Java::java.lang.String.java_class,Java::boolean.java_class,Java::IoVertxCore::Handler.java_class]).call(service,passing,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling health_service_nodes(#{service},#{passing})"
    end

### - (`self`) health_service_nodes_with_options(service = nil, passing = nil, options = nil) { ... }

Returns the nodes providing the service. This endpoint is very similar to the #catalog_service_nodes_with_options endpoint; however, this endpoint automatically returns the status of the associated health check as well as any system level health checks.

Parameters:

- service (`String`) (defaults to: `nil`) —
  the service name
- passing (`true`, `false`) (defaults to: `nil`) —
  if true, filter results to only nodes with all checks in the passing state
- options (`Hash`) (defaults to: `nil`) —
  options used to request services

Yields:

- will be provided with list of services

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    489
    490
    491
    492
    493
    494
    495
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 489

    def health_service_nodes_with_options(service=nil,passing=nil,options=nil)
      if service.class == String && (passing.class == TrueClass || passing.class == FalseClass) && options.class == Hash && block_given?
        @j_del.java_method(:healthServiceNodesWithOptions, [Java::java.lang.String.java_class,Java::boolean.java_class,Java::IoVertxExtConsul::ServiceQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(service,passing,Java::IoVertxExtConsul::ServiceQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling health_service_nodes_with_options(#{service},#{passing},#{options})"
    end

### - (`self`) health_state(healthState = nil) { ... }

Returns the checks in the specified status

Parameters:

- healthState (`:PASSING`, `:WARNING`, `:CRITICAL`, `:ANY`) (defaults to: `nil`) —
  the health state

Yields:

- will be provided with list of checks

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    450
    451
    452
    453
    454
    455
    456
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 450

    def health_state(healthState=nil)
      if healthState.class == Symbol && block_given?
        @j_del.java_method(:healthState, [Java::IoVertxExtConsul::HealthState.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::HealthState.valueOf(healthState.to_s),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling health_state(#{healthState})"
    end

### - (`self`) health_state_with_options(healthState = nil, options = nil) { ... }

Returns the checks in the specified status

Parameters:

- healthState (`:PASSING`, `:WARNING`, `:CRITICAL`, `:ANY`) (defaults to: `nil`) —
  the health state
- options (`Hash`) (defaults to: `nil`) —
  options used to request checks

Yields:

- will be provided with list of checks

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    462
    463
    464
    465
    466
    467
    468
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 462

    def health_state_with_options(healthState=nil,options=nil)
      if healthState.class == Symbol && options.class == Hash && block_given?
        @j_del.java_method(:healthStateWithOptions, [Java::IoVertxExtConsul::HealthState.java_class,Java::IoVertxExtConsul::CheckQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::HealthState.valueOf(healthState.to_s),Java::IoVertxExtConsul::CheckQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling health_state_with_options(#{healthState},#{options})"
    end

### - (`self`) info_acl_token(id = nil) { ... }

Get info of Acl token

Parameters:

- id (`String`) (defaults to: `nil`) —
  the ID of token

Yields:

- will be provided with token

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    266
    267
    268
    269
    270
    271
    272
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 266

    def info_acl_token(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:infoAclToken, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling info_acl_token(#{id})"
    end

### - (`self`) info_session(id = nil) { ... }

Returns the requested session information

Parameters:

- id (`String`) (defaults to: `nil`) —
  the ID of requested session

Yields:

- will be provided with info of requested session

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    726
    727
    728
    729
    730
    731
    732
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 726

    def info_session(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:infoSession, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling info_session(#{id})"
    end

### - (`self`) info_session_with_options(id = nil, options = nil) { ... }

Returns the requested session information This is blocking query unlike #info_session

Parameters:

- id (`String`) (defaults to: `nil`) —
  the ID of requested session
- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with info of requested session

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    739
    740
    741
    742
    743
    744
    745
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 739

    def info_session_with_options(id=nil,options=nil)
      if id.class == String && options.class == Hash && block_given?
        @j_del.java_method(:infoSessionWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(id,Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling info_session_with_options(#{id},#{options})"
    end

### - (`self`) leader_status { ... }

Get the Raft leader for the datacenter in which the agent is running. It returns an address in format "`10.1.10.12:8300`"

Yields:

- will be provided with address of cluster leader

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    683
    684
    685
    686
    687
    688
    689
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 683

    def leader_status
      if block_given?
        @j_del.java_method(:leaderStatus, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling leader_status()"
    end

### - (`self`) list_acl_tokens { ... }

Get list of Acl token

Yields:

- will be provided with list of tokens

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    255
    256
    257
    258
    259
    260
    261
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 255

    def list_acl_tokens
      if block_given?
        @j_del.java_method(:listAclTokens, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt != nil ? JSON.parse(elt.toJson.encode) : nil } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling list_acl_tokens()"
    end

### - (`self`) list_events { ... }

Returns the most recent events known by the agent

Yields:

- will be provided with list of events

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    310
    311
    312
    313
    314
    315
    316
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 310

    def list_events
      if block_given?
        @j_del.java_method(:listEvents, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling list_events()"
    end

### - (`self`) list_events_with_options(options = nil) { ... }

Returns the most recent events known by the agent. This is blocking query unlike #list_events. However, the semantics of this endpoint are slightly different. Most blocking queries provide a monotonic index and block until a newer index is available. This can be supported as a consequence of the total ordering of the consensus protocol. With gossip, there is no ordering, and instead `X-Consul-Index` maps to the newest event that matches the query.

In practice, this means the index is only useful when used against a single agent and has no meaning globally. Because Consul defines the index as being opaque, clients should not be expecting a natural ordering either.

Parameters:

- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with list of events

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    328
    329
    330
    331
    332
    333
    334
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 328

    def list_events_with_options(options=nil)
      if options.class == Hash && block_given?
        @j_del.java_method(:listEventsWithOptions, [Java::IoVertxExtConsul::EventListOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::EventListOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling list_events_with_options(#{options})"
    end

### - (`self`) list_node_sessions(nodeId = nil) { ... }

Returns the active sessions for a given node

Parameters:

- nodeId (`String`) (defaults to: `nil`) —
  the ID of node

Yields:

- will be provided with list of sessions

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    783
    784
    785
    786
    787
    788
    789
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 783

    def list_node_sessions(nodeId=nil)
      if nodeId.class == String && block_given?
        @j_del.java_method(:listNodeSessions, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(nodeId,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling list_node_sessions(#{nodeId})"
    end

### - (`self`) list_node_sessions_with_options(nodeId = nil, options = nil) { ... }

Returns the active sessions for a given node This is blocking query unlike #list_node_sessions

Parameters:

- nodeId (`String`) (defaults to: `nil`) —
  the ID of node
- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with list of sessions

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    796
    797
    798
    799
    800
    801
    802
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 796

    def list_node_sessions_with_options(nodeId=nil,options=nil)
      if nodeId.class == String && options.class == Hash && block_given?
        @j_del.java_method(:listNodeSessionsWithOptions, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(nodeId,Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling list_node_sessions_with_options(#{nodeId},#{options})"
    end

### - (`self`) list_sessions { ... }

Returns the active sessions

Yields:

- will be provided with list of sessions

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    760
    761
    762
    763
    764
    765
    766
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 760

    def list_sessions
      if block_given?
        @j_del.java_method(:listSessions, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling list_sessions()"
    end

### - (`self`) list_sessions_with_options(options = nil) { ... }

Returns the active sessions This is blocking query unlike #list_sessions

Parameters:

- options (`Hash`) (defaults to: `nil`) —
  the blocking options

Yields:

- will be provided with list of sessions

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    772
    773
    774
    775
    776
    777
    778
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 772

    def list_sessions_with_options(options=nil)
      if options.class == Hash && block_given?
        @j_del.java_method(:listSessionsWithOptions, [Java::IoVertxExtConsul::BlockingQueryOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::BlockingQueryOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling list_sessions_with_options(#{options})"
    end

### - (`self`) local_checks { ... }

Return all the checks that are registered with the local agent.

Yields:

- will be provided with list of checks

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    555
    556
    557
    558
    559
    560
    561
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 555

    def local_checks
      if block_given?
        @j_del.java_method(:localChecks, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt != nil ? JSON.parse(elt.toJson.encode) : nil } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling local_checks()"
    end

### - (`self`) local_services { ... }

Returns list of services registered with the local agent.

Yields:

- will be provided with list of services

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    545
    546
    547
    548
    549
    550
    551
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 545

    def local_services
      if block_given?
        @j_del.java_method(:localServices, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt != nil ? JSON.parse(elt.toJson.encode) : nil } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling local_services()"
    end

### - (`self`) maintenance_service(maintenanceOptions = nil) { ... }

Places a given service into "maintenance mode"

Parameters:

- maintenanceOptions (`Hash`) (defaults to: `nil`) —
  the maintenance options

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    350
    351
    352
    353
    354
    355
    356
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 350

    def maintenance_service(maintenanceOptions=nil)
      if maintenanceOptions.class == Hash && block_given?
        @j_del.java_method(:maintenanceService, [Java::IoVertxExtConsul::MaintenanceOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::MaintenanceOptions.new(::Vertx::Util::Utils.to_json_object(maintenanceOptions)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling maintenance_service(#{maintenanceOptions})"
    end

### - (`self`) pass_check(checkId = nil) { ... }

Set status of the check to "passing". Used with a check that is of the TTL type. The TTL clock will be reset.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    589
    590
    591
    592
    593
    594
    595
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 589

    def pass_check(checkId=nil)
      if checkId.class == String && block_given?
        @j_del.java_method(:passCheck, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling pass_check(#{checkId})"
    end

### - (`self`) pass_check_with_note(checkId = nil, note = nil) { ... }

Set status of the check to "passing". Used with a check that is of the TTL type. The TTL clock will be reset.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check
- note (`String`) (defaults to: `nil`) —
  specifies a human-readable message. This will be passed through to the check's `Output` field.

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    601
    602
    603
    604
    605
    606
    607
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 601

    def pass_check_with_note(checkId=nil,note=nil)
      if checkId.class == String && note.class == String && block_given?
        @j_del.java_method(:passCheckWithNote, [Java::java.lang.String.java_class,Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,note,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling pass_check_with_note(#{checkId},#{note})"
    end

### - (`self`) peers_status { ... }

Retrieves the Raft peers for the datacenter in which the the agent is running. It returns a list of addresses "`10.1.10.12:8300`", "`10.1.10.13:8300`"

Yields:

- will be provided with list of peers

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    694
    695
    696
    697
    698
    699
    700
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 694

    def peers_status
      if block_given?
        @j_del.java_method(:peersStatus, [Java::IoVertxCore::Handler.java_class]).call((Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result.to_a.map { |elt| elt } : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling peers_status()"
    end

### - (`self`) put_value(key = nil, value = nil) { ... }

Adds specified key/value pair

Parameters:

- key (`String`) (defaults to: `nil`) —
  the key
- value (`String`) (defaults to: `nil`) —
  the value

Yields:

- will be provided with success of operation

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    189
    190
    191
    192
    193
    194
    195
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 189

    def put_value(key=nil,value=nil)
      if key.class == String && value.class == String && block_given?
        @j_del.java_method(:putValue, [Java::java.lang.String.java_class,Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(key,value,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling put_value(#{key},#{value})"
    end

### - (`self`) put_value_with_options(key = nil, value = nil, options = nil) { ... }

Parameters:

- key (`String`) (defaults to: `nil`) —
  the key
- value (`String`) (defaults to: `nil`) —
  the value
- options (`Hash`) (defaults to: `nil`) —
  options used to push pair

Yields:

- will be provided with success of operation

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    201
    202
    203
    204
    205
    206
    207
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 201

    def put_value_with_options(key=nil,value=nil,options=nil)
      if key.class == String && value.class == String && options.class == Hash && block_given?
        @j_del.java_method(:putValueWithOptions, [Java::java.lang.String.java_class,Java::java.lang.String.java_class,Java::IoVertxExtConsul::KeyValueOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(key,value,Java::IoVertxExtConsul::KeyValueOptions.new(::Vertx::Util::Utils.to_json_object(options)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling put_value_with_options(#{key},#{value},#{options})"
    end

### - (`self`) register_check(checkOptions = nil) { ... }

Add a new check to the local agent. The agent is responsible for managing the status of the check and keeping the Catalog in sync.

Parameters:

- checkOptions (`Hash`) (defaults to: `nil`) —
  options used to register new check

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    567
    568
    569
    570
    571
    572
    573
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 567

    def register_check(checkOptions=nil)
      if checkOptions.class == Hash && block_given?
        @j_del.java_method(:registerCheck, [Java::IoVertxExtConsul::CheckOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::CheckOptions.new(::Vertx::Util::Utils.to_json_object(checkOptions)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling register_check(#{checkOptions})"
    end

### - (`self`) register_service(serviceOptions = nil) { ... }

Adds a new service, with an optional health check, to the local agent.

Parameters:

- serviceOptions (`Hash`) (defaults to: `nil`) —
  the options of new service

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    339
    340
    341
    342
    343
    344
    345
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 339

    def register_service(serviceOptions=nil)
      if serviceOptions.class == Hash && block_given?
        @j_del.java_method(:registerService, [Java::IoVertxExtConsul::ServiceOptions.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::ServiceOptions.new(::Vertx::Util::Utils.to_json_object(serviceOptions)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling register_service(#{serviceOptions})"
    end

### - (`self`) renew_session(id = nil) { ... }

Renews the given session. This is used with sessions that have a TTL, and it extends the expiration by the TTL

Parameters:

- id (`String`) (defaults to: `nil`) —
  the ID of session that should be renewed

Yields:

- will be provided with info of renewed session

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    750
    751
    752
    753
    754
    755
    756
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 750

    def renew_session(id=nil)
      if id.class == String && block_given?
        @j_del.java_method(:renewSession, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(id,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling renew_session(#{id})"
    end

### - (`self`) transaction(request = nil) { ... }

Manages multiple operations inside a single, atomic transaction.

Parameters:

- request (`Hash`) (defaults to: `nil`) —
  transaction request

Yields:

- will be provided with result of transaction

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    212
    213
    214
    215
    216
    217
    218
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 212

    def transaction(request=nil)
      if request.class == Hash && block_given?
        @j_del.java_method(:transaction, [Java::IoVertxExtConsul::TxnRequest.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::TxnRequest.new(::Vertx::Util::Utils.to_json_object(request)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result != nil ? JSON.parse(ar.result.toJson.encode) : nil : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling transaction(#{request})"
    end

### - (`self`) update_acl_token(token = nil) { ... }

Update Acl token

Parameters:

- token (`Hash`) (defaults to: `nil`) —
  properties of the token to be updated

Yields:

- will be provided with ID of updated

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    234
    235
    236
    237
    238
    239
    240
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 234

    def update_acl_token(token=nil)
      if token.class == Hash && block_given?
        @j_del.java_method(:updateAclToken, [Java::IoVertxExtConsul::AclToken.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::AclToken.new(::Vertx::Util::Utils.to_json_object(token)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil, ar.succeeded ? ar.result : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling update_acl_token(#{token})"
    end

### - (`self`) update_check(checkId = nil, status = nil) { ... }

Set status of the check to given status. Used with a check that is of the TTL type. The TTL clock will be reset.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check
- status (`:PASSING`, `:WARNING`, `:CRITICAL`) (defaults to: `nil`) —
  new status of check

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    659
    660
    661
    662
    663
    664
    665
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 659

    def update_check(checkId=nil,status=nil)
      if checkId.class == String && status.class == Symbol && block_given?
        @j_del.java_method(:updateCheck, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::CheckStatus.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,Java::IoVertxExtConsul::CheckStatus.valueOf(status.to_s),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling update_check(#{checkId},#{status})"
    end

### - (`self`) update_check_with_note(checkId = nil, status = nil, note = nil) { ... }

Set status of the check to given status. Used with a check that is of the TTL type. The TTL clock will be reset.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check
- status (`:PASSING`, `:WARNING`, `:CRITICAL`) (defaults to: `nil`) —
  new status of check
- note (`String`) (defaults to: `nil`) —
  specifies a human-readable message. This will be passed through to the check's `Output` field.

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    672
    673
    674
    675
    676
    677
    678
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 672

    def update_check_with_note(checkId=nil,status=nil,note=nil)
      if checkId.class == String && status.class == Symbol && note.class == String && block_given?
        @j_del.java_method(:updateCheckWithNote, [Java::java.lang.String.java_class,Java::IoVertxExtConsul::CheckStatus.java_class,Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,Java::IoVertxExtConsul::CheckStatus.valueOf(status.to_s),note,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling update_check_with_note(#{checkId},#{status},#{note})"
    end

### - (`self`) update_prepared_query(definition = nil) { ... }

Parameters:

- definition (`Hash`) (defaults to: `nil`) —
  definition of the prepare query

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    848
    849
    850
    851
    852
    853
    854
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 848

    def update_prepared_query(definition=nil)
      if definition.class == Hash && block_given?
        @j_del.java_method(:updatePreparedQuery, [Java::IoVertxExtConsul::PreparedQueryDefinition.java_class,Java::IoVertxCore::Handler.java_class]).call(Java::IoVertxExtConsul::PreparedQueryDefinition.new(::Vertx::Util::Utils.to_json_object(definition)),(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling update_prepared_query(#{definition})"
    end

### - (`self`) warn_check(checkId = nil) { ... }

Set status of the check to "warning". Used with a check that is of the TTL type. The TTL clock will be reset.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    612
    613
    614
    615
    616
    617
    618
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 612

    def warn_check(checkId=nil)
      if checkId.class == String && block_given?
        @j_del.java_method(:warnCheck, [Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling warn_check(#{checkId})"
    end

### - (`self`) warn_check_with_note(checkId = nil, note = nil) { ... }

Set status of the check to "warning". Used with a check that is of the TTL type. The TTL clock will be reset.

Parameters:

- checkId (`String`) (defaults to: `nil`) —
  the ID of check
- note (`String`) (defaults to: `nil`) —
  specifies a human-readable message. This will be passed through to the check's `Output` field.

Yields:

- will be called when complete

Returns:

- (`self`)

Raises:

- (`ArgumentError`)

    624
    625
    626
    627
    628
    629
    630
    # File '/Users/julien/java/vertx-aggregator/modules/vertx-lang-ruby/vertx-lang-ruby/target/classes/vertx-consul/consul_client.rb', line 624

    def warn_check_with_note(checkId=nil,note=nil)
      if checkId.class == String && note.class == String && block_given?
        @j_del.java_method(:warnCheckWithNote, [Java::java.lang.String.java_class,Java::java.lang.String.java_class,Java::IoVertxCore::Handler.java_class]).call(checkId,note,(Proc.new { |ar| yield(ar.failed ? ar.cause : nil) }))
        return self
      end
      raise ArgumentError, "Invalid arguments when calling warn_check_with_note(#{checkId},#{note})"
    end