Skip to content

Commit 5da4ec2

Browse files
committed
feat: lock
1 parent c90214f commit 5da4ec2

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

frameworks/Rust/hyperlane/src/db.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
use std::{time::Duration, u64};
2-
31
use crate::*;
42

53
#[inline]
@@ -120,7 +118,7 @@ pub async fn connection_db() -> DbPoolConnection {
120118
};
121119
let pool: DbPoolConnection = PgPoolOptions::new()
122120
.max_connections(1_000)
123-
.max_lifetime(Some(Duration::from_secs(u64::MAX)))
121+
.max_lifetime(Some(Duration::from_secs(860_400)))
124122
.idle_timeout(None)
125123
.connect(db_url)
126124
.await

frameworks/Rust/hyperlane/src/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ pub(crate) use sqlx::{
3131
postgres::{PgPoolOptions, PgRow},
3232
Pool, Postgres, Row,
3333
};
34-
pub(crate) use std::{fmt, sync::Arc};
34+
pub(crate) use std::{fmt, sync::Arc, time::Duration};
3535
pub(crate) use utils::*;
3636

3737
#[tokio::main]

0 commit comments

Comments
 (0)