-
Notifications
You must be signed in to change notification settings - Fork 202
Closed
Description
When I send a message to sqs with empty value, sqs returns error (InvalidParameterValue).
cat attributes.json
{
"piyo": {
"DataType": "String",
"StringValue": ""
}
}
aws sqs send-message \
--queue-url https://sqs.ap-northeast-1.amazonaws.com/XXXXXXXXXX/elastic-mq-debug \
--message-body bar \
--message-attributes file://attributes.json
An error occurred (InvalidParameterValue) when calling the SendMessage operation: Message (user) attribute 'piyo' must contain a non-empty value of type 'String'.
But elastmq does not return error.
java -jar elasticmq-server-0.15.7.jar
...
aws --endpoint-url http://localhost:9324 sqs create-queue --queue-name foo
{
"QueueUrl": "http://localhost:9324/queue/foo"
}
cat attributes.json
{
"piyo": {
"DataType": "String",
"StringValue": ""
}
}
aws --endpoint-url http://localhost:9324 \
sqs send-message \
--queue-url http://localhost:9324/queue/foo \
--message-body bar \
--message-attributes file://attributes.json
{
"MD5OfMessageBody": "37b51d194a7513e45b56f6524f2d51f2",
"MD5OfMessageAttributes": "4166cc16b73099be3abe8e2b0f544c99",
"MessageId": "62aa4db3-9666-4421-a1d8-b988f76b7ae1"
}
echo $?
0
Metadata
Metadata
Assignees
Labels
No labels