12937
Afi SV

@afi #12937

Cartegan Software | Get the Ultimate SaaS guide on the internet (link below) https://cartegan.com/a
648 Follower 1077 Following
workflow orchestration tools

Temporal
Cadence
Apache airflow
Camunda
Conductor
Luigi
Step funcitons (aws)
Subscribe to my YouTube channel. I make videos on React, Remix & Software Development https://www.youtube.com/@afiiiiiiiiiii/videos
Subscribe to my YouTube channel. I make videos on React, Remix & Software Development https://www.youtube.com/@afiiiiiiiiiii/videos
Subscribe to my YouTube channel. I make videos on React, Remix & Software Development https://www.youtube.com/@afiiiiiiiiiii/videos
HTTP vs Server-side Cache

Use server-side cache when the performance problem you want to solve is the database query, or API fetch taking a lot of time

User HTTP cache when you need to reduce the number of requests reaching your server or when your data is public

- sergiodxa
Subscribe to my YouTube channel. I make videos on React, Remix & Software Development https://www.youtube.com/@afiiiiiiiiiii/videos
Did you know in your GithubAction

You can use a container to run the steps in a job!

eg:

jobs:
jobName:
runs-on: ubuntu-latest
container: cypress // docker contianer
steps:
- name: Run Update
shell: bash
run: apt-get update // bash command
what gives you scale?

Queue does. Its asynchronous processing.

Offload heavy prorcess task from the main app flow.

checkout BullMQ
Weakness is your ally

to find it,

Load test your system before you put it into production.

checkout https://Artillery.io
Are you in the midst of vertical scaling?

Use caprover to horizontal scale via docker swarm

connect and deploy!
Did you know in docker 🚢

Multistage builds is the go to way to build your docker image

Image size is small thus security is vastly improved
And build performance is faster with layer caching
/dev
Did you know with Sentry's event fingerprinting you can group errors with greater granularity?

If your quering an API service the stack trace is generally the same even if the outgoing request is very different

Add it to your Sentry.init beforeSend function.
/dev
Did you know Nginx has a Lua module?

You can extend the functionality beyond what is available

Things like:
generate dynamic content on the fly
handle HTTP requests with custom logic
custom API gateways rate limiting, transofrm requests etc
custom error handling and logging
/dev
Your missing out on this

Your production code stack trace should be readable, and see exaclty what code caused the error.

Upload your sourcemaps to sentry right now!
/dev
This is how you stop worrying about scaling.

Vertical scale until you run out of resources
Horizontal scale until you reach 20 - 50 machines

Docker swarm until you think you cant handle manual auto scaling

Kubernetes when your product hits 100M in revenue
/dev
Here are 3 types of scan you didnt know about in postgres

Sequential Scan
Index Scan &
Bitmap Heap Scan

Use the EXPLAIN or EXPLAIN ANALYZE infront of your Query

Outputs the type of scan, the planning time and the execution time
Here is a lightning hack 🔥

Preload data before the user even clicks a link

Using prefetch="intent"

<Link to="/some/path" prefetch="intent" />

from React Router⚡
Do you wanna fake high web speed?

Use stale-while-revalidate cache directive. It serves stale content while fetching fresh content in the background

Users get instant responses while new data loads quietly! 🧙‍♂️

"Cache-Control": "public, max-age=60, stale-while-revalidate=300"
Subscribe to my YouTube channel. I make videos on DevOps, React and Software Development
https://www.youtube.com/@afiiiiiiiiiii/videos
You know about this recent headline right?
Google deletes $135B pension fund customer's cloud account

wal-g has a Failover archive storages
experimental tho

Dont forget!
backup db in all the places,
aws s3, digital ocean s3, black blaze s3 etc..

https://buff.ly/4cO5PtM
/dev
Also I missed out.

For point-in-time-recovery (PITR) you can use
pg_basebackup

You can take very fast consisten binary backups both for slaves/replicas
There are different types of dumps for postgres

pg_dump for a single database 1️⃣
pg_dumpall for entire clusters 🎇

And Point-in-time-recovery (PITR) as well

wal files for continuous archiving 🧱