Trait channel_loader::diesel::DieselWorker [−][src]
pub trait DieselWorker: Send + Sync { type Key: Key; type Value: Send + Clone + 'static; const MAX_BATCH_SIZE: i32; fn load(
conn: PooledConnection,
keys: Vec<Self::Key>
) -> Result<HashMap<Self::Key, Self::Value>, DieselError>; }
Expand description
a diesel
specific loader interface designed with that optimizes batching around connection acquisition using diesel_connection::get_connection
.
Associated Types
Associated Constants
const MAX_BATCH_SIZE: i32
[src]Required methods
fn load(
conn: PooledConnection,
keys: Vec<Self::Key>
) -> Result<HashMap<Self::Key, Self::Value>, DieselError>
[src]