Workshop 8 - Building Complex Backends

Explore the design and implementation of advanced backend systems, including multi-table databases, microservices, and authentication techniques.

Workshop Topics

  • Setup
    Before starting, ensure your environment is ready for the workshop:

    • Charge your laptop and ensure all necessary software is installed:
      • Node.js
      • Git
      • VSCode
    • Start Zoom with the camera off, unmute yourself, and share your screen. Test audio to ensure it plays through your speakers and confirm attendees can hear you.
    • Share the Zoom link, slides, and attendance link via Discord and Zoom chat. Write the attendance link on the chalkboard.
    • Open slides, test microphones, and confirm any website updates are deployed.
  • Building Complex Backends
    This workshop introduces the principles of building robust, scalable backends used in industry. We’ll discuss architectural patterns, database management, and authentication.

    • Industry-Grade Backends:

      • Overview of complex backend systems using a simple architectural diagram.
      • Key components of industry-standard backend designs:
        • APIs: Load balancing, rate limiting, and gateways.
        • Data storage strategies: Caching with Redis, BLOB storage, and replication with multiple databases.
        • Microservices: The importance of separating concerns for scalability.
        • CDNs: Mentioned briefly for context (but not covered in detail).
    • Complex Databases:

      • Working with multiple tables, SQL joins, and grouping.
      • The importance of indexing for performance optimization.
      • ORMs (Object-Relational Mappers):
        • What they are and why they are useful.
        • Overview of common ORMs, with a focus on Supabase.
        • Demo: Using Supabase ORM to perform a SQL join.
    • Authentication:

      • Differentiating between authentication (verifying identity) and authorization (verifying permissions).
      • API gateways and their role in secure authentication.
      • Techniques for securing user data:
        • Encryption, decryption, hashing, and salting.
        • Sessions and JWT tokens (including refresh tokens).
        • Role-based authentication.
        • OAuth for third-party authentication.
      • Why using existing authentication services simplifies implementation:
        • Services like AWS Cognito, Firebase Auth, Supabase Auth, AuthJS, and Lucia Auth.
        • Demo: Implementing Supabase Auth for authentication.

Materials

Workshop recordingSlidesHomework
LinkLinkAssignment 7