top of page

Breaking beliefs with AWS Amplify

Fondness is a bit of a loaded word in this subtitle. I was, am, and will always be fond of tech - especially the development and architecture aspect of it. However, although frontend technologies have made me curious to explore them, I have always stayed careful of not falling into that rabbit hole as the backend wonders took over.

Thanks for reading Let's Do Tech! Subscribe for free to receive new posts ad support my work.

Apart from a short stint with AngularJS back in 2015, I have no experience in fronted dev till date.

What is frontend anyway?

As opposed to the last week’s update - where I worked on setting up the backend infrastructure DevOps pipeline - this week I deterministically spent time in finding a similar solution for the frontend. To me it is like designing a spacecraft to safely land on the surface of Mars, as I am not familiar with frontend dev stack and best practices, let alone the pipelines.

But the push was real this time, and I am glad to have spent this week familiarising myself with AWS Amplify. It has been able to answer ‘most’ of my naive questions about approach towards building frontend and integrating the same with backend.

Some of my questions were:

  1. Where to begin?

  2. How to adopt modular development for reusability?

  3. How to enable fellow developers for parallel development?

  4. How to review and promote changes to higher environments?

  5. How to integrate frontend with backend securely?

  6. How to implement authentication and authorization?

  7. What are the best practices in hosting the frontend?

  8. How to scale?

  9. How to implement GraphQL for efficient API calls?

I am yet to ask and answer deeper questions like styling and theming, custom frontend components and behaviours, etc.

At first, AWS Amplify seemed too complex a service to implement. But then it wasn’t a result of thorough consideration of above questions. After taking a stock of all the things required for a frontend MVP, Amplify made sense. In short, it had answers to all the questions listed above.

Broken beliefs

The reason my beliefs were broken was because of the way Amplify created all the resources. On one side, it was convenient to build “working” frontend components in the fastest way possible, on the other side, I had to part ways with my favourite tech stack.

  1. NodeJS over Golang - Since the start of my serverless journey, I made it a point to do all the backend development using Golang as it was more performant than NodeJS, thus reaping benefits in cloud costs. However, to get going with the project and product, Amplify made it really easy to let the Lambda functions and GraphQL queries to be generated in Javascript/Typescript. Good part is - I do have some experience with NodeJS as well.

  2. CloudFormation over Terraform - Since the last few years, I have used Terraform at length. It would not be incorrect to say that all my projects in this time span were basically a huge “Terraform repository”. Amplify manages all the backend components required to support the fronted - like DynamoDB for persistence, Lambda function for auth and query logic, etc. - using CloudFormation under the hood. The good part is “under the hood”. We don’t really have to know CF. At this moment, I am aware of the fact that knowing CF will enable greater flexibility and better customisation opportunities.

  3. Auto generated names over custom naming convention - Using AWS Amplify to manage all the AWS resources also mean that the naming convention is decided by Amplify as well. As someone who numbers their folder structure on their laptop - this is of huge inconvenience. This is again something that I had to make peace with this week, given the speed offered.

  4. Keys over Roles - This limitation greatly impacted critical access related DevOps decisions. Unlike the backend and infrastructure development, complete DevOps pipelines were managed using Role ARN and AssumeRole function. I am not sure if this limitation with Amplify will be addressed in the future or not, but for now, I had to stick with independent access and secret keys for multi-account AWS deployments.

To be fair, along with the other advantages, Amplify did enable me to use latest frontend frameworks like React and React Native. Additionally, custom component development is accelerated with it’s integration with Figma - this is something I will be exploring in more details in the upcoming weeks.

At this point, I feel confident on my frontend progress made with AWS amplify, although I do not call myself an expert in the same. I am intending to divide my work packages / AWS resources in 3 categories as below.

  1. Frontend components

  2. Backend components which support frontend

  3. Backend components which enable business logic

But more on this later!

Sumeet N.

0 views0 comments
bottom of page