collab: Setup database for LLM service (#15882)
This PR puts the initial infrastructure for the LLM service's database in place. The LLM service will be using a separate Postgres database, with its own set of migrations. Currently we only connect to the database in development, as we don't yet have the database setup for the staging/production environments. Release Notes: - N/A
This commit is contained in:
parent
a64906779b
commit
7f6d0919c9
25 changed files with 627 additions and 74 deletions
|
@ -11,6 +11,8 @@ mod feature_flag_tests;
|
|||
mod message_tests;
|
||||
mod processed_stripe_event_tests;
|
||||
|
||||
use crate::migrations::run_database_migrations;
|
||||
|
||||
use super::*;
|
||||
use gpui::BackgroundExecutor;
|
||||
use parking_lot::Mutex;
|
||||
|
@ -91,7 +93,9 @@ impl TestDb {
|
|||
.await
|
||||
.unwrap();
|
||||
let migrations_path = concat!(env!("CARGO_MANIFEST_DIR"), "/migrations");
|
||||
db.migrate(Path::new(migrations_path), false).await.unwrap();
|
||||
run_database_migrations(db.options(), migrations_path, false)
|
||||
.await
|
||||
.unwrap();
|
||||
db.initialize_notification_kinds().await.unwrap();
|
||||
db
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue