# Generated by the protocol buffer compiler.  DO NOT EDIT!
# Source: temporal/api/operatorservice/v1/service.proto for package 'Temporalio.Api.OperatorService.V1'
# Original file comments:
# The MIT License
#
# Copyright (c) 2020 Temporal Technologies Inc.  All rights reserved.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
# THE SOFTWARE.
#

require 'grpc'
require 'temporal/api/operatorservice/v1/service_pb'

module Temporalio
  module Api
    module OperatorService
      module V1
        module OperatorService
          # OperatorService API defines how Temporal SDKs and other clients interact with the Temporal server
          # to perform administrative functions like registering a search attribute or a namespace.
          # APIs in this file could be not compatible with Temporal Cloud, hence it's usage in SDKs should be limited by
          # designated APIs that clearly state that they shouldn't be used by the main Application (Workflows & Activities) framework.
          class Service

            include ::GRPC::GenericService

            self.marshal_class_method = :encode
            self.unmarshal_class_method = :decode
            self.service_name = 'temporal.api.operatorservice.v1.OperatorService'

            # AddSearchAttributes add custom search attributes.
            #
            # Returns ALREADY_EXISTS status code if a Search Attribute with any of the specified names already exists
            # Returns INTERNAL status code with temporal.api.errordetails.v1.SystemWorkflowFailure in Error Details if registration process fails,
            rpc :AddSearchAttributes, ::Temporalio::Api::OperatorService::V1::AddSearchAttributesRequest, ::Temporalio::Api::OperatorService::V1::AddSearchAttributesResponse
            # RemoveSearchAttributes removes custom search attributes.
            #
            # Returns NOT_FOUND status code if a Search Attribute with any of the specified names is not registered
            rpc :RemoveSearchAttributes, ::Temporalio::Api::OperatorService::V1::RemoveSearchAttributesRequest, ::Temporalio::Api::OperatorService::V1::RemoveSearchAttributesResponse
            # ListSearchAttributes returns comprehensive information about search attributes.
            rpc :ListSearchAttributes, ::Temporalio::Api::OperatorService::V1::ListSearchAttributesRequest, ::Temporalio::Api::OperatorService::V1::ListSearchAttributesResponse
            # DeleteNamespace synchronously deletes a namespace and asynchronously reclaims all namespace resources.
            # (-- api-linter: core::0135::method-signature=disabled
            #     aip.dev/not-precedent: DeleteNamespace RPC doesn't follow Google API format. --)
            # (-- api-linter: core::0135::response-message-name=disabled
            #     aip.dev/not-precedent: DeleteNamespace RPC doesn't follow Google API format. --)
            rpc :DeleteNamespace, ::Temporalio::Api::OperatorService::V1::DeleteNamespaceRequest, ::Temporalio::Api::OperatorService::V1::DeleteNamespaceResponse
            # AddOrUpdateRemoteCluster adds or updates remote cluster.
            rpc :AddOrUpdateRemoteCluster, ::Temporalio::Api::OperatorService::V1::AddOrUpdateRemoteClusterRequest, ::Temporalio::Api::OperatorService::V1::AddOrUpdateRemoteClusterResponse
            # RemoveRemoteCluster removes remote cluster.
            rpc :RemoveRemoteCluster, ::Temporalio::Api::OperatorService::V1::RemoveRemoteClusterRequest, ::Temporalio::Api::OperatorService::V1::RemoveRemoteClusterResponse
            # ListClusters returns information about Temporal clusters.
            rpc :ListClusters, ::Temporalio::Api::OperatorService::V1::ListClustersRequest, ::Temporalio::Api::OperatorService::V1::ListClustersResponse
          end

          Stub = Service.rpc_stub_class
        end
        # (-- Search Attribute --)
      end
    end
  end
end
