MCPcopy Create free account
hub / github.com/CodSpeedHQ/codspeed / new_compressed_in_memory

Method new_compressed_in_memory

src/upload/profile_archive.rs:20–26  ·  view source on GitHub ↗
(data: Vec<u8>)

Source from the content-addressed store, hash-verified

18
19impl ProfileArchive {
20 pub fn new_compressed_in_memory(data: Vec<u8>) -> Self {
21 let hash = general_purpose::STANDARD.encode(md5::compute(&data).0);
22 ProfileArchive {
23 hash,
24 content: ProfileArchiveContent::CompressedInMemory { data },
25 }
26 }
27
28 pub fn new_uncompressed_on_disk(path: PathBuf) -> Result<Self> {
29 let metadata = std::fs::metadata(&path)?;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected