Skip to content

Commit

Permalink
fix: removed mutex
Browse files Browse the repository at this point in the history
  • Loading branch information
nikola-bozin-org committed May 11, 2024
1 parent 1046b53 commit aaa058a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ services:
POSTGRES_DB: ${POSTGRES_DB}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
ports:
- "5432:5432"
- "5430:5432"
volumes:
- ./docker-volumes/postgres-wisdomia-monolithic-volume:/var/lib/postgresql/data
networks:
Expand Down
4 changes: 2 additions & 2 deletions server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ use std::{env, net::SocketAddr, sync::Arc};

use axum::{middleware, Extension, Router};
use middlewares::response_mapper;
use tokio::{net::TcpListener, sync::Mutex};
use tokio::net::TcpListener;

use crate::{
constants::{REQUESTS_AMOUNT_LIMIT, REQUESTS_AMOUNT_TIME_FRAME},
Expand Down Expand Up @@ -50,7 +50,7 @@ async fn main() {
rate_limiter_config,
};

let shared_state = Arc::new(Mutex::new(state));
let shared_state = Arc::new(state);

let listener = TcpListener::bind(format!("{}:{}", constants::HOST, constants::PORT))
.await
Expand Down

0 comments on commit aaa058a

Please sign in to comment.