Trait nektar::FacebookServiceSyncHandler
source · pub trait FacebookServiceSyncHandler {
Show 13 methods
// Required methods
fn handle_get_name(&self) -> Result<String>;
fn handle_get_version(&self) -> Result<String>;
fn handle_get_status(&self) -> Result<FbStatus>;
fn handle_get_status_details(&self) -> Result<String>;
fn handle_get_counters(&self) -> Result<BTreeMap<String, i64>>;
fn handle_get_counter(&self, key: String) -> Result<i64>;
fn handle_set_option(&self, key: String, value: String) -> Result<()>;
fn handle_get_option(&self, key: String) -> Result<String>;
fn handle_get_options(&self) -> Result<BTreeMap<String, String>>;
fn handle_get_cpu_profile(
&self,
profile_duration_in_sec: i32
) -> Result<String>;
fn handle_alive_since(&self) -> Result<i64>;
fn handle_reinitialize(&self) -> Result<()>;
fn handle_shutdown(&self) -> Result<()>;
}Expand description
Standard base service
Required Methods§
sourcefn handle_get_name(&self) -> Result<String>
fn handle_get_name(&self) -> Result<String>
Returns a descriptive name of the service
sourcefn handle_get_version(&self) -> Result<String>
fn handle_get_version(&self) -> Result<String>
Returns the version of the service
sourcefn handle_get_status(&self) -> Result<FbStatus>
fn handle_get_status(&self) -> Result<FbStatus>
Gets the status of this service
sourcefn handle_get_status_details(&self) -> Result<String>
fn handle_get_status_details(&self) -> Result<String>
User friendly description of status, such as why the service is in the dead or warning state, or what is being started or stopped.
sourcefn handle_get_counters(&self) -> Result<BTreeMap<String, i64>>
fn handle_get_counters(&self) -> Result<BTreeMap<String, i64>>
Gets the counters for this service
sourcefn handle_get_counter(&self, key: String) -> Result<i64>
fn handle_get_counter(&self, key: String) -> Result<i64>
Gets the value of a single counter
sourcefn handle_get_option(&self, key: String) -> Result<String>
fn handle_get_option(&self, key: String) -> Result<String>
Gets an option
sourcefn handle_get_cpu_profile(&self, profile_duration_in_sec: i32) -> Result<String>
fn handle_get_cpu_profile(&self, profile_duration_in_sec: i32) -> Result<String>
Returns a CPU profile over the given time interval (client and server must agree on the profile format).
sourcefn handle_alive_since(&self) -> Result<i64>
fn handle_alive_since(&self) -> Result<i64>
Returns the unix time that the server has been running since
sourcefn handle_reinitialize(&self) -> Result<()>
fn handle_reinitialize(&self) -> Result<()>
Tell the server to reload its configuration, reopen log files, etc
sourcefn handle_shutdown(&self) -> Result<()>
fn handle_shutdown(&self) -> Result<()>
Suggest a shutdown to the server