Files
tasks/client/matching/metric_client_gen.go
Michael SnowdenandGitHub b4ff3563fa Inline metrics scope names used in generated files (#4575)
<!-- Describe what has changed in this PR -->
**What changed?**


<!-- Tell your future self why have you made these changes -->
**Why?**


<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
**How did you test it?**


<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
**Potential risks**


<!-- Is this PR a hotfix candidate or require that a notification be
sent to the broader community? (Yes/No) -->
**Is hotfix candidate?**
2023-09-05 23:44:49 +00:00

203 lines
7.1 KiB
Go

// The MIT License
//
// Copyright (c) 2020 Temporal Technologies Inc. All rights reserved.
//
// Copyright (c) 2020 Uber Technologies, Inc.
//
// 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.
// Code generated by cmd/tools/rpcwrappers. DO NOT EDIT.
package matching
import (
"context"
"go.temporal.io/server/api/matchingservice/v1"
"google.golang.org/grpc"
)
func (c *metricClient) ApplyTaskQueueUserDataReplicationEvent(
ctx context.Context,
request *matchingservice.ApplyTaskQueueUserDataReplicationEventRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.ApplyTaskQueueUserDataReplicationEventResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientApplyTaskQueueUserDataReplicationEvent")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.ApplyTaskQueueUserDataReplicationEvent(ctx, request, opts...)
}
func (c *metricClient) CancelOutstandingPoll(
ctx context.Context,
request *matchingservice.CancelOutstandingPollRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.CancelOutstandingPollResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientCancelOutstandingPoll")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.CancelOutstandingPoll(ctx, request, opts...)
}
func (c *metricClient) DescribeTaskQueue(
ctx context.Context,
request *matchingservice.DescribeTaskQueueRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.DescribeTaskQueueResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientDescribeTaskQueue")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.DescribeTaskQueue(ctx, request, opts...)
}
func (c *metricClient) ForceUnloadTaskQueue(
ctx context.Context,
request *matchingservice.ForceUnloadTaskQueueRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.ForceUnloadTaskQueueResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientForceUnloadTaskQueue")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.ForceUnloadTaskQueue(ctx, request, opts...)
}
func (c *metricClient) GetBuildIdTaskQueueMapping(
ctx context.Context,
request *matchingservice.GetBuildIdTaskQueueMappingRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.GetBuildIdTaskQueueMappingResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientGetBuildIdTaskQueueMapping")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.GetBuildIdTaskQueueMapping(ctx, request, opts...)
}
func (c *metricClient) GetTaskQueueUserData(
ctx context.Context,
request *matchingservice.GetTaskQueueUserDataRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.GetTaskQueueUserDataResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientGetTaskQueueUserData")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.GetTaskQueueUserData(ctx, request, opts...)
}
func (c *metricClient) GetWorkerBuildIdCompatibility(
ctx context.Context,
request *matchingservice.GetWorkerBuildIdCompatibilityRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.GetWorkerBuildIdCompatibilityResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientGetWorkerBuildIdCompatibility")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.GetWorkerBuildIdCompatibility(ctx, request, opts...)
}
func (c *metricClient) ListTaskQueuePartitions(
ctx context.Context,
request *matchingservice.ListTaskQueuePartitionsRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.ListTaskQueuePartitionsResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientListTaskQueuePartitions")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.ListTaskQueuePartitions(ctx, request, opts...)
}
func (c *metricClient) ReplicateTaskQueueUserData(
ctx context.Context,
request *matchingservice.ReplicateTaskQueueUserDataRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.ReplicateTaskQueueUserDataResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientReplicateTaskQueueUserData")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.ReplicateTaskQueueUserData(ctx, request, opts...)
}
func (c *metricClient) RespondQueryTaskCompleted(
ctx context.Context,
request *matchingservice.RespondQueryTaskCompletedRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.RespondQueryTaskCompletedResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientRespondQueryTaskCompleted")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.RespondQueryTaskCompleted(ctx, request, opts...)
}
func (c *metricClient) UpdateTaskQueueUserData(
ctx context.Context,
request *matchingservice.UpdateTaskQueueUserDataRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.UpdateTaskQueueUserDataResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientUpdateTaskQueueUserData")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.UpdateTaskQueueUserData(ctx, request, opts...)
}
func (c *metricClient) UpdateWorkerBuildIdCompatibility(
ctx context.Context,
request *matchingservice.UpdateWorkerBuildIdCompatibilityRequest,
opts ...grpc.CallOption,
) (_ *matchingservice.UpdateWorkerBuildIdCompatibilityResponse, retError error) {
metricsHandler, startTime := c.startMetricsRecording(ctx, "MatchingClientUpdateWorkerBuildIdCompatibility")
defer func() {
c.finishMetricsRecording(metricsHandler, startTime, retError)
}()
return c.client.UpdateWorkerBuildIdCompatibility(ctx, request, opts...)
}