Adding Durable Execution to Flask Applications with Restate

The Challenge of Reliable Background Operations Building web applications with Flask is straightforward until you need to handle operations that can fail. Database operations timeout, external APIs become unavailable, and network connections drop. These failures are inevitable in production systems, yet handling them gracefully often requires significant engineering effort. Recently, I was trying to build a Todo application where users could create, update, and delete tasks. On the surface, this seems simple. But when you start thinking about production scenarios, questions emerge. What happens if the database connection fails mid-operation? How do you handle retries without duplicating operations? What if the server crashes while processing a delete request? ...

November 16, 2025 · 7 min · 1385 words · Joel Hanson

Supercharging Your AI: Setting Up RAG with PostgreSQL and pgvector

Learn how to implement a powerful Retrieval-Augmented Generation (RAG) system using PostgreSQL and pgvector. This comprehensive guide covers everything from setting up a custom PostgreSQL Docker image to creating a fully functional RAG query system with vector embeddings and language model inference.

September 30, 2024 · 4 min · 773 words · Joel Hanson