Chat SDK Adds PostgreSQL State Adapter
Key point
Chat SDK has added a PostgreSQL state adapter, enabling data persistence without Redis.
Details
Following Redis and ioredis, Chat SDK now supports PostgreSQL as a new production state backend. This allows teams already running PostgreSQL to manage subscription information, distributed locks, and key-value cache state without adding separate Redis infrastructure.
The new adapter uses the pg (node-postgres) library and operates via raw SQL queries. It provides functionality to automatically create the necessary tables upon first connection.
Key features include:
- Support for TTL-based caching
- Distributed locks across multiple instances
- Namespaced state management via configurable key prefixes
This summary was generated automatically by AI. Check the original for the author's claims and context. Copyright belongs to the original author.
Our guide explains how the AI works. Report summary errors, attribution issues, or removal requests via Contact.