MCPcopy Create free account
hub / github.com/chirpstack/chirpstack / get_async_db_conn

Function get_async_db_conn

chirpstack/src/storage/sqlite.rs:84–93  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

82}
83
84pub async fn get_async_db_conn() -> Result<AsyncSqlitePoolConnection> {
85 let pool = get_async_db_pool()?;
86
87 let start = Instant::now();
88 let res = pool.get().await?;
89
90 STORAGE_SQLITE_CONN_GET.observe(start.elapsed().as_secs_f64());
91
92 Ok(res)
93}
94
95fn set_async_db_pool(p: AsyncSqlitePool) {
96 let mut pool_w = ASYNC_SQLITE_POOL.write().unwrap();

Callers 15

enqueue_itemFunction · 0.70
get_itemFunction · 0.70
update_itemFunction · 0.70
delete_itemFunction · 0.70
get_next_for_dev_euiFunction · 0.70
get_for_dev_euiFunction · 0.70
flush_for_dev_euiFunction · 0.70
get_pending_for_dev_euiFunction · 0.70
get_max_f_cnt_downFunction · 0.70
createFunction · 0.70
getFunction · 0.70

Calls 2

get_async_db_poolFunction · 0.70
getMethod · 0.45

Tested by 1