pub struct BuildCacheCounts {
pub hits: u64,
pub misses: u64,
pub read_bytes: u64,
pub written_bytes: u64,
pub refused: u64,
pub writer: bool,
}Expand description
What the shared build cache served one runner and took from it (ADR 0052), counted by the cache itself.
Fields§
§hits: u64Lookups that found an entry.
misses: u64Lookups that found none.
read_bytes: u64Bytes of the entries it served.
written_bytes: u64Bytes of the entries it stored.
refused: u64Entries it was sent and did not store: the job may not write (a pull request, another branch), or the cache was full.
writer: boolWhether the job could write: a push, scheduled or manually started run of a branch that may write.
Implementations§
Source§impl BuildCacheCounts
impl BuildCacheCounts
Sourcepub fn hit_percent(&self) -> Option<u64>
pub fn hit_percent(&self) -> Option<u64>
Hits in percent of lookups, None without any.
Sourcepub fn add(&mut self, other: &BuildCacheCounts)
pub fn add(&mut self, other: &BuildCacheCounts)
Adds other’s counts; writer stays.
Source§impl BuildCacheCounts
impl BuildCacheCounts
Sourcepub fn activity(&self) -> Option<BuildCacheActivity>
pub fn activity(&self) -> Option<BuildCacheActivity>
What it did, for a job that used it at all: looked an entry up, stored one, or was refused one. None for
a job that never used it.
Trait Implementations§
Source§impl Clone for BuildCacheCounts
impl Clone for BuildCacheCounts
impl Copy for BuildCacheCounts
Source§impl Debug for BuildCacheCounts
impl Debug for BuildCacheCounts
Source§impl Default for BuildCacheCounts
impl Default for BuildCacheCounts
Source§impl<'de> Deserialize<'de> for BuildCacheCounts
impl<'de> Deserialize<'de> for BuildCacheCounts
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for BuildCacheCounts
Source§impl PartialEq for BuildCacheCounts
impl PartialEq for BuildCacheCounts
Source§impl Serialize for BuildCacheCounts
impl Serialize for BuildCacheCounts
impl StructuralPartialEq for BuildCacheCounts
Auto Trait Implementations§
impl Freeze for BuildCacheCounts
impl RefUnwindSafe for BuildCacheCounts
impl Send for BuildCacheCounts
impl Sync for BuildCacheCounts
impl Unpin for BuildCacheCounts
impl UnsafeUnpin for BuildCacheCounts
impl UnwindSafe for BuildCacheCounts
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.