Remove unnecessary parameter
This commit is contained in:
@@ -578,7 +578,6 @@ pub async fn make_scylla_stream(
|
|||||||
pub async fn channel_state_events(
|
pub async fn channel_state_events(
|
||||||
evq: &ChannelStateEventsQuery,
|
evq: &ChannelStateEventsQuery,
|
||||||
scyco: &ScyllaConfig,
|
scyco: &ScyllaConfig,
|
||||||
_dbconf: Database,
|
|
||||||
) -> Result<Vec<(u64, u32)>, Error> {
|
) -> Result<Vec<(u64, u32)>, Error> {
|
||||||
let scy = scylla::SessionBuilder::new()
|
let scy = scylla::SessionBuilder::new()
|
||||||
.known_nodes(&scyco.hosts)
|
.known_nodes(&scyco.hosts)
|
||||||
|
|||||||
@@ -1,6 +1,5 @@
|
|||||||
use crate::bodystream::response;
|
use crate::bodystream::response;
|
||||||
use crate::err::Error;
|
use crate::err::Error;
|
||||||
use dbconn::events_scylla::channel_state_events;
|
|
||||||
use http::{Method, Request, Response, StatusCode};
|
use http::{Method, Request, Response, StatusCode};
|
||||||
use hyper::Body;
|
use hyper::Body;
|
||||||
use netpod::query::ChannelStateEventsQuery;
|
use netpod::query::ChannelStateEventsQuery;
|
||||||
@@ -49,14 +48,13 @@ impl ConnectionStatusEvents {
|
|||||||
q: &ChannelStateEventsQuery,
|
q: &ChannelStateEventsQuery,
|
||||||
node_config: &NodeConfigCached,
|
node_config: &NodeConfigCached,
|
||||||
) -> Result<Vec<(u64, u32)>, Error> {
|
) -> Result<Vec<(u64, u32)>, Error> {
|
||||||
let dbconf = &node_config.node_config.cluster.database;
|
|
||||||
let scyco = node_config
|
let scyco = node_config
|
||||||
.node_config
|
.node_config
|
||||||
.cluster
|
.cluster
|
||||||
.scylla
|
.scylla
|
||||||
.as_ref()
|
.as_ref()
|
||||||
.ok_or_else(|| Error::with_public_msg_no_trace(format!("No Scylla configured")))?;
|
.ok_or_else(|| Error::with_public_msg_no_trace(format!("No Scylla configured")))?;
|
||||||
let ret = channel_state_events(q, scyco, dbconf.clone()).await?;
|
let ret = dbconn::events_scylla::channel_state_events(q, scyco).await?;
|
||||||
Ok(ret)
|
Ok(ret)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -103,14 +101,13 @@ impl ChannelConnectionStatusEvents {
|
|||||||
q: &ChannelStateEventsQuery,
|
q: &ChannelStateEventsQuery,
|
||||||
node_config: &NodeConfigCached,
|
node_config: &NodeConfigCached,
|
||||||
) -> Result<Vec<(u64, u32)>, Error> {
|
) -> Result<Vec<(u64, u32)>, Error> {
|
||||||
let dbconf = &node_config.node_config.cluster.database;
|
|
||||||
let scyco = node_config
|
let scyco = node_config
|
||||||
.node_config
|
.node_config
|
||||||
.cluster
|
.cluster
|
||||||
.scylla
|
.scylla
|
||||||
.as_ref()
|
.as_ref()
|
||||||
.ok_or_else(|| Error::with_public_msg_no_trace(format!("No Scylla configured")))?;
|
.ok_or_else(|| Error::with_public_msg_no_trace(format!("No Scylla configured")))?;
|
||||||
let ret = channel_state_events(q, scyco, dbconf.clone()).await?;
|
let ret = dbconn::events_scylla::channel_state_events(q, scyco).await?;
|
||||||
Ok(ret)
|
Ok(ret)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user