siilisolutions / hedge

a serverless solution for clojure
Eclipse Public License 1.0
39 stars 6 forks source link

AWS deploy bugs #73

Open jikuja opened 6 years ago

jikuja commented 6 years ago

Re-deploy crashed with (probably changeset without any changes)

Use case: deploy artifacts accidentally twice

Ensuring bucket hedge-testing-01-deploy exists Uploading functions-1517393987.zip into bucket hedge-testing-01-deploy Deploying to AWS java.lang.Thread.run Thread.java: 748 java.util.concurrent.ThreadPoolExecutor$Worker.run ThreadPoolExecutor.java: 624 java.util.concurrent.ThreadPoolExecutor.runWorker ThreadPoolExecutor.java: 1149 java.util.concurrent.FutureTask.run FutureTask.java: 266 clojure.lang.AFn.call AFn.java: 18 clojure.core/binding-conveyor-fn/fn core.clj: 1938 boot.core/boot/fn core.clj: 1031 boot.core/run-tasks core.clj: 1021 boot-hedge.aws.core/eval1617/fn/fn/fn core.clj: 17 adzerk.boot-cljs/eval302/fn/fn/fn boot_cljs.clj: 135 adzerk.boot-cljs/eval354/fn/fn/fn boot_cljs.clj: 208 boot-hedge.aws.core/eval1804/fn/fn/fn core.clj: 79 boot.task.built-in/fn/fn/fn/fn built_in.clj: 627 boot.task.built-in/fn/fn/fn/fn built_in.clj: 918 boot-hedge.aws.core/eval1652/fn/fn/fn core.clj: 26 boot-hedge.aws.core/eval1690/fn/fn/fn core.clj: 58 boot-hedge.aws.cloudformation-api/deploy-stack cloudformation_api.clj: 157 boot-hedge.aws.cloudformation-api/update-stack cloudformation_api.clj: 138 boot-hedge.aws.cloudformation-api/create-or-update-stack cloudformation_api.clj: 128 boot-hedge.aws.cloudformation-api/create-changeset cloudformation_api.clj: 46 clojure.lang.Reflector.invokeInstanceMethod Reflector.java: 28 clojure.lang.Reflector.invokeMatchingMethod Reflector.java: 93 java.lang.reflect.Method.invoke Method.java: 498 sun.reflect.DelegatingMethodAccessorImpl.invoke DelegatingMethodAccessorImpl.java: 43 sun.reflect.NativeMethodAccessorImpl.invoke NativeMethodAccessorImpl.java: 62 sun.reflect.NativeMethodAccessorImpl.invoke0 NativeMethodAccessorImpl.java com.amazonaws.services.cloudformation.AmazonCloudFormationClient.createChangeSet AmazonCloudFormationClient.java: 457 com.amazonaws.services.cloudformation.AmazonCloudFormationClient.executeCreateChangeSet AmazonCloudFormationClient.java: 481 com.amazonaws.services.cloudformation.AmazonCloudFormationClient.invoke AmazonCloudFormationClient.java: 2666 com.amazonaws.services.cloudformation.AmazonCloudFormationClient.doInvoke AmazonCloudFormationClient.java: 2690 com.amazonaws.http.AmazonHttpClient.execute AmazonHttpClient.java: 513 com.amazonaws.http.AmazonHttpClient$RequestExecutionBuilderImpl.execute AmazonHttpClient.java: 649 com.amazonaws.http.AmazonHttpClient$RequestExecutor.access$500 AmazonHttpClient.java: 667 com.amazonaws.http.AmazonHttpClient$RequestExecutor.execute AmazonHttpClient.java: 699 com.amazonaws.http.AmazonHttpClient$RequestExecutor.executeWithTimer AmazonHttpClient.java: 717 com.amazonaws.http.AmazonHttpClient$RequestExecutor.doExecute AmazonHttpClient.java: 743 com.amazonaws.http.AmazonHttpClient$RequestExecutor.executeHelper AmazonHttpClient.java: 1056 com.amazonaws.http.AmazonHttpClient$RequestExecutor.executeOneRequest AmazonHttpClient.java: 1304 com.amazonaws.http.AmazonHttpClient$RequestExecutor.handleErrorResponse AmazonHttpClient.java: 1639 com.amazonaws.services.cloudformation.model.AlreadyExistsException: ChangeSet TODO-change-this-asap cannot be created due to a mismatch with existing attribute Description (Service: AmazonCloudFormation; Status Code: 400; Error Code: AlreadyExistsException; Request ID: 7792e6ff-0670-11e8-bdcb-c55f27438670) errorCode: "AlreadyExistsException" errorMessage: "ChangeSet TODO-change-this-asap cannot be created due to a mismatch with existing attribute Description" errorType: #object[com.amazonaws.AmazonServiceException$ErrorType 0x1e1237ab "Client"] httpHeaders: {"Connection" "close", "Content-Length" "367", "Content-Type" "text/xml", "Date" "Wed, 31 Jan 2018 10:21:14 GMT", "x-amzn-RequestId" "7792e6ff-0670-11e8-bdcb-c55f27438670"} requestId: "7792e6ff-0670-11e8-bdcb-c55f27438670" retryable: true serviceName: "AmazonCloudFormation" statusCode: 400 clojure.lang.ExceptionInfo: ChangeSet TODO-change-this-asap cannot be created due to a mismatch with existing attribute Description (Service: AmazonCloudFormation; Status Code: 400; Error Code: AlreadyExistsException; Request ID: 7792e6ff-0670-11e8-bdcb-c55f27438670) line: 26

