feat(presentation): wire SearchPort, /search returns thoughts + users
This commit is contained in:
@@ -7,6 +7,7 @@ pub mod state;
|
||||
use std::sync::Arc;
|
||||
use sqlx::PgPool;
|
||||
use state::AppState;
|
||||
use postgres_search::PgSearchRepository;
|
||||
|
||||
use async_trait::async_trait;
|
||||
use domain::{errors::DomainError, events::DomainEvent, ports::EventPublisher};
|
||||
@@ -34,6 +35,7 @@ pub fn build_state(pool: PgPool, jwt_secret: String) -> AppState {
|
||||
notifications: Arc::new(postgres::notification::PgNotificationRepository::new(pool.clone())),
|
||||
remote_actors: Arc::new(postgres::remote_actor::PgRemoteActorRepository::new(pool.clone())),
|
||||
feed: Arc::new(postgres::feed::PgFeedRepository::new(pool.clone())),
|
||||
search: Arc::new(PgSearchRepository::new(pool.clone())),
|
||||
auth: Arc::new(auth::JwtAuthService::new(jwt_secret, 86400 * 30)),
|
||||
hasher: Arc::new(auth::Argon2PasswordHasher),
|
||||
events: Arc::new(NoOpEventPublisher),
|
||||
|
||||
Reference in New Issue
Block a user