feat: add PostgreSQL schema isolation for playground environment
- Create schema.rs utility module with table_name() function - Add schema prefix to all SQL queries in postgres_db.rs - Support dev schema for playground, public for production - Add DATABASE_SCHEMA, MONGODB_DATABASE, QDRANT_COLLECTION config - Fix 40+ functions including videos, chunks, frames, vectors, etc. - Update Cargo dependencies
This commit is contained in:
@@ -78,6 +78,15 @@ pub static SERVER_PORT: Lazy<u16> = Lazy::new(|| {
|
||||
pub static REDIS_KEY_PREFIX: Lazy<String> =
|
||||
Lazy::new(|| env::var("MOMENTRY_REDIS_PREFIX").unwrap_or_else(|_| "momentry:".to_string()));
|
||||
|
||||
pub static DATABASE_SCHEMA: Lazy<String> =
|
||||
Lazy::new(|| env::var("DATABASE_SCHEMA").unwrap_or_else(|_| "public".to_string()));
|
||||
|
||||
pub static MONGODB_DATABASE: Lazy<String> =
|
||||
Lazy::new(|| env::var("MONGODB_DATABASE").unwrap_or_else(|_| "momentry".to_string()));
|
||||
|
||||
pub static QDRANT_COLLECTION: Lazy<String> =
|
||||
Lazy::new(|| env::var("QDRANT_COLLECTION").unwrap_or_else(|_| "momentry_rule1".to_string()));
|
||||
|
||||
pub mod processor {
|
||||
use super::*;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user