Two less than stellar experiences #19374
Replies: 3 comments 2 replies
-
We also had the same problem with elasticbeanstalk and load balancer. We couldn't customize the load balancer to our liking so we opt to dockerize our application and use ECS. Project is still in progress. For lambda functions, we don't use CDK for that, as you mentioned, overly long. We use Serverless Framework for our projects and use CDK as to build our deployment pipeline. Our project does not use Step Functions though. |
Beta Was this translation helpful? Give feedback.
-
Hey Isch, could you share your step function example and/or any suggestions on how e can improve the experience? |
Beta Was this translation helpful? Give feedback.
-
first of all, apologies for the bad experience. We try to make sure CDK is delightful (or at least, as delightful as possible), so whenever that doesn't happen, we definitely want to hear that feedback. If you don't mind, can we dig a little deeper into what the problems were in each instance?
So seems like there were 2 problems here:
Is that a good summary? If so, can we dig into the details a little bit more (what were the exact problems with the load balancer L2? Why was it tough to use the Elastic BeanStalk L1s?).
So here, it seems like it's the StepFunctions Layer 2 library is the problem here? If so, can you expand on that - what was missing in the library to be able to write the definition using it? We in general had good feedback on that library, so I'm very curious what were the issues you ran into. Thanks a lot for the feedback! |
Beta Was this translation helpful? Give feedback.
-
I recently experienced two less than satisfying development projects using the CDK. I wanted to comment here and see if my conclusions are similar to more experienced users. These were two projects that went well beyond the toy model training exercises I completed in preparation.
The first project was a CDK solution for deploying a couple of websites hosted on elastic beanstalk, with a cloudfront distribution in front of them and an RDS Aurora database backend. The CDK solution really tanked when it came to customizing the load balancer and target groups, and many other issues arising from the fact that there are no L2 constructs for elastic beanstalk and the L1 construct basically spawns CF template completely divorced from my stacks and that provides no outputs at all to the parent stack. It was a really embarrassing example to use to try and show my management the merits of the CDK. We're deploying the solution using the EBCLI and some EB extensions in the website package, because it's clearly a better choice than the CDK.
The second real world solution I tried to build with the CDK is a serverless step function ETL, that scales up lambdas to do a basic map reduce pattern. The amount of CDK code necessary in order order to create 4 lambdas, the buckets, and the sns notification grew overly long. Almost none of the permissions were handled by the CDK, I had to write all inline policies. And creating the step function workflow nativelt would have been completely ridiculous, I ended up using an L1 construct and just importing the definition designed using the aws console. and this doesn't even account for the fact I still had to write all of the lambda logic. The creation and deployment of step functions seems much better handled by the SAM CLI; you do have to learn yet another domain specific language in order to write the SAM template, but at least it does everything you expect.
So these two projects really failed using the CDK, and no matter how much I want to like it, I doubt I'm gonna be able to convince anybody in my management that it's a good fit for our org. I guess maybe it's just bad luck that the problems I tried to solve with it were so ill suited for the current state of the CDK. My work is sending me to one of these serverless immersion things next week, so I'm gonna see if I can get some answers as to why these two types of solutions are so painful in the CDK.
Best,
Isch
Beta Was this translation helpful? Give feedback.
All reactions