pub struct Store {
pub data_dir: PathBuf,
/* private fields */
}Fields§
§data_dir: PathBufImplementations§
Source§impl Store
impl Store
pub fn open(data_dir: PathBuf) -> Result<Self>
pub fn pricing_for(&self, model: &str) -> Option<Pricing>
pub fn pricing_models(&self) -> Vec<String>
pub fn insert_trace(&self, t: &TraceRecord) -> Result<()>
pub fn list_traces( &self, limit: usize, session: Option<&str>, model: Option<&str>, ) -> Result<Vec<Value>>
pub fn search_traces(&self, f: &TraceFilter) -> Result<Vec<Value>>
pub fn sessions( &self, since_ms: Option<i64>, limit: usize, ) -> Result<Vec<Value>>
pub fn session_traces( &self, session_id: &str, since_ms: Option<i64>, ) -> Result<Vec<Value>>
pub fn get_trace(&self, id: &str) -> Result<Option<Value>>
pub fn delete_trace(&self, id: &str) -> Result<Vec<String>>
pub fn run_summary(&self, run_id: &str) -> Result<Value>
pub fn run_artifacts(&self, run_id: &str) -> Result<Vec<Value>>
pub fn insert_heartbeat( &self, ts_ms: i64, provider: &str, account_id: Option<&str>, ok: bool, status: Option<i64>, latency_ms: i64, message: &str, ) -> Result<()>
pub fn last_heartbeats(&self) -> Result<Vec<Value>>
pub fn latest_provider_headers(&self) -> Result<Vec<(String, i64, String)>>
pub fn analytics(&self, since_ms: i64) -> Result<Value>
pub fn insert_run_key( &self, id: &str, key_hash: &str, kind: &str, run_id: Option<&str>, tags_json: Option<&str>, label: Option<&str>, created_ms: i64, expires_ms: Option<i64>, ) -> Result<()>
pub fn lookup_run_key( &self, key_hash: &str, now_ms: i64, ) -> Result<Option<Value>>
pub fn touch_run_key(&self, key_hash: &str, now_ms: i64) -> Result<()>
pub fn list_run_keys(&self, include_inactive: bool) -> Result<Vec<Value>>
pub fn revoke_run_key(&self, id_or_prefix: &str) -> Result<bool>
pub fn prune( &self, older_than_ms: i64, bodies_only: bool, dry_run: bool, ) -> Result<PruneReport>
pub fn disk_usage(&self) -> Result<Value>
pub fn write_body( &self, trace_id: &str, kind: &str, bytes: &[u8], ) -> Result<String>
Auto Trait Implementations§
impl !Freeze for Store
impl RefUnwindSafe for Store
impl Send for Store
impl Sync for Store
impl Unpin for Store
impl UnsafeUnpin for Store
impl UnwindSafe for Store
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more