Skip to content

Commit

Permalink
Expose PluginManager for sessions.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jezza committed Jan 16, 2025
1 parent 4173948 commit 55cd6a2
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions zenoh/src/api/session.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
// Contributors:
// ZettaScale Zenoh Team, <[email protected]>
//
#[cfg(feature = "plugins")]
use std::sync::MutexGuard;
use std::{
collections::{hash_map::Entry, HashMap},
convert::TryInto,
Expand All @@ -23,6 +25,8 @@ use std::{
time::{Duration, SystemTime, UNIX_EPOCH},
};

#[cfg(feature = "plugins")]
use crate::api::plugins::PluginsManager;
use async_trait::async_trait;
#[zenoh_macros::internal]
use ref_cast::ref_cast_custom;
Expand Down Expand Up @@ -713,6 +717,11 @@ impl Session {
self.0.runtime.hlc()
}

#[cfg(feature = "plugins")]
pub fn plugins_manager(&self) -> MutexGuard<'_, PluginsManager> {
self.0.runtime.plugins_manager()
}

/// Close the zenoh [`Session`](Session).
///
/// Every subscriber and queryable declared will stop receiving data, and further attempt to
Expand Down

0 comments on commit 55cd6a2

Please sign in to comment.