Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resource updates & required, write-only properties #190

Open
ewbankkit opened this issue Sep 28, 2021 · 3 comments
Open

Resource updates & required, write-only properties #190

ewbankkit opened this issue Sep 28, 2021 · 3 comments
Labels
runtime-handling Relates to runtime handling and conversion of Terraform configuration to CloudFormation. upstream-aws Unable to proceed due to missing or broken functionality from an AWS dependency.

Comments

@ewbankkit
Copy link
Contributor

ewbankkit commented Sep 28, 2021

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment
  • The resources and data sources in this provider are generated from the CloudFormation schema, so they can only support the actions that the underlying schema supports. For this reason submitted bugs should be limited to defects in the generation and runtime code of the provider. Customizing behavior of the resource, or noting a gap in behavior are not valid bugs and should be submitted as enhancements to AWS via the Cloudformation Open Coverage Roadmap.

Relates: #185.

Response from AWS on resource updates and including required, write-only properties (e.g. the Code property of AWS::Lambda::Function):

It's currently required to include any property that is write-only and required. We'll evaluate whether we can safely relax that restriction in a future release.

@ewbankkit ewbankkit added the runtime-handling Relates to runtime handling and conversion of Terraform configuration to CloudFormation. label Sep 28, 2021
@ewbankkit ewbankkit added this to the v0.1.0 milestone Sep 28, 2021
@ewbankkit
Copy link
Contributor Author

generating Terraform resource code for "awscc_acmpca_certificate_authority_activation" from "../service/cloudformation/schemas/AWS_ACMPCA_CertificateAuthorityActivation.json" into "../aws/acmpca/certificate_authority_activation_resource_gen.go" and "../aws/acmpca/certificate_authority_activation_resource_gen_test.go"
Certificate is write-only, required and not force-new
generating Terraform resource code for "awscc_datasync_location_nfs" from "../service/cloudformation/schemas/AWS_DataSync_LocationNFS.json" into "../aws/datasync/location_nfs_resource_gen.go" and "../aws/datasync/location_nfs_resource_gen_test.go"
Subdirectory is write-only, required and not force-new
generating Terraform resource code for "awscc_datasync_location_smb" from "../service/cloudformation/schemas/AWS_DataSync_LocationSMB.json" into "../aws/datasync/location_smb_resource_gen.go" and "../aws/datasync/location_smb_resource_gen_test.go"
Password is write-only, required and not force-new
Subdirectory is write-only, required and not force-new
generating Terraform resource code for "awscc_lambda_function" from "../service/cloudformation/schemas/AWS_Lambda_Function.json" into "../aws/lambda/function_resource_gen.go" and "../aws/lambda/function_resource_gen_test.go"
Code is write-only, required and not force-new
generating Terraform resource code for "awscc_ssmcontacts_contact" from "../service/cloudformation/schemas/AWS_SSMContacts_Contact.json" into "../aws/ssmcontacts/contact_resource_gen.go" and "../aws/ssmcontacts/contact_resource_gen_test.go"
Plan is write-only, required and not force-new

@ewbankkit
Copy link
Contributor Author

It isn't obvious what should be happening here.

I get errors like

╷
│ Error: AWS SDK Go Service Operation Unsuccessful
│ 
│   with awscc_lambda_function.test,
│   on main.tf line 204, in resource "awscc_lambda_function" "test":
│  204: resource "awscc_lambda_function" "test" {
│ 
│ Calling Cloud Control API service UpdateResource operation returned: operation error CloudControl: UpdateResource, https response error StatusCode: 400, RequestID:
│ ce44f8f4-e5d4-476c-8eb4-66463546eb9f, api error ValidationException: [REPLACE Operation] noSuchPath in source, path provided : //Code
╵

which are very similar to error I get when updating the code otherwise:

╷
│ Error: AWS SDK Go Service Operation Unsuccessful
│ 
│   with awscc_lambda_function.test,
│   on main.tf line 204, in resource "awscc_lambda_function" "test":
│  204: resource "awscc_lambda_function" "test" {
│ 
│ Calling Cloud Control API service UpdateResource operation returned: operation error CloudControl: UpdateResource, https response error StatusCode: 400, RequestID:
│ 0e81e0e6-f747-4e5c-81c0-583c60a6e3a0, api error ValidationException: [REPLACE Operation] noSuchPath in source, path provided: //Code/ZipFile
╵

@ewbankkit
Copy link
Contributor Author

I'm going to move this to a post-9/30 task.

@breathingdust breathingdust added the upstream-aws Unable to proceed due to missing or broken functionality from an AWS dependency. label Nov 17, 2021
@breathingdust breathingdust removed this from the v0.2.0 milestone Nov 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
runtime-handling Relates to runtime handling and conversion of Terraform configuration to CloudFormation. upstream-aws Unable to proceed due to missing or broken functionality from an AWS dependency.
Projects
None yet
2 participants