1// Code generated by smithy-go-codegen DO NOT EDIT. 2 3package kinesisanalytics 4 5import ( 6 "context" 7 awsmiddleware "github.com/aws/aws-sdk-go-v2/aws/middleware" 8 "github.com/aws/aws-sdk-go-v2/aws/signer/v4" 9 "github.com/aws/smithy-go/middleware" 10 smithyhttp "github.com/aws/smithy-go/transport/http" 11) 12 13// This documentation is for version 1 of the Amazon Kinesis Data Analytics API, 14// which only supports SQL applications. Version 2 of the API supports SQL and Java 15// applications. For more information about version 2, see Amazon Kinesis Data 16// Analytics API V2 Documentation. Deletes output destination configuration from 17// your application configuration. Amazon Kinesis Analytics will no longer write 18// data from the corresponding in-application stream to the external output 19// destination. This operation requires permissions to perform the 20// kinesisanalytics:DeleteApplicationOutput action. 21func (c *Client) DeleteApplicationOutput(ctx context.Context, params *DeleteApplicationOutputInput, optFns ...func(*Options)) (*DeleteApplicationOutputOutput, error) { 22 if params == nil { 23 params = &DeleteApplicationOutputInput{} 24 } 25 26 result, metadata, err := c.invokeOperation(ctx, "DeleteApplicationOutput", params, optFns, addOperationDeleteApplicationOutputMiddlewares) 27 if err != nil { 28 return nil, err 29 } 30 31 out := result.(*DeleteApplicationOutputOutput) 32 out.ResultMetadata = metadata 33 return out, nil 34} 35 36// 37type DeleteApplicationOutputInput struct { 38 39 // Amazon Kinesis Analytics application name. 40 // 41 // This member is required. 42 ApplicationName *string 43 44 // Amazon Kinesis Analytics application version. You can use the 45 // DescribeApplication 46 // (https://docs.aws.amazon.com/kinesisanalytics/latest/dev/API_DescribeApplication.html) 47 // operation to get the current application version. If the version specified is 48 // not the current version, the ConcurrentModificationException is returned. 49 // 50 // This member is required. 51 CurrentApplicationVersionId *int64 52 53 // The ID of the configuration to delete. Each output configuration that is added 54 // to the application, either when the application is created or later using the 55 // AddApplicationOutput 56 // (https://docs.aws.amazon.com/kinesisanalytics/latest/dev/API_AddApplicationOutput.html) 57 // operation, has a unique ID. You need to provide the ID to uniquely identify the 58 // output configuration that you want to delete from the application configuration. 59 // You can use the DescribeApplication 60 // (https://docs.aws.amazon.com/kinesisanalytics/latest/dev/API_DescribeApplication.html) 61 // operation to get the specific OutputId. 62 // 63 // This member is required. 64 OutputId *string 65} 66 67// 68type DeleteApplicationOutputOutput struct { 69 // Metadata pertaining to the operation's result. 70 ResultMetadata middleware.Metadata 71} 72 73func addOperationDeleteApplicationOutputMiddlewares(stack *middleware.Stack, options Options) (err error) { 74 err = stack.Serialize.Add(&awsAwsjson11_serializeOpDeleteApplicationOutput{}, middleware.After) 75 if err != nil { 76 return err 77 } 78 err = stack.Deserialize.Add(&awsAwsjson11_deserializeOpDeleteApplicationOutput{}, middleware.After) 79 if err != nil { 80 return err 81 } 82 if err = addSetLoggerMiddleware(stack, options); err != nil { 83 return err 84 } 85 if err = awsmiddleware.AddClientRequestIDMiddleware(stack); err != nil { 86 return err 87 } 88 if err = smithyhttp.AddComputeContentLengthMiddleware(stack); err != nil { 89 return err 90 } 91 if err = addResolveEndpointMiddleware(stack, options); err != nil { 92 return err 93 } 94 if err = v4.AddComputePayloadSHA256Middleware(stack); err != nil { 95 return err 96 } 97 if err = addRetryMiddlewares(stack, options); err != nil { 98 return err 99 } 100 if err = addHTTPSignerV4Middleware(stack, options); err != nil { 101 return err 102 } 103 if err = awsmiddleware.AddRawResponseToMetadata(stack); err != nil { 104 return err 105 } 106 if err = awsmiddleware.AddRecordResponseTiming(stack); err != nil { 107 return err 108 } 109 if err = addClientUserAgent(stack); err != nil { 110 return err 111 } 112 if err = smithyhttp.AddErrorCloseResponseBodyMiddleware(stack); err != nil { 113 return err 114 } 115 if err = smithyhttp.AddCloseResponseBodyMiddleware(stack); err != nil { 116 return err 117 } 118 if err = addOpDeleteApplicationOutputValidationMiddleware(stack); err != nil { 119 return err 120 } 121 if err = stack.Initialize.Add(newServiceMetadataMiddleware_opDeleteApplicationOutput(options.Region), middleware.Before); err != nil { 122 return err 123 } 124 if err = addRequestIDRetrieverMiddleware(stack); err != nil { 125 return err 126 } 127 if err = addResponseErrorMiddleware(stack); err != nil { 128 return err 129 } 130 if err = addRequestResponseLogging(stack, options); err != nil { 131 return err 132 } 133 return nil 134} 135 136func newServiceMetadataMiddleware_opDeleteApplicationOutput(region string) *awsmiddleware.RegisterServiceMetadata { 137 return &awsmiddleware.RegisterServiceMetadata{ 138 Region: region, 139 ServiceID: ServiceID, 140 SigningName: "kinesisanalytics", 141 OperationName: "DeleteApplicationOutput", 142 } 143} 144