3 simple tips for successful serverless apps.
Serverless is a very hot topic today. Here are some tips when building serverless applications.

🤲 Divide and conquer
Make sure your functions are small.
Yes, S M AL L.
Your serverless functions should only do one small thing and fast.
Dependencies? Forget about them, keep your code as lean as possible.
Why? The heavier your function (more dependencies), the longer the latency will be when warming up your function after invocation from a cold start.
Why a cold starts? (Well…The running environment that runs your function oftentimes goes to bed until your beautiful function is invoked again. This saves money to the Serverless provider. Don’t tell anybody).
📞 Calling other functions
Please, don’t!
Don’t chain function calls. {{{DO NOT}}}
Instead, use well-known patterns for distributed systems.
Propagate messages to other functions.
Use queue systems or simple notification services.
Detach your tasks from the main thread (your function).
🏃Long-running processes
I hope you don’t do this either 🤦
Serverless functions are meant for executing fast and non-blocking operations. Yes, <<<NON | BLOCKING>>>.
Forget about establishing long-running connections (Yeah, no RDBMS connections) or having long-running processes.
Your functions should delegate long-running processes to workers ready to receive and compute anything really heavy.
A queue system and workers system together can help you with keeping your Serverless functions ready to accept incoming connections and save you resources.
👨💻Takeaway
It’s clear that the future is less code and more code sharing and features. However, while we get there, it’s important to understand the gist of new emerging technologies like the Serverless architecture.
I hope You have enjoyed this post!
Help me get to others by CLAPPING! 👏
👉 Follow me on Twitter: https://twitter.com/anthonyrod4

😊 You might also like:
If you want to discuss more on this topic, make a correction or just say “hi 🙌”, just leave us a comment, please.
