-
Notifications
You must be signed in to change notification settings - Fork 2.1k
/
errors.go
54 lines (45 loc) · 1.92 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
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
package ec2instanceconnect
import (
"github.com/aws/aws-sdk-go/private/protocol"
)
const (
// ErrCodeAuthException for service response error code
// "AuthException".
//
// Indicates that either your AWS credentials are invalid or you do not have
// access to the EC2 instance.
ErrCodeAuthException = "AuthException"
// ErrCodeEC2InstanceNotFoundException for service response error code
// "EC2InstanceNotFoundException".
//
// Indicates that the instance requested was not found in the given zone. Check
// that you have provided a valid instance ID and the correct zone.
ErrCodeEC2InstanceNotFoundException = "EC2InstanceNotFoundException"
// ErrCodeInvalidArgsException for service response error code
// "InvalidArgsException".
//
// Indicates that you provided bad input. Ensure you have a valid instance ID,
// the correct zone, and a valid SSH public key.
ErrCodeInvalidArgsException = "InvalidArgsException"
// ErrCodeServiceException for service response error code
// "ServiceException".
//
// Indicates that the service encountered an error. Follow the message's instructions
// and try again.
ErrCodeServiceException = "ServiceException"
// ErrCodeThrottlingException for service response error code
// "ThrottlingException".
//
// Indicates you have been making requests too frequently and have been throttled.
// Wait for a while and try again. If higher call volume is warranted contact
// AWS Support.
ErrCodeThrottlingException = "ThrottlingException"
)
var exceptionFromCode = map[string]func(protocol.ResponseMetadata) error{
"AuthException": newErrorAuthException,
"EC2InstanceNotFoundException": newErrorEC2InstanceNotFoundException,
"InvalidArgsException": newErrorInvalidArgsException,
"ServiceException": newErrorServiceException,
"ThrottlingException": newErrorThrottlingException,
}