Struct fluence_faas::FluenceFaaS
source · [−]pub struct FluenceFaaS { /* private fields */ }
Implementations
sourceimpl FluenceFaaS
impl FluenceFaaS
sourcepub fn with_raw_config<C>(config: C) -> Result<Self, FaaSError> where
C: TryInto<FaaSConfig>,
FaaSError: From<C::Error>,
pub fn with_raw_config<C>(config: C) -> Result<Self, FaaSError> where
C: TryInto<FaaSConfig>,
FaaSError: From<C::Error>,
Creates FaaS from config deserialized from TOML.
sourcepub fn with_modules<C>(
modules: HashMap<String, Vec<u8>>,
config: C
) -> Result<Self, FaaSError> where
C: TryInto<FaaSConfig>,
FaaSError: From<C::Error>,
pub fn with_modules<C>(
modules: HashMap<String, Vec<u8>>,
config: C
) -> Result<Self, FaaSError> where
C: TryInto<FaaSConfig>,
FaaSError: From<C::Error>,
Creates FaaS with given modules.
sourcepub fn with_module_names<C>(
names: &HashMap<String, String>,
config: C
) -> Result<Self, FaaSError> where
C: TryInto<FaaSConfig>,
FaaSError: From<C::Error>,
pub fn with_module_names<C>(
names: &HashMap<String, String>,
config: C
) -> Result<Self, FaaSError> where
C: TryInto<FaaSConfig>,
FaaSError: From<C::Error>,
Searches for modules in config.modules_dir
, loads only those in the names
set
sourcepub fn call_with_ivalues(
&mut self,
module_name: impl AsRef<str>,
func_name: impl AsRef<str>,
args: &[IValue],
call_parameters: CallParameters
) -> Result<Vec<IValue>, FaaSError>
pub fn call_with_ivalues(
&mut self,
module_name: impl AsRef<str>,
func_name: impl AsRef<str>,
args: &[IValue],
call_parameters: CallParameters
) -> Result<Vec<IValue>, FaaSError>
Call a specified function of loaded on a startup module by its name.
sourcepub fn call_with_json(
&mut self,
module_name: impl AsRef<str>,
func_name: impl AsRef<str>,
json_args: JValue,
call_parameters: CallParameters
) -> Result<JValue, FaaSError>
pub fn call_with_json(
&mut self,
module_name: impl AsRef<str>,
func_name: impl AsRef<str>,
json_args: JValue,
call_parameters: CallParameters
) -> Result<JValue, FaaSError>
Call a specified function of loaded on a startup module by its name.
sourcepub fn get_interface(&self) -> FaaSInterface<'_>
pub fn get_interface(&self) -> FaaSInterface<'_>
Return all export functions (name and signatures) of loaded modules.
sourcepub fn module_memory_stats(&self) -> MemoryStats<'_>
pub fn module_memory_stats(&self) -> MemoryStats<'_>
Return statistic of Wasm modules heap footprint.
Trait Implementations
impl Send for FluenceFaaS
Auto Trait Implementations
impl !RefUnwindSafe for FluenceFaaS
impl !Sync for FluenceFaaS
impl Unpin for FluenceFaaS
impl !UnwindSafe for FluenceFaaS
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more