mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-05-06 22:18:28 +00:00
Update Go AWS SDK to the latest version
This commit is contained in:
committed by
Andrey Smirnov
parent
d08be990ef
commit
94a72b23ff
+4185
File diff suppressed because it is too large
Load Diff
+31
@@ -0,0 +1,31 @@
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
// Package quicksight provides the client and types for making API
|
||||
// requests to Amazon QuickSight.
|
||||
//
|
||||
// Amazon QuickSight is a fully managed, serverless, cloud business intelligence
|
||||
// service that makes it easy to extend data and insights to every user in your
|
||||
// organization. This API interface reference contains documentation for a programming
|
||||
// interface that you can use to manage Amazon QuickSight.
|
||||
//
|
||||
// See https://docs.aws.amazon.com/goto/WebAPI/quicksight-2018-04-01 for more information on this service.
|
||||
//
|
||||
// See quicksight package documentation for more information.
|
||||
// https://docs.aws.amazon.com/sdk-for-go/api/service/quicksight/
|
||||
//
|
||||
// Using the Client
|
||||
//
|
||||
// To contact Amazon QuickSight with the SDK use the New function to create
|
||||
// a new service client. With that client you can make API requests to the service.
|
||||
// These clients are safe to use concurrently.
|
||||
//
|
||||
// See the SDK's documentation for more information on how to use the SDK.
|
||||
// https://docs.aws.amazon.com/sdk-for-go/api/
|
||||
//
|
||||
// See aws.Config documentation for more information on configuring SDK clients.
|
||||
// https://docs.aws.amazon.com/sdk-for-go/api/aws/#Config
|
||||
//
|
||||
// See the Amazon QuickSight client QuickSight for more
|
||||
// information on creating client for this service.
|
||||
// https://docs.aws.amazon.com/sdk-for-go/api/service/quicksight/#New
|
||||
package quicksight
|
||||
+107
@@ -0,0 +1,107 @@
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
package quicksight
|
||||
|
||||
const (
|
||||
|
||||
// ErrCodeAccessDeniedException for service response error code
|
||||
// "AccessDeniedException".
|
||||
//
|
||||
// You don't have access to this. The provided credentials couldn't be validated.
|
||||
// You might not be authorized to carry out the request. Ensure that your account
|
||||
// is authorized to use the Amazon QuickSight service, that your policies have
|
||||
// the correct permissions, and that you are using the correct access keys.
|
||||
ErrCodeAccessDeniedException = "AccessDeniedException"
|
||||
|
||||
// ErrCodeDomainNotWhitelistedException for service response error code
|
||||
// "DomainNotWhitelistedException".
|
||||
//
|
||||
// The domain specified is not on the allowlist. All domains for embedded dashboards
|
||||
// must be added to the approved list by an Amazon QuickSight admin.
|
||||
ErrCodeDomainNotWhitelistedException = "DomainNotWhitelistedException"
|
||||
|
||||
// ErrCodeIdentityTypeNotSupportedException for service response error code
|
||||
// "IdentityTypeNotSupportedException".
|
||||
//
|
||||
// The identity type specified is not supported. Supported identity types include
|
||||
// IAM and QUICKSIGHT.
|
||||
ErrCodeIdentityTypeNotSupportedException = "IdentityTypeNotSupportedException"
|
||||
|
||||
// ErrCodeInternalFailureException for service response error code
|
||||
// "InternalFailureException".
|
||||
//
|
||||
// An internal failure occurred.
|
||||
ErrCodeInternalFailureException = "InternalFailureException"
|
||||
|
||||
// ErrCodeInvalidNextTokenException for service response error code
|
||||
// "InvalidNextTokenException".
|
||||
//
|
||||
// The NextToken value isn't valid.
|
||||
ErrCodeInvalidNextTokenException = "InvalidNextTokenException"
|
||||
|
||||
// ErrCodeInvalidParameterValueException for service response error code
|
||||
// "InvalidParameterValueException".
|
||||
//
|
||||
// One or more parameters don't have a valid value.
|
||||
ErrCodeInvalidParameterValueException = "InvalidParameterValueException"
|
||||
|
||||
// ErrCodeLimitExceededException for service response error code
|
||||
// "LimitExceededException".
|
||||
//
|
||||
// A limit is exceeded.
|
||||
ErrCodeLimitExceededException = "LimitExceededException"
|
||||
|
||||
// ErrCodePreconditionNotMetException for service response error code
|
||||
// "PreconditionNotMetException".
|
||||
//
|
||||
// One or more preconditions aren't met.
|
||||
ErrCodePreconditionNotMetException = "PreconditionNotMetException"
|
||||
|
||||
// ErrCodeResourceExistsException for service response error code
|
||||
// "ResourceExistsException".
|
||||
//
|
||||
// The resource specified doesn't exist.
|
||||
ErrCodeResourceExistsException = "ResourceExistsException"
|
||||
|
||||
// ErrCodeResourceNotFoundException for service response error code
|
||||
// "ResourceNotFoundException".
|
||||
//
|
||||
// One or more resources can't be found.
|
||||
ErrCodeResourceNotFoundException = "ResourceNotFoundException"
|
||||
|
||||
// ErrCodeResourceUnavailableException for service response error code
|
||||
// "ResourceUnavailableException".
|
||||
//
|
||||
// This resource is currently unavailable.
|
||||
ErrCodeResourceUnavailableException = "ResourceUnavailableException"
|
||||
|
||||
// ErrCodeSessionLifetimeInMinutesInvalidException for service response error code
|
||||
// "SessionLifetimeInMinutesInvalidException".
|
||||
//
|
||||
// The number of minutes specified for the lifetime of a session is not valid.
|
||||
// The session lifetime must be from 15 to 600 minutes.
|
||||
ErrCodeSessionLifetimeInMinutesInvalidException = "SessionLifetimeInMinutesInvalidException"
|
||||
|
||||
// ErrCodeThrottlingException for service response error code
|
||||
// "ThrottlingException".
|
||||
//
|
||||
// Access is throttled.
|
||||
ErrCodeThrottlingException = "ThrottlingException"
|
||||
|
||||
// ErrCodeUnsupportedUserEditionException for service response error code
|
||||
// "UnsupportedUserEditionException".
|
||||
//
|
||||
// This error indicates that you are calling an operation on an Amazon QuickSight
|
||||
// subscription where the edition doesn't include support for that operation.
|
||||
// Amazon QuickSight currently has Standard Edition and Enterprise Edition.
|
||||
// Not every operation and capability is available in every edition.
|
||||
ErrCodeUnsupportedUserEditionException = "UnsupportedUserEditionException"
|
||||
|
||||
// ErrCodeUserNotFoundException for service response error code
|
||||
// "QuickSightUserNotFoundException".
|
||||
//
|
||||
// The user is not found. This error can happen in any operation that requires
|
||||
// finding a user based on a provided user name, such as DeleteUser, DescribeUser,
|
||||
// and so on.
|
||||
ErrCodeUserNotFoundException = "QuickSightUserNotFoundException"
|
||||
)
|
||||
+128
@@ -0,0 +1,128 @@
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
// Package quicksightiface provides an interface to enable mocking the Amazon QuickSight service client
|
||||
// for testing your code.
|
||||
//
|
||||
// It is important to note that this interface will have breaking changes
|
||||
// when the service model is updated and adds new API operations, paginators,
|
||||
// and waiters.
|
||||
package quicksightiface
|
||||
|
||||
import (
|
||||
"github.com/aws/aws-sdk-go/aws"
|
||||
"github.com/aws/aws-sdk-go/aws/request"
|
||||
"github.com/aws/aws-sdk-go/service/quicksight"
|
||||
)
|
||||
|
||||
// QuickSightAPI provides an interface to enable mocking the
|
||||
// quicksight.QuickSight service client's API operation,
|
||||
// paginators, and waiters. This make unit testing your code that calls out
|
||||
// to the SDK's service client's calls easier.
|
||||
//
|
||||
// The best way to use this interface is so the SDK's service client's calls
|
||||
// can be stubbed out for unit testing your code with the SDK without needing
|
||||
// to inject custom request handlers into the SDK's request pipeline.
|
||||
//
|
||||
// // myFunc uses an SDK service client to make a request to
|
||||
// // Amazon QuickSight.
|
||||
// func myFunc(svc quicksightiface.QuickSightAPI) bool {
|
||||
// // Make svc.CreateGroup request
|
||||
// }
|
||||
//
|
||||
// func main() {
|
||||
// sess := session.New()
|
||||
// svc := quicksight.New(sess)
|
||||
//
|
||||
// myFunc(svc)
|
||||
// }
|
||||
//
|
||||
// In your _test.go file:
|
||||
//
|
||||
// // Define a mock struct to be used in your unit tests of myFunc.
|
||||
// type mockQuickSightClient struct {
|
||||
// quicksightiface.QuickSightAPI
|
||||
// }
|
||||
// func (m *mockQuickSightClient) CreateGroup(input *quicksight.CreateGroupInput) (*quicksight.CreateGroupOutput, error) {
|
||||
// // mock response/functionality
|
||||
// }
|
||||
//
|
||||
// func TestMyFunc(t *testing.T) {
|
||||
// // Setup Test
|
||||
// mockSvc := &mockQuickSightClient{}
|
||||
//
|
||||
// myfunc(mockSvc)
|
||||
//
|
||||
// // Verify myFunc's functionality
|
||||
// }
|
||||
//
|
||||
// It is important to note that this interface will have breaking changes
|
||||
// when the service model is updated and adds new API operations, paginators,
|
||||
// and waiters. Its suggested to use the pattern above for testing, or using
|
||||
// tooling to generate mocks to satisfy the interfaces.
|
||||
type QuickSightAPI interface {
|
||||
CreateGroup(*quicksight.CreateGroupInput) (*quicksight.CreateGroupOutput, error)
|
||||
CreateGroupWithContext(aws.Context, *quicksight.CreateGroupInput, ...request.Option) (*quicksight.CreateGroupOutput, error)
|
||||
CreateGroupRequest(*quicksight.CreateGroupInput) (*request.Request, *quicksight.CreateGroupOutput)
|
||||
|
||||
CreateGroupMembership(*quicksight.CreateGroupMembershipInput) (*quicksight.CreateGroupMembershipOutput, error)
|
||||
CreateGroupMembershipWithContext(aws.Context, *quicksight.CreateGroupMembershipInput, ...request.Option) (*quicksight.CreateGroupMembershipOutput, error)
|
||||
CreateGroupMembershipRequest(*quicksight.CreateGroupMembershipInput) (*request.Request, *quicksight.CreateGroupMembershipOutput)
|
||||
|
||||
DeleteGroup(*quicksight.DeleteGroupInput) (*quicksight.DeleteGroupOutput, error)
|
||||
DeleteGroupWithContext(aws.Context, *quicksight.DeleteGroupInput, ...request.Option) (*quicksight.DeleteGroupOutput, error)
|
||||
DeleteGroupRequest(*quicksight.DeleteGroupInput) (*request.Request, *quicksight.DeleteGroupOutput)
|
||||
|
||||
DeleteGroupMembership(*quicksight.DeleteGroupMembershipInput) (*quicksight.DeleteGroupMembershipOutput, error)
|
||||
DeleteGroupMembershipWithContext(aws.Context, *quicksight.DeleteGroupMembershipInput, ...request.Option) (*quicksight.DeleteGroupMembershipOutput, error)
|
||||
DeleteGroupMembershipRequest(*quicksight.DeleteGroupMembershipInput) (*request.Request, *quicksight.DeleteGroupMembershipOutput)
|
||||
|
||||
DeleteUser(*quicksight.DeleteUserInput) (*quicksight.DeleteUserOutput, error)
|
||||
DeleteUserWithContext(aws.Context, *quicksight.DeleteUserInput, ...request.Option) (*quicksight.DeleteUserOutput, error)
|
||||
DeleteUserRequest(*quicksight.DeleteUserInput) (*request.Request, *quicksight.DeleteUserOutput)
|
||||
|
||||
DeleteUserByPrincipalId(*quicksight.DeleteUserByPrincipalIdInput) (*quicksight.DeleteUserByPrincipalIdOutput, error)
|
||||
DeleteUserByPrincipalIdWithContext(aws.Context, *quicksight.DeleteUserByPrincipalIdInput, ...request.Option) (*quicksight.DeleteUserByPrincipalIdOutput, error)
|
||||
DeleteUserByPrincipalIdRequest(*quicksight.DeleteUserByPrincipalIdInput) (*request.Request, *quicksight.DeleteUserByPrincipalIdOutput)
|
||||
|
||||
DescribeGroup(*quicksight.DescribeGroupInput) (*quicksight.DescribeGroupOutput, error)
|
||||
DescribeGroupWithContext(aws.Context, *quicksight.DescribeGroupInput, ...request.Option) (*quicksight.DescribeGroupOutput, error)
|
||||
DescribeGroupRequest(*quicksight.DescribeGroupInput) (*request.Request, *quicksight.DescribeGroupOutput)
|
||||
|
||||
DescribeUser(*quicksight.DescribeUserInput) (*quicksight.DescribeUserOutput, error)
|
||||
DescribeUserWithContext(aws.Context, *quicksight.DescribeUserInput, ...request.Option) (*quicksight.DescribeUserOutput, error)
|
||||
DescribeUserRequest(*quicksight.DescribeUserInput) (*request.Request, *quicksight.DescribeUserOutput)
|
||||
|
||||
GetDashboardEmbedUrl(*quicksight.GetDashboardEmbedUrlInput) (*quicksight.GetDashboardEmbedUrlOutput, error)
|
||||
GetDashboardEmbedUrlWithContext(aws.Context, *quicksight.GetDashboardEmbedUrlInput, ...request.Option) (*quicksight.GetDashboardEmbedUrlOutput, error)
|
||||
GetDashboardEmbedUrlRequest(*quicksight.GetDashboardEmbedUrlInput) (*request.Request, *quicksight.GetDashboardEmbedUrlOutput)
|
||||
|
||||
ListGroupMemberships(*quicksight.ListGroupMembershipsInput) (*quicksight.ListGroupMembershipsOutput, error)
|
||||
ListGroupMembershipsWithContext(aws.Context, *quicksight.ListGroupMembershipsInput, ...request.Option) (*quicksight.ListGroupMembershipsOutput, error)
|
||||
ListGroupMembershipsRequest(*quicksight.ListGroupMembershipsInput) (*request.Request, *quicksight.ListGroupMembershipsOutput)
|
||||
|
||||
ListGroups(*quicksight.ListGroupsInput) (*quicksight.ListGroupsOutput, error)
|
||||
ListGroupsWithContext(aws.Context, *quicksight.ListGroupsInput, ...request.Option) (*quicksight.ListGroupsOutput, error)
|
||||
ListGroupsRequest(*quicksight.ListGroupsInput) (*request.Request, *quicksight.ListGroupsOutput)
|
||||
|
||||
ListUserGroups(*quicksight.ListUserGroupsInput) (*quicksight.ListUserGroupsOutput, error)
|
||||
ListUserGroupsWithContext(aws.Context, *quicksight.ListUserGroupsInput, ...request.Option) (*quicksight.ListUserGroupsOutput, error)
|
||||
ListUserGroupsRequest(*quicksight.ListUserGroupsInput) (*request.Request, *quicksight.ListUserGroupsOutput)
|
||||
|
||||
ListUsers(*quicksight.ListUsersInput) (*quicksight.ListUsersOutput, error)
|
||||
ListUsersWithContext(aws.Context, *quicksight.ListUsersInput, ...request.Option) (*quicksight.ListUsersOutput, error)
|
||||
ListUsersRequest(*quicksight.ListUsersInput) (*request.Request, *quicksight.ListUsersOutput)
|
||||
|
||||
RegisterUser(*quicksight.RegisterUserInput) (*quicksight.RegisterUserOutput, error)
|
||||
RegisterUserWithContext(aws.Context, *quicksight.RegisterUserInput, ...request.Option) (*quicksight.RegisterUserOutput, error)
|
||||
RegisterUserRequest(*quicksight.RegisterUserInput) (*request.Request, *quicksight.RegisterUserOutput)
|
||||
|
||||
UpdateGroup(*quicksight.UpdateGroupInput) (*quicksight.UpdateGroupOutput, error)
|
||||
UpdateGroupWithContext(aws.Context, *quicksight.UpdateGroupInput, ...request.Option) (*quicksight.UpdateGroupOutput, error)
|
||||
UpdateGroupRequest(*quicksight.UpdateGroupInput) (*request.Request, *quicksight.UpdateGroupOutput)
|
||||
|
||||
UpdateUser(*quicksight.UpdateUserInput) (*quicksight.UpdateUserOutput, error)
|
||||
UpdateUserWithContext(aws.Context, *quicksight.UpdateUserInput, ...request.Option) (*quicksight.UpdateUserOutput, error)
|
||||
UpdateUserRequest(*quicksight.UpdateUserInput) (*request.Request, *quicksight.UpdateUserOutput)
|
||||
}
|
||||
|
||||
var _ QuickSightAPI = (*quicksight.QuickSight)(nil)
|
||||
+95
@@ -0,0 +1,95 @@
|
||||
// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
|
||||
|
||||
package quicksight
|
||||
|
||||
import (
|
||||
"github.com/aws/aws-sdk-go/aws"
|
||||
"github.com/aws/aws-sdk-go/aws/client"
|
||||
"github.com/aws/aws-sdk-go/aws/client/metadata"
|
||||
"github.com/aws/aws-sdk-go/aws/request"
|
||||
"github.com/aws/aws-sdk-go/aws/signer/v4"
|
||||
"github.com/aws/aws-sdk-go/private/protocol/restjson"
|
||||
)
|
||||
|
||||
// QuickSight provides the API operation methods for making requests to
|
||||
// Amazon QuickSight. See this package's package overview docs
|
||||
// for details on the service.
|
||||
//
|
||||
// QuickSight methods are safe to use concurrently. It is not safe to
|
||||
// modify mutate any of the struct's properties though.
|
||||
type QuickSight struct {
|
||||
*client.Client
|
||||
}
|
||||
|
||||
// Used for custom client initialization logic
|
||||
var initClient func(*client.Client)
|
||||
|
||||
// Used for custom request initialization logic
|
||||
var initRequest func(*request.Request)
|
||||
|
||||
// Service information constants
|
||||
const (
|
||||
ServiceName = "QuickSight" // Name of service.
|
||||
EndpointsID = "quicksight" // ID to lookup a service endpoint with.
|
||||
ServiceID = "QuickSight" // ServiceID is a unique identifer of a specific service.
|
||||
)
|
||||
|
||||
// New creates a new instance of the QuickSight client with a session.
|
||||
// If additional configuration is needed for the client instance use the optional
|
||||
// aws.Config parameter to add your extra config.
|
||||
//
|
||||
// Example:
|
||||
// // Create a QuickSight client from just a session.
|
||||
// svc := quicksight.New(mySession)
|
||||
//
|
||||
// // Create a QuickSight client with additional configuration
|
||||
// svc := quicksight.New(mySession, aws.NewConfig().WithRegion("us-west-2"))
|
||||
func New(p client.ConfigProvider, cfgs ...*aws.Config) *QuickSight {
|
||||
c := p.ClientConfig(EndpointsID, cfgs...)
|
||||
return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName)
|
||||
}
|
||||
|
||||
// newClient creates, initializes and returns a new service client instance.
|
||||
func newClient(cfg aws.Config, handlers request.Handlers, endpoint, signingRegion, signingName string) *QuickSight {
|
||||
svc := &QuickSight{
|
||||
Client: client.New(
|
||||
cfg,
|
||||
metadata.ClientInfo{
|
||||
ServiceName: ServiceName,
|
||||
ServiceID: ServiceID,
|
||||
SigningName: signingName,
|
||||
SigningRegion: signingRegion,
|
||||
Endpoint: endpoint,
|
||||
APIVersion: "2018-04-01",
|
||||
},
|
||||
handlers,
|
||||
),
|
||||
}
|
||||
|
||||
// Handlers
|
||||
svc.Handlers.Sign.PushBackNamed(v4.SignRequestHandler)
|
||||
svc.Handlers.Build.PushBackNamed(restjson.BuildHandler)
|
||||
svc.Handlers.Unmarshal.PushBackNamed(restjson.UnmarshalHandler)
|
||||
svc.Handlers.UnmarshalMeta.PushBackNamed(restjson.UnmarshalMetaHandler)
|
||||
svc.Handlers.UnmarshalError.PushBackNamed(restjson.UnmarshalErrorHandler)
|
||||
|
||||
// Run custom client initialization if present
|
||||
if initClient != nil {
|
||||
initClient(svc.Client)
|
||||
}
|
||||
|
||||
return svc
|
||||
}
|
||||
|
||||
// newRequest creates a new request for a QuickSight operation and runs any
|
||||
// custom request initialization.
|
||||
func (c *QuickSight) newRequest(op *request.Operation, params, data interface{}) *request.Request {
|
||||
req := c.NewRequest(op, params, data)
|
||||
|
||||
// Run custom request initialization if present
|
||||
if initRequest != nil {
|
||||
initRequest(req)
|
||||
}
|
||||
|
||||
return req
|
||||
}
|
||||
Reference in New Issue
Block a user