Struct sentry_rs::Sentry
[−]
[src]
pub struct Sentry { pub server_name: String, pub release: String, pub environment: String, pub worker: Arc<SingleWorker<Event, SentryCredentials>>, pub reciever: Arc<Mutex<Receiver<()>>>, }
A Sentry Object, instiates the worker, and actually is what you send your sentry events too.
Fields
server_name: String
release: String
environment: String
worker: Arc<SingleWorker<Event, SentryCredentials>>
reciever: Arc<Mutex<Receiver<()>>>
Methods
impl Sentry
[src]
fn new(server_name: String,
release: String,
environment: String,
credentials: SentryCredentials)
-> Sentry
release: String,
environment: String,
credentials: SentryCredentials)
-> Sentry
Creates a new connection to Sentry.
fn log_event(&self, e: Event)
Handles a logged event.
fn register_panic_handler(&self)
Sets up a sentry hook to listen for panic!()
's, and post the results to Sentry.
fn register_panic_handler_with_func<F>(&self, maybe_f: Option<F>) where F: Fn(&PanicInfo) + 'static + Sync + Send
fn unregister_panic_handler(&self)
Unregisters the panic handler.
fn fatal(&self, logger: &str, message: &str, culprit: Option<&str>)
Logs a fatal message to sentry.
fn error(&self, logger: &str, message: &str, culprit: Option<&str>)
Logs an error message to sentry.
fn warning(&self, logger: &str, message: &str, culprit: Option<&str>)
Logs a warning message to sentry.
fn info(&self, logger: &str, message: &str, culprit: Option<&str>)
Logs an info message to sentry.
fn debug(&self, logger: &str, message: &str, culprit: Option<&str>)
Logs a debug message to sentry.