jikuja commented 6 years ago

Use case: change set failed, stack is in REVIEW_IM_PROGRESS stack:

Fix?: 1) remove changeset 2) restore state of stack

Deploying to AWS java.lang.Thread.run Thread.java: 748 java.util.concurrent.ThreadPoolExecutor$Worker.run ThreadPoolExecutor.java: 624 java.util.concurrent.ThreadPoolExecutor.runWorker ThreadPoolExecutor.java: 1149 java.util.concurrent.FutureTask.run FutureTask.java: 266 ... clojure.core/binding-conveyor-fn/fn core.clj: 2022 boot.core/boot/fn core.clj: 1031 boot.core/run-tasks core.clj: 1021 boot-hedge.aws.core/eval1873/fn/fn/fn core.clj: 18 adzerk.boot-cljs/eval456/fn/fn/fn boot_cljs.clj: 135 adzerk.boot-cljs/eval510/fn/fn/fn boot_cljs.clj: 208 boot-hedge.aws.core/eval2084/fn/fn/fn core.clj: 83 boot.task.built-in/fn/fn/fn/fn built_in.clj: 627 boot.task.built-in/fn/fn/fn/fn built_in.clj: 918 boot-hedge.aws.core/eval1910/fn/fn/fn core.clj: 28 boot-hedge.aws.core/eval1950/fn/fn/fn core.clj: 60 boot-hedge.aws.cloudformation-api/deploy-stack cloudformation_api.clj: 160 boot-hedge.aws.cloudformation-api/update-stack cloudformation_api.clj: 139 boot-hedge.aws.cloudformation-api/create-or-update-stack cloudformation_api.clj: 129 boot-hedge.aws.cloudformation-api/create-changeset cloudformation_api.clj: 47 ... com.amazonaws.services.cloudformation.AmazonCloudFormationClient.createChangeSet AmazonCloudFormationClient.java: 457 com.amazonaws.services.cloudformation.AmazonCloudFormationClient.executeCreateChangeSet AmazonCloudFormationClient.java: 481 com.amazonaws.services.cloudformation.AmazonCloudFormationClient.invoke AmazonCloudFormationClient.java: 2666 com.amazonaws.services.cloudformation.AmazonCloudFormationClient.doInvoke AmazonCloudFormationClient.java: 2690 com.amazonaws.http.AmazonHttpClient.execute AmazonHttpClient.java: 513 com.amazonaws.http.AmazonHttpClient$RequestExecutionBuilderImpl.execute AmazonHttpClient.java: 649 com.amazonaws.http.AmazonHttpClient$RequestExecutor.access$500 AmazonHttpClient.java: 667 com.amazonaws.http.AmazonHttpClient$RequestExecutor.execute AmazonHttpClient.java: 699 com.amazonaws.http.AmazonHttpClient$RequestExecutor.executeWithTimer AmazonHttpClient.java: 717 com.amazonaws.http.AmazonHttpClient$RequestExecutor.doExecute AmazonHttpClient.java: 743 com.amazonaws.http.AmazonHttpClient$RequestExecutor.executeHelper AmazonHttpClient.java: 1056 com.amazonaws.http.AmazonHttpClient$RequestExecutor.executeOneRequest AmazonHttpClient.java: 1304 com.amazonaws.http.AmazonHttpClient$RequestExecutor.handleErrorResponse AmazonHttpClient.java: 1639 com.amazonaws.services.cloudformation.model.AmazonCloudFormationException: Stack [queue-message-pick-02] does not exist (Service: AmazonCloudFormation; Status Code: 400; Error Code: ValidationError; Request ID: 500a7b85-0da1-11e8-93b6-c5cf5b9938d9) errorCode: "ValidationError" errorMessage: "Stack [queue-message-pick-02] does not exist" errorType: #object[com.amazonaws.AmazonServiceException$ErrorType 0x6723cce7 "Client"] httpHeaders: {"Connection" "close", "Content-Length" "301", "Content-Type" "text/xml", "Date" "Fri, 09 Feb 2018 13:58:31 GMT", "x-amzn-RequestId" "500a7b85-0da1-11e8-93b6-c5cf5b9938d9"} requestId: "500a7b85-0da1-11e8-93b6-c5cf5b9938d9" retryable: true serviceName: "AmazonCloudFormation" statusCode: 400 clojure.lang.ExceptionInfo: Stack [queue-message-pick-02] does not exist (Service: AmazonCloudFormation; Status Code: 400; Error Code: ValidationError; Request ID: 500a7b85-0da1-11e8-93b6-c5cf5b9938d9) line: 26