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

Override `snapshotRequested` Attribute In Contract Tests Request

Open moataz-mhmd opened this issue 4 years ago • 0 comments

Hey, We are implementing RDS DBInstance resource. As per DBInstance docs, The default behavior on deletion is snapshot. We check this attribute in handler request here.

In contract test inputs, We can not override snapshotRequested attribute which means every time a contract test's delete handler request invoked will leave a DBInstance snapshot behind. RDS snapshots limited with quota. When snapshots quota is full, Contract tests will fail and block registration of DBInstance type to succeed.

Can you provide a way to override snapshotRequested to false in contract test request?

public class ResourceHandlerRequest<T> {
    private String clientRequestToken;
    private T desiredResourceState;
    private T previousResourceState;
    ...
    private String logicalResourceIdentifier;
    private String nextToken;
    private Boolean snapshotRequested;  <------ 
    private Boolean rollback;
    ...
}

moataz-mhmd avatar Jan 13 '22 13:01 moataz-mhmd