Skip to content

Commit a7354bd

Browse files
committed
Request all properties from message hub
Signed-off-by: Luca Arato <luca.arato@secomind.com>
1 parent 1423ebf commit a7354bd

3 files changed

Lines changed: 65 additions & 158 deletions

File tree

src/builder.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ pub struct Config {
107107
pub(crate) writable_dir: Option<PathBuf>,
108108
}
109109

110-
/// Struct use to pass the connection configuration to the [`ConnectionConfig`]
110+
/// Struct used to pass the connection configuration to the [`ConnectionConfig`]
111111
#[derive(Debug, Clone)]
112112
pub struct ConnectionBuildConfig<'a, S> {
113113
pub(crate) store: S,

src/transport/grpc/mod.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -522,7 +522,7 @@ impl<S> Connection for Grpc<S>
522522
where
523523
S: PropertyStore,
524524
{
525-
type Sender = GrpcClient<GrpcStore<S>>;
525+
type Sender = GrpcClient<GrpcStore>;
526526
}
527527

528528
/// Internal struct holding the received grpc message
@@ -568,7 +568,7 @@ impl<S> ConnectionConfig<S> for GrpcConfig
568568
where
569569
S: StoreCapabilities + PropertyStore + Send + Sync,
570570
{
571-
type Store = GrpcStore<S>;
571+
type Store = GrpcStore;
572572
type Conn = Grpc<S>;
573573
type Err = GrpcError;
574574

@@ -577,9 +577,7 @@ where
577577
config: ConnectionBuildConfig<'_, S>,
578578
) -> Result<DeviceTransport<Self::Store, Self::Conn>, Self::Err> {
579579
let ConnectionBuildConfig {
580-
store,
581-
interfaces,
582-
config,
580+
interfaces, config, ..
583581
} = config;
584582

585583
let channel = self.endpoint.connect().await.map_err(GrpcError::from)?;
@@ -591,7 +589,7 @@ where
591589
let node_data = NodeData::try_from(interfaces)?;
592590
let stream = Grpc::<StoreWrapper<S>>::attach(&mut client, node_data).await?;
593591

594-
let grpc_store = StoreWrapper::new(GrpcStore::new(store.clone(), client.clone()));
592+
let grpc_store = StoreWrapper::new(GrpcStore::new(client.clone()));
595593

596594
let sender = GrpcClient::new(client.clone(), grpc_store.clone(), config.volatile.clone());
597595
let receiver = Grpc::new(self.uuid, client, stream);

0 commit comments

Comments
 (0)