Thank you to Josh for asking this question on the AppSync Masterclass forum. His original question goes like this:

Let’s say I want to add a one-to-many relationship from Profile to a new property called “Tag” (a complex object with “name” and “color” properties) so a user can define their own Tags.

I would also like a Tweet to reference one or more of the user’s own Tags. The Tag(name, color) object can change over time (the “name” can be renamed for example) so I don’t think I want to copy it into a Tweet.

Do you have an example…

One of the most common questions I get is “How do I build a multi-tenant application with AppSync and Cognito?”.

If you google this topic on the internet you will no doubt come across many different opinions. It’s a topic that we’ll soon explore in the AppSync Masterclass but I want to take this opportunity to explain my thoughts on it.

You see, a common requirement in these multi-tenant applications is to support roles within each tenant. These are usually well-defined roles in your application and a user would fall into one of these roles within his/her tenant.

So you…

In light of recent news of Okta’s pending acquisition of Auth0 there’s been renewed discussion about where Amazon Cognito fits into the picture. It’s a question my clients often ask me, so here are my two cents.

The case for Cognito

Integration with other AWS services

Cognito’s tight integration with other AWS services such as API Gateway, AppSync and ALB is by far its greatest strength.

It removes a whole layer of custom code you’d have to write otherwise.

For example, if you decide to use Auth0 and skip Cognito altogether (I will talk about SAML federation in a minute) then you will need to write a Lambda authorizer…

When you start a new Vue.js project that needs to interface with APIs running in AWS, there’s a good chance you will have these lines of code:

import Amplify from 'aws-amplify'Amplify.configure({
Auth: {
region: 'us-east-1',
userPoolId: 'xxx',
userPoolWebClientId: 'xxx',
mandatorySignIn: true

These few lines of code let you use the aws-amplify library to authenticate the user against a Cognito User Pool and support common flows such as sign-up, sign-in, sign-out, forgotten passwords and change passwords.

But, as you provide your Vue.js …

All the sessions during week 1 are available to watch on-demand now. You can access them via the official reinvent portal here.

Here are my top picks for sessions to watch, in no particular order.

“Building technology standards at Amazon scale” by Marc Brooker
You can watch the session here, and here‘s my notes for the session.

“Monitoring production services at Amazon” by David Yanacek
You can watch the session here, and here‘s my notes for the session.

“Automating continuous delivery pipelines at Amazon” by Clare Liguori
You can watch the session here, and here‘s my notes for the session.

I’ve gotten a few questions about Aurora Serverless v2 preview, so here is what you need to know about Aurora Serverless v2 during preview.

Q: Does it replace the existing Aurora Serverless offering?

A: No, it lives side-by-side with the existing Aurora Serverless, which will still be available to you as “v1”.

Q: Aurora Serverless v1 takes a few seconds to scale up, that’s too much for our use case where we get a lot of spikes. Is that the same with v2?

A: No, v2 scales up in milliseconds, during preview the max ACU is only 32 though.


During this re:Invent, I’m sharing with you the biggest serverless-related announcements and what they mean for you in a series of hot-takes.

Starting with, the biggest announcements from today’s keynote, plus a bunch of other important announcements just before r:Invent.

1. Lambda changes billing to per ms

Lambda now bills you by the ms as opposed to 100 ms. So if your function runs for 42ms you will be billed for 42ms, not 100ms.

This instantly makes everyone’s lambda bills cheaper without anyone having to lift a finger. It’s the best kind of optimization!

However, this might not mean much in practice for a lot of you…

Today, AWS announced another major feature to the Lambda platform: the option to package your code and dependencies as container images. The advantage of this capability is that it makes it easier for enterprise users to use a consistent set of tools for security scanning, code signing, and more. It also raises the maximum code package size for a function to a whopping 10GB.

As an official launch partner, we are proud to add support for container images in the Lumigo platform so you can quickly identify functions that are deployed as a container image.

I have been involved with a client project to help the client launch a new social network for university students to engage with each other to do sports.

Amongst other things, users can:

  • Arrange activities and ask to join others’ activities (like a basketball match or to run in the park).
  • There’s private messaging.
  • Users can book sports classes organized by their university’s sports centre.

And so on.

The client is a bootstrapped startup and we had to launch the app before the semester restarted in September 2020. …

A common complaint I have heard about serverless applications is that they tend to look really complicated on architecture diagrams, with many moving parts. But does it mean serverless applications are more complex compared to their serverful counterparts?

Before I get to that, let’s do a simple exercise.

Serverful architectures

Which of these two serverful applications are more complex?

Pretty hard to tell, right? Since the architecture diagram alone doesn’t tell the full story. And those EC2 icons are really great at hiding all the complexities that are buried in your code.

What if we have a more honest representation of what…

Yan Cui

AWS Serverless Hero. Independent Consultant Author of Speaker. Trainer. Blogger.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store