Send optional fields as nil instead of "" to ECS #938
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Previously when sending certain requests that contain optional fields to ECS through the Go AWS SDK, we always send empty strings instead of nil for those optional fields that are not set. The service treats such an action as an explicit intent and hence fails to plug in the default values from the service side.
This PR closes #927. Specifically, the repo 3.
Enter
[N/A]
in the box, if an item is not applicable to your change.Testing
I was able to run
ecs-cli compose service up
instead of getting thenamed volume [backup-laptop] is used but no declaration was found in the volumes section
error message described in the issue. Also verified the default, "local" driver, was correctly set on the service side in task def:Documentation
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.