-
Notifications
You must be signed in to change notification settings - Fork 2.1k
/
errors.go
159 lines (136 loc) · 6.59 KB
/
errors.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
package cloudwatchlogs
import (
"github.com/aws/aws-sdk-go/private/protocol"
)
const (
// ErrCodeAccessDeniedException for service response error code
// "AccessDeniedException".
//
// You don't have sufficient permissions to perform this action.
ErrCodeAccessDeniedException = "AccessDeniedException"
// ErrCodeConflictException for service response error code
// "ConflictException".
//
// This operation attempted to create a resource that already exists.
ErrCodeConflictException = "ConflictException"
// ErrCodeDataAlreadyAcceptedException for service response error code
// "DataAlreadyAcceptedException".
//
// The event was already logged.
//
// PutLogEvents actions are now always accepted and never return DataAlreadyAcceptedException
// regardless of whether a given batch of log events has already been accepted.
ErrCodeDataAlreadyAcceptedException = "DataAlreadyAcceptedException"
// ErrCodeInvalidOperationException for service response error code
// "InvalidOperationException".
//
// The operation is not valid on the specified resource.
ErrCodeInvalidOperationException = "InvalidOperationException"
// ErrCodeInvalidParameterException for service response error code
// "InvalidParameterException".
//
// A parameter is specified incorrectly.
ErrCodeInvalidParameterException = "InvalidParameterException"
// ErrCodeInvalidSequenceTokenException for service response error code
// "InvalidSequenceTokenException".
//
// The sequence token is not valid. You can get the correct sequence token in
// the expectedSequenceToken field in the InvalidSequenceTokenException message.
//
// PutLogEvents actions are now always accepted and never return InvalidSequenceTokenException
// regardless of receiving an invalid sequence token.
ErrCodeInvalidSequenceTokenException = "InvalidSequenceTokenException"
// ErrCodeLimitExceededException for service response error code
// "LimitExceededException".
//
// You have reached the maximum number of resources that can be created.
ErrCodeLimitExceededException = "LimitExceededException"
// ErrCodeMalformedQueryException for service response error code
// "MalformedQueryException".
//
// The query string is not valid. Details about this error are displayed in
// a QueryCompileError object. For more information, see QueryCompileError (https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_QueryCompileError.html).
//
// For more information about valid query syntax, see CloudWatch Logs Insights
// Query Syntax (https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_QuerySyntax.html).
ErrCodeMalformedQueryException = "MalformedQueryException"
// ErrCodeOperationAbortedException for service response error code
// "OperationAbortedException".
//
// Multiple concurrent requests to update the same resource were in conflict.
ErrCodeOperationAbortedException = "OperationAbortedException"
// ErrCodeResourceAlreadyExistsException for service response error code
// "ResourceAlreadyExistsException".
//
// The specified resource already exists.
ErrCodeResourceAlreadyExistsException = "ResourceAlreadyExistsException"
// ErrCodeResourceNotFoundException for service response error code
// "ResourceNotFoundException".
//
// The specified resource does not exist.
ErrCodeResourceNotFoundException = "ResourceNotFoundException"
// ErrCodeServiceQuotaExceededException for service response error code
// "ServiceQuotaExceededException".
//
// This request exceeds a service quota.
ErrCodeServiceQuotaExceededException = "ServiceQuotaExceededException"
// ErrCodeServiceUnavailableException for service response error code
// "ServiceUnavailableException".
//
// The service cannot complete the request.
ErrCodeServiceUnavailableException = "ServiceUnavailableException"
// ErrCodeSessionStreamingException for service response error code
// "SessionStreamingException".
//
// his exception is returned if an unknown error occurs during a Live Tail session.
ErrCodeSessionStreamingException = "SessionStreamingException"
// ErrCodeSessionTimeoutException for service response error code
// "SessionTimeoutException".
//
// This exception is returned in a Live Tail stream when the Live Tail session
// times out. Live Tail sessions time out after three hours.
ErrCodeSessionTimeoutException = "SessionTimeoutException"
// ErrCodeThrottlingException for service response error code
// "ThrottlingException".
//
// The request was throttled because of quota limits.
ErrCodeThrottlingException = "ThrottlingException"
// ErrCodeTooManyTagsException for service response error code
// "TooManyTagsException".
//
// A resource can have no more than 50 tags.
ErrCodeTooManyTagsException = "TooManyTagsException"
// ErrCodeUnrecognizedClientException for service response error code
// "UnrecognizedClientException".
//
// The most likely cause is an Amazon Web Services access key ID or secret key
// that's not valid.
ErrCodeUnrecognizedClientException = "UnrecognizedClientException"
// ErrCodeValidationException for service response error code
// "ValidationException".
//
// One of the parameters for the request is not valid.
ErrCodeValidationException = "ValidationException"
)
var exceptionFromCode = map[string]func(protocol.ResponseMetadata) error{
"AccessDeniedException": newErrorAccessDeniedException,
"ConflictException": newErrorConflictException,
"DataAlreadyAcceptedException": newErrorDataAlreadyAcceptedException,
"InvalidOperationException": newErrorInvalidOperationException,
"InvalidParameterException": newErrorInvalidParameterException,
"InvalidSequenceTokenException": newErrorInvalidSequenceTokenException,
"LimitExceededException": newErrorLimitExceededException,
"MalformedQueryException": newErrorMalformedQueryException,
"OperationAbortedException": newErrorOperationAbortedException,
"ResourceAlreadyExistsException": newErrorResourceAlreadyExistsException,
"ResourceNotFoundException": newErrorResourceNotFoundException,
"ServiceQuotaExceededException": newErrorServiceQuotaExceededException,
"ServiceUnavailableException": newErrorServiceUnavailableException,
"SessionStreamingException": newErrorSessionStreamingException,
"SessionTimeoutException": newErrorSessionTimeoutException,
"ThrottlingException": newErrorThrottlingException,
"TooManyTagsException": newErrorTooManyTagsException,
"UnrecognizedClientException": newErrorUnrecognizedClientException,
"ValidationException": newErrorValidationException,
}