Reference documentation and code samples for the App Topology V1 API class Google::Cloud::AppTopology::V1::AppTopology::Client.
Client for the AppTopology service.
Service describing handlers for resources
Inherits
- Object
Methods
.configure
def self.configure() { |config| ... } -> Client::ConfigurationConfigure the AppTopology Client class.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
# Modify the configuration for all AppTopology clients ::Google::Cloud::AppTopology::V1::AppTopology::Client.configure do |config| config.timeout = 10.0 end
#configure
def configure() { |config| ... } -> Client::ConfigurationConfigure the AppTopology Client instance.
The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on Client.configure.
See Configuration for a description of the configuration fields.
- (config) — Configure the Client client.
- config (Client::Configuration)
#generate_discovered_resources_topology
def generate_discovered_resources_topology(request, options = nil) -> ::Google::Cloud::AppTopology::V1::GenerateDiscoveredResourcesTopologyResponse
def generate_discovered_resources_topology(filter: nil, name: nil, topology_domains: nil) -> ::Google::Cloud::AppTopology::V1::GenerateDiscoveredResourcesTopologyResponseGenerate the topology for all resources in the given project. If the project represents an app boundary, the topology is generated for all resources in the boundary.
def generate_discovered_resources_topology(request, options = nil) -> ::Google::Cloud::AppTopology::V1::GenerateDiscoveredResourcesTopologyResponsegenerate_discovered_resources_topology via a request object, either of type
GenerateDiscoveredResourcesTopologyRequest or an equivalent Hash.
- request (::Google::Cloud::AppTopology::V1::GenerateDiscoveredResourcesTopologyRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def generate_discovered_resources_topology(filter: nil, name: nil, topology_domains: nil) -> ::Google::Cloud::AppTopology::V1::GenerateDiscoveredResourcesTopologyResponsegenerate_discovered_resources_topology via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
- filter (::Google::Cloud::AppTopology::V1::GraphPattern, ::Hash) — Filters for the topology nodes and edges; Detail format see GraphPattern proto. A separate 'LookupSchema' method will be added that will return the necessary information to be able to construct these filters.
-
name (::String) — Required. The project to query discoverable resources on.
Expected format:
projects/{project}/locations/{location}/discoveredResourcesTopology. Onlygloballocation is supported. -
topology_domains (::Array<::String>) — Required. The full resource name of the domain of the app topology.
Format:
projects/{project}/locations/{location}/domains/{domain}Caller must have apptopology.domains.get permission on each of the domains.
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::AppTopology::V1::GenerateDiscoveredResourcesTopologyResponse)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/app_topology/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::AppTopology::V1::AppTopology::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::AppTopology::V1::GenerateDiscoveredResourcesTopologyRequest.new # Call the generate_discovered_resources_topology method. result = client.generate_discovered_resources_topology request # The returned object is of type Google::Cloud::AppTopology::V1::GenerateDiscoveredResourcesTopologyResponse. p result
#get_domain
def get_domain(request, options = nil) -> ::Google::Cloud::AppTopology::V1::Domain
def get_domain(name: nil) -> ::Google::Cloud::AppTopology::V1::DomainRetrieves the specified topology domain.
def get_domain(request, options = nil) -> ::Google::Cloud::AppTopology::V1::Domainget_domain via a request object, either of type
GetDomainRequest or an equivalent Hash.
- request (::Google::Cloud::AppTopology::V1::GetDomainRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_domain(name: nil) -> ::Google::Cloud::AppTopology::V1::Domainget_domain via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the domain to retrieve.
Format:
projects/{project}/locations/{location}/domains/{domain}
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::AppTopology::V1::Domain)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/app_topology/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::AppTopology::V1::AppTopology::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::AppTopology::V1::GetDomainRequest.new # Call the get_domain method. result = client.get_domain request # The returned object is of type Google::Cloud::AppTopology::V1::Domain. p result
#get_schema
def get_schema(request, options = nil) -> ::Google::Cloud::AppTopology::V1::Schema
def get_schema(name: nil) -> ::Google::Cloud::AppTopology::V1::SchemaRetrieves the schema for the specified topology domain. The schema defines the NodeTypes and EdgeTypes that are supported in GenerateDiscoveredResourcesTopology requests and responses for a given domain.
def get_schema(request, options = nil) -> ::Google::Cloud::AppTopology::V1::Schemaget_schema via a request object, either of type
GetSchemaRequest or an equivalent Hash.
- request (::Google::Cloud::AppTopology::V1::GetSchemaRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def get_schema(name: nil) -> ::Google::Cloud::AppTopology::V1::Schemaget_schema via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
name (::String) — Required. The name of the singleton domain schema resource.
Format:
projects/{project}/locations/{location}/domains/{domain}/schema
- (response, operation) — Access the result along with the RPC operation
- response (::Google::Cloud::AppTopology::V1::Schema)
- operation (::GRPC::ActiveCall::Operation)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/app_topology/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::AppTopology::V1::AppTopology::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::AppTopology::V1::GetSchemaRequest.new # Call the get_schema method. result = client.get_schema request # The returned object is of type Google::Cloud::AppTopology::V1::Schema. p result
#initialize
def initialize() { |config| ... } -> ClientCreate a new AppTopology client object.
- (config) — Configure the AppTopology client.
- config (Client::Configuration)
- (Client) — a new instance of Client
# Create a client using the default configuration client = ::Google::Cloud::AppTopology::V1::AppTopology::Client.new # Create a client using a custom configuration client = ::Google::Cloud::AppTopology::V1::AppTopology::Client.new do |config| config.timeout = 10.0 end
#list_domains
def list_domains(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::AppTopology::V1::Domain>
def list_domains(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::AppTopology::V1::Domain>Lists the topology domains available in a specific location.
Only global location is supported.
def list_domains(request, options = nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::AppTopology::V1::Domain>list_domains via a request object, either of type
ListDomainsRequest or an equivalent Hash.
- request (::Google::Cloud::AppTopology::V1::ListDomainsRequest, ::Hash) — A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- options (::Gapic::CallOptions, ::Hash) — Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
def list_domains(parent: nil, page_size: nil, page_token: nil) -> ::Gapic::PagedEnumerable<::Google::Cloud::AppTopology::V1::Domain>list_domains via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
-
parent (::String) — Required. The parent location to list domains for.
Format:
projects/{project}/locations/{location}Onlygloballocation is supported. - page_size (::Integer) — Optional. The maximum number of domains to return. The service may return fewer than this value. If unspecified, at most 50 domains will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
-
page_token (::String) — Optional. A page token, received from a previous
ListDomainscall. Provide this to retrieve the subsequent page.When paginating, all other parameters provided to
ListDomainsmust match the call that provided the page token.
- (response, operation) — Access the result along with the RPC operation
- response (::Gapic::PagedEnumerable<::Google::Cloud::AppTopology::V1::Domain>)
- operation (::GRPC::ActiveCall::Operation)
- (::Gapic::PagedEnumerable<::Google::Cloud::AppTopology::V1::Domain>)
- (::Google::Cloud::Error) — if the RPC is aborted.
Basic example
require "google/cloud/app_topology/v1" # Create a client object. The client can be reused for multiple calls. client = Google::Cloud::AppTopology::V1::AppTopology::Client.new # Create a request. To set request fields, pass in keyword arguments. request = Google::Cloud::AppTopology::V1::ListDomainsRequest.new # Call the list_domains method. result = client.list_domains request # The returned object is of type Gapic::PagedEnumerable. You can iterate # over elements, and API calls will be issued to fetch pages as needed. result.each do |item| # Each element is of type ::Google::Cloud::AppTopology::V1::Domain. p item end
#location_client
def location_client() -> Google::Cloud::Location::Locations::ClientGet the associated client for mix-in of the Locations.
- (Google::Cloud::Location::Locations::Client)
#logger
def logger() -> LoggerThe logger used for request/response debug logging.
- (Logger)
#universe_domain
def universe_domain() -> StringThe effective universe domain
- (String)