Enum value maps for OperationMetadata_State.
var ( OperationMetadata_State_name = map[int32]string{ 0: "STATE_UNSPECIFIED", 1: "CREATED", 2: "RUNNING", 3: "DONE", 4: "CANCELLED", } OperationMetadata_State_value = map[string]int32{ "STATE_UNSPECIFIED": 0, "CREATED": 1, "RUNNING": 2, "DONE": 3, "CANCELLED": 4, } )
var File_google_monitoring_metricsscope_v1_metrics_scope_proto protoreflect.FileDescriptor
var File_google_monitoring_metricsscope_v1_metrics_scopes_proto protoreflect.FileDescriptor
func RegisterMetricsScopesServer(s *grpc.Server, srv MetricsScopesServer)
Request for the `CreateMonitoredProject` method.
type CreateMonitoredProjectRequest struct { // Required. The resource name of the existing `Metrics Scope` that will monitor this // project. // Example: // `locations/global/metricsScopes/{SCOPING_PROJECT_ID_OR_NUMBER}` Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"` // Required. The initial `MonitoredProject` configuration. // Specify only the `monitored_project.name` field. All other fields are // ignored. The `monitored_project.name` must be in the format: // `locations/global/metricsScopes/{SCOPING_PROJECT_ID_OR_NUMBER}/projects/{MONITORED_PROJECT_ID_OR_NUMBER}` MonitoredProject *MonitoredProject `protobuf:"bytes,2,opt,name=monitored_project,json=monitoredProject,proto3" json:"monitored_project,omitempty"` // contains filtered or unexported fields }
func (*CreateMonitoredProjectRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateMonitoredProjectRequest.ProtoReflect.Descriptor instead.
func (x *CreateMonitoredProjectRequest) GetMonitoredProject() *MonitoredProject
func (x *CreateMonitoredProjectRequest) GetParent() string
func (*CreateMonitoredProjectRequest) ProtoMessage()
func (x *CreateMonitoredProjectRequest) ProtoReflect() protoreflect.Message
func (x *CreateMonitoredProjectRequest) Reset()
func (x *CreateMonitoredProjectRequest) String() string
Request for the `DeleteMonitoredProject` method.
type DeleteMonitoredProjectRequest struct { // Required. The resource name of the `MonitoredProject`. // Example: // `locations/global/metricsScopes/{SCOPING_PROJECT_ID_OR_NUMBER}/projects/{MONITORED_PROJECT_ID_OR_NUMBER}` // // Authorization requires the following [Google // IAM](https://cloud.google.com/iam) permissions on both the `Metrics Scope` // and on the `MonitoredProject`: `monitoring.metricsScopes.link` Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*DeleteMonitoredProjectRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteMonitoredProjectRequest.ProtoReflect.Descriptor instead.
func (x *DeleteMonitoredProjectRequest) GetName() string
func (*DeleteMonitoredProjectRequest) ProtoMessage()
func (x *DeleteMonitoredProjectRequest) ProtoReflect() protoreflect.Message
func (x *DeleteMonitoredProjectRequest) Reset()
func (x *DeleteMonitoredProjectRequest) String() string
Request for the `GetMetricsScope` method.
type GetMetricsScopeRequest struct { // Required. The resource name of the `Metrics Scope`. // Example: // `locations/global/metricsScopes/{SCOPING_PROJECT_ID_OR_NUMBER}` Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*GetMetricsScopeRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetMetricsScopeRequest.ProtoReflect.Descriptor instead.
func (x *GetMetricsScopeRequest) GetName() string
func (*GetMetricsScopeRequest) ProtoMessage()
func (x *GetMetricsScopeRequest) ProtoReflect() protoreflect.Message
func (x *GetMetricsScopeRequest) Reset()
func (x *GetMetricsScopeRequest) String() string
Request for the `ListMetricsScopesByMonitoredProject` method.
type ListMetricsScopesByMonitoredProjectRequest struct { // Required. The resource name of the `Monitored Project` being requested. // Example: // `projects/{MONITORED_PROJECT_ID_OR_NUMBER}` MonitoredResourceContainer string `protobuf:"bytes,1,opt,name=monitored_resource_container,json=monitoredResourceContainer,proto3" json:"monitored_resource_container,omitempty"` // contains filtered or unexported fields }
func (*ListMetricsScopesByMonitoredProjectRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListMetricsScopesByMonitoredProjectRequest.ProtoReflect.Descriptor instead.
func (x *ListMetricsScopesByMonitoredProjectRequest) GetMonitoredResourceContainer() string
func (*ListMetricsScopesByMonitoredProjectRequest) ProtoMessage()
func (x *ListMetricsScopesByMonitoredProjectRequest) ProtoReflect() protoreflect.Message
func (x *ListMetricsScopesByMonitoredProjectRequest) Reset()
func (x *ListMetricsScopesByMonitoredProjectRequest) String() string
Response for the `ListMetricsScopesByMonitoredProject` method.
type ListMetricsScopesByMonitoredProjectResponse struct { // A set of all metrics scopes that the specified monitored project has been // added to. MetricsScopes []*MetricsScope `protobuf:"bytes,1,rep,name=metrics_scopes,json=metricsScopes,proto3" json:"metrics_scopes,omitempty"` // contains filtered or unexported fields }
func (*ListMetricsScopesByMonitoredProjectResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListMetricsScopesByMonitoredProjectResponse.ProtoReflect.Descriptor instead.
func (x *ListMetricsScopesByMonitoredProjectResponse) GetMetricsScopes() []*MetricsScope
func (*ListMetricsScopesByMonitoredProjectResponse) ProtoMessage()
func (x *ListMetricsScopesByMonitoredProjectResponse) ProtoReflect() protoreflect.Message
func (x *ListMetricsScopesByMonitoredProjectResponse) Reset()
func (x *ListMetricsScopesByMonitoredProjectResponse) String() string
Represents a [Metrics Scope](https://cloud.google.com/monitoring/settings#concept-scope) in Cloud Monitoring, which specifies one or more Google projects and zero or more AWS accounts to monitor together.
type MetricsScope struct { // Immutable. The resource name of the Monitoring Metrics Scope. // On input, the resource name can be specified with the // scoping project ID or number. On output, the resource name is // specified with the scoping project number. // Example: // `locations/global/metricsScopes/{SCOPING_PROJECT_ID_OR_NUMBER}` Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Output only. The time when this `Metrics Scope` was created. CreateTime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"` // Output only. The time when this `Metrics Scope` record was last updated. UpdateTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"` // Output only. The list of projects monitored by this `Metrics Scope`. MonitoredProjects []*MonitoredProject `protobuf:"bytes,4,rep,name=monitored_projects,json=monitoredProjects,proto3" json:"monitored_projects,omitempty"` // contains filtered or unexported fields }
func (*MetricsScope) Descriptor() ([]byte, []int)
Deprecated: Use MetricsScope.ProtoReflect.Descriptor instead.
func (x *MetricsScope) GetCreateTime() *timestamppb.Timestamp
func (x *MetricsScope) GetMonitoredProjects() []*MonitoredProject
func (x *MetricsScope) GetName() string
func (x *MetricsScope) GetUpdateTime() *timestamppb.Timestamp
func (*MetricsScope) ProtoMessage()
func (x *MetricsScope) ProtoReflect() protoreflect.Message
func (x *MetricsScope) Reset()
func (x *MetricsScope) String() string
MetricsScopesClient is the client API for MetricsScopes service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type MetricsScopesClient interface { // Returns a specific `Metrics Scope`. GetMetricsScope(ctx context.Context, in *GetMetricsScopeRequest, opts ...grpc.CallOption) (*MetricsScope, error) // Returns a list of every `Metrics Scope` that a specific `MonitoredProject` // has been added to. The metrics scope representing the specified monitored // project will always be the first entry in the response. ListMetricsScopesByMonitoredProject(ctx context.Context, in *ListMetricsScopesByMonitoredProjectRequest, opts ...grpc.CallOption) (*ListMetricsScopesByMonitoredProjectResponse, error) // Adds a `MonitoredProject` with the given project ID // to the specified `Metrics Scope`. CreateMonitoredProject(ctx context.Context, in *CreateMonitoredProjectRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) // Deletes a `MonitoredProject` from the specified `Metrics Scope`. DeleteMonitoredProject(ctx context.Context, in *DeleteMonitoredProjectRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) }
func NewMetricsScopesClient(cc grpc.ClientConnInterface) MetricsScopesClient
MetricsScopesServer is the server API for MetricsScopes service.
type MetricsScopesServer interface { // Returns a specific `Metrics Scope`. GetMetricsScope(context.Context, *GetMetricsScopeRequest) (*MetricsScope, error) // Returns a list of every `Metrics Scope` that a specific `MonitoredProject` // has been added to. The metrics scope representing the specified monitored // project will always be the first entry in the response. ListMetricsScopesByMonitoredProject(context.Context, *ListMetricsScopesByMonitoredProjectRequest) (*ListMetricsScopesByMonitoredProjectResponse, error) // Adds a `MonitoredProject` with the given project ID // to the specified `Metrics Scope`. CreateMonitoredProject(context.Context, *CreateMonitoredProjectRequest) (*longrunningpb.Operation, error) // Deletes a `MonitoredProject` from the specified `Metrics Scope`. DeleteMonitoredProject(context.Context, *DeleteMonitoredProjectRequest) (*longrunningpb.Operation, error) }
A [project being monitored](https://cloud.google.com/monitoring/settings/multiple-projects#create-multi) by a `Metrics Scope`.
type MonitoredProject struct { // Immutable. The resource name of the `MonitoredProject`. On input, the resource name // includes the scoping project ID and monitored project ID. On output, it // contains the equivalent project numbers. // Example: // `locations/global/metricsScopes/{SCOPING_PROJECT_ID_OR_NUMBER}/projects/{MONITORED_PROJECT_ID_OR_NUMBER}` Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Output only. The time when this `MonitoredProject` was created. CreateTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"` // contains filtered or unexported fields }
func (*MonitoredProject) Descriptor() ([]byte, []int)
Deprecated: Use MonitoredProject.ProtoReflect.Descriptor instead.
func (x *MonitoredProject) GetCreateTime() *timestamppb.Timestamp
func (x *MonitoredProject) GetName() string
func (*MonitoredProject) ProtoMessage()
func (x *MonitoredProject) ProtoReflect() protoreflect.Message
func (x *MonitoredProject) Reset()
func (x *MonitoredProject) String() string
Contains metadata for longrunning operation for the edit Metrics Scope endpoints.
type OperationMetadata struct { // Current state of the batch operation. State OperationMetadata_State `protobuf:"varint,1,opt,name=state,proto3,enum=google.monitoring.metricsscope.v1.OperationMetadata_State" json:"state,omitempty"` // The time when the batch request was received. CreateTime *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"` // The time when the operation result was last updated. UpdateTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"` // contains filtered or unexported fields }
func (*OperationMetadata) Descriptor() ([]byte, []int)
Deprecated: Use OperationMetadata.ProtoReflect.Descriptor instead.
func (x *OperationMetadata) GetCreateTime() *timestamppb.Timestamp
func (x *OperationMetadata) GetState() OperationMetadata_State
func (x *OperationMetadata) GetUpdateTime() *timestamppb.Timestamp
func (*OperationMetadata) ProtoMessage()
func (x *OperationMetadata) ProtoReflect() protoreflect.Message
func (x *OperationMetadata) Reset()
func (x *OperationMetadata) String() string
Batch operation states.
type OperationMetadata_State int32
const ( // Invalid. OperationMetadata_STATE_UNSPECIFIED OperationMetadata_State = 0 // Request has been received. OperationMetadata_CREATED OperationMetadata_State = 1 // Request is actively being processed. OperationMetadata_RUNNING OperationMetadata_State = 2 // The batch processing is done. OperationMetadata_DONE OperationMetadata_State = 3 // The batch processing was cancelled. OperationMetadata_CANCELLED OperationMetadata_State = 4 )
func (OperationMetadata_State) Descriptor() protoreflect.EnumDescriptor
func (x OperationMetadata_State) Enum() *OperationMetadata_State
func (OperationMetadata_State) EnumDescriptor() ([]byte, []int)
Deprecated: Use OperationMetadata_State.Descriptor instead.
func (x OperationMetadata_State) Number() protoreflect.EnumNumber
func (x OperationMetadata_State) String() string
func (OperationMetadata_State) Type() protoreflect.EnumType
UnimplementedMetricsScopesServer can be embedded to have forward compatible implementations.
type UnimplementedMetricsScopesServer struct { }
func (*UnimplementedMetricsScopesServer) CreateMonitoredProject(context.Context, *CreateMonitoredProjectRequest) (*longrunningpb.Operation, error)
func (*UnimplementedMetricsScopesServer) DeleteMonitoredProject(context.Context, *DeleteMonitoredProjectRequest) (*longrunningpb.Operation, error)
func (*UnimplementedMetricsScopesServer) GetMetricsScope(context.Context, *GetMetricsScopeRequest) (*MetricsScope, error)
func (*UnimplementedMetricsScopesServer) ListMetricsScopesByMonitoredProject(context.Context, *ListMetricsScopesByMonitoredProjectRequest) (*ListMetricsScopesByMonitoredProjectResponse, error)