Centralize durable schema migration ownership
This commit is contained in:
parent
cc328237f4
commit
069f3813ae
1 changed files with 354 additions and 350 deletions
|
|
@ -1,12 +1,9 @@
|
|||
use std::{net::TcpListener, time::Duration};
|
||||
|
||||
use actix_web::{App, HttpServer, web};
|
||||
use remora_admission::{AdmissionConfig, AdmissionService, migrate as admission_migrate};
|
||||
use remora_api::{
|
||||
PublicApiConfig, PublicApiServices, PublicApiState, configure_public_api,
|
||||
migrate as api_migrate,
|
||||
};
|
||||
use remora_attempt::{AttemptConfig, AttemptService, migrate as attempt_migrate};
|
||||
use remora_admission::{AdmissionConfig, AdmissionService};
|
||||
use remora_api::{PublicApiConfig, PublicApiServices, PublicApiState, configure_public_api};
|
||||
use remora_attempt::{AttemptConfig, AttemptService};
|
||||
use remora_contracts::{
|
||||
AttemptPageDto, DeletionOperationDto, JobPageDto, JobResourceDto, ResultDescriptorDto,
|
||||
ResultMemberPageDto, SourceCredentialDto,
|
||||
|
|
@ -14,16 +11,12 @@ use remora_contracts::{
|
|||
use remora_coordination::{
|
||||
ActivateOptions, CoordinationStore, LeaseOwner, ProgressValue, StoreConfig,
|
||||
};
|
||||
use remora_credentials::{
|
||||
CredentialRegistry, VaultClient, VaultConfig, migrate as credentials_migrate,
|
||||
};
|
||||
use remora_deletion::{
|
||||
DeletionConfig, DeletionService, TargetRegistry, migrate as deletion_migrate,
|
||||
};
|
||||
use remora_credentials::{CredentialRegistry, VaultClient, VaultConfig};
|
||||
use remora_deletion::{DeletionConfig, DeletionService, TargetRegistry};
|
||||
use remora_domain::{BucketName, OpaqueId, TargetPrefix, TargetStoreId};
|
||||
use remora_durable::{PoolConfig, connect, migrate as durable_migrate};
|
||||
use remora_identity::{DefaultTarget, migrate as identity_migrate};
|
||||
use remora_result::migrate as result_migrate;
|
||||
use remora_durable::{PoolConfig, connect};
|
||||
use remora_identity::DefaultTarget;
|
||||
use remora_schema::migrate as migrate_schema;
|
||||
use remora_target::{
|
||||
CreateObjectRequest, TargetStore, TargetStoreConfig, attempt_manifest_key_in,
|
||||
attempt_object_key_in,
|
||||
|
|
@ -64,14 +57,7 @@ impl Harness {
|
|||
)
|
||||
.await
|
||||
.unwrap();
|
||||
durable_migrate(&pool).await.unwrap();
|
||||
identity_migrate(&pool).await.unwrap();
|
||||
credentials_migrate(&pool).await.unwrap();
|
||||
admission_migrate(&pool).await.unwrap();
|
||||
attempt_migrate(&pool).await.unwrap();
|
||||
result_migrate(&pool).await.unwrap();
|
||||
deletion_migrate(&pool).await.unwrap();
|
||||
api_migrate(&pool).await.unwrap();
|
||||
migrate_schema(&pool).await.unwrap();
|
||||
sqlx::query("TRUNCATE TABLE jobs CASCADE")
|
||||
.execute(&pool)
|
||||
.await
|
||||
|
|
|
|||
Loading…
Reference in a new issue