aws-cli icon indicating copy to clipboard operation
aws-cli copied to clipboard

aws firehose create-delivery-stream fails due to `TypeName`

Open MMChrisHinshaw opened this issue 7 years ago • 6 comments

Here is the error I get when TypeName has a value: [chinshaw@build4 aws]$ grep TypeName p00000012.json "TypeName": "document", [chinshaw@build4 aws]$ aws firehose create-delivery-stream --delivery-stream-name p00000012 --delivery-stream-type DirectPut --cli-input-json file://$PWD/p00000012.json --profile psledeng An error occurred (InvalidArgumentException) when calling the CreateDeliveryStream operation: Types are deprecated in Elasticsearch version 7.1. TypeName must be empty. Next is when TypeName is "": [chinshaw@build4 aws]$ grep TypeName p00000012.json "TypeName": "", [chinshaw@build4 aws]$ aws firehose create-delivery-stream --delivery-stream-name p00000012 --delivery-stream-type DirectPut --cli-input-json file://$PWD/p00000012.json --profile psledeng Parameter validation failed: Invalid length for parameter ElasticsearchDestinationConfiguration.TypeName, value: 0, valid range: 1-inf Here is when TypeName is removed: [chinshaw@build4 aws]$ grep TypeName p00000012.json [chinshaw@build4 aws]$ aws firehose create-delivery-stream --delivery-stream-name p00000012 --delivery-stream-type DirectPut --cli-input-json file://$PWD/p00000012.json --profile psledeng Parameter validation failed: Missing required parameter in ElasticsearchDestinationConfiguration: "TypeName"

The beginning of the file in question.... { "ElasticsearchDestinationConfiguration": { "RoleARN": "<redacted>", "DomainARN": "<redacted>", "IndexName": "p00000012-sensors", "TypeName": "document", "IndexRotationPeriod": "OneDay", ... } aws --version aws-cli/1.11.133 Python/2.7.5 Linux/4.10.10-1.el7.elrepo.x86_64 botocore/1.9.2

Also confirmed failure occurs with: aws-cli/1.16.250 Python/3.7.4 Darwin/19.0.0 botocore/1.12.240

Please let me know what text is required to create a firehose delivery stream using the CLI as this is impacting our customer deployment system.

MMChrisHinshaw avatar Nov 21 '19 20:11 MMChrisHinshaw

Also facing this issue when deploying through a CloudFormation stack - please advise.

troydieter avatar Dec 30 '19 18:12 troydieter

Try updating to the latest version of aws-cli. I believe that fixed the problem I was running into.

MMChrisHinshaw avatar Jan 05 '20 00:01 MMChrisHinshaw

Hi,

We are deploying this through a serverless stack, in this case being a cloudformation resource.

We opened a support case with AWS who recommended we downgrade to ES 6.8.

In my opinion, a cop-out for not supporting a handler for type not being supported in 7.1.

On Sat, Jan 4, 2020, 7:48 PM Chris Hinshaw [email protected] wrote:

Try updating to the latest version of aws-cli. I believe that fixed the problem I was running into.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/aws/aws-cli/issues/4697?email_source=notifications&email_token=AA4E3KB32JP2EEFGH75NP33Q4EU7DA5CNFSM4JQHSAK2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEIDDUNY#issuecomment-570833463, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA4E3KDEJXKT5EQ372Z7SNLQ4EU7DANCNFSM4JQHSAKQ .

troydieter avatar Jan 05 '20 06:01 troydieter

Copy/paste from our AWS support ticket: Turns out the version of the aws cli tool was older. Upgraded to the latest (1.16.304), and the error no longer occurs in our process

MMChrisHinshaw avatar Jan 05 '20 21:01 MMChrisHinshaw

@troydieter you can use CF for ES 7.1, on your Firehose delivery stream do not remove the TypeName field, CF will fail if it's missing, but set it to an empty string (TypeName: '').

jsontm avatar Jan 29 '20 21:01 jsontm

Looks like this is resolved with a newer version of the AWS CLI. @PSChrisHinshaw please reopen if it reoccurs!

kdaily avatar Sep 21 '20 22:09 kdaily