Skip to content

Commit

Permalink
chore: add docs on DB_CONNECTIONS
Browse files Browse the repository at this point in the history
  • Loading branch information
JasonShin committed Oct 1, 2023
1 parent 52a643d commit eb3183a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/common/lazy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ lazy_static! {
cache
};

// This variable holds a singleton of DBConnections that is used to get a DBConn from the cache
// DBConn is used to access the raw connection to the database or run `prepare` statement against each connection
pub static ref DB_CONNECTIONS: Mutex<DBConnections<'static>> = {
let db_connections = DBConnections::new(&DB_CONN_CACHE);
Mutex::new(db_connections)
Expand Down

0 comments on commit eb3183a

Please sign in to comment.