[−][src]Struct arq::tree::Commit
Commit
A "commit" contains the following bytes:
43 6f 6d 6d 69 74 56 30 31 32 "CommitV012"
[String:"<author>"]
[String:"<comment>"]
[UInt64:num_parent_commits] (this is always 0 or 1)
(
[String:parent_commit_sha1] /* can't be null */
[Bool:parent_commit_encryption_key_stretched]] /* present for Commit version >= 4 */
) /* repeat num_parent_commits times */
[String:tree_sha1]] /* can't be null */
[Bool:tree_encryption_key_stretched]] /* present for Commit version >= 4 */
[Bool:tree_is_compressed] /* present for Commit version 8 and 9 only; indicates Gzip compression or none */
[CompressionType:tree_compression_type] /* present for Commit version >= 10 */
[String:"file://<hostname><path_to_folder>"]
[String:"<merge_common_ancestor_sha1>"] /* only present for Commit version 7 or *older* (was never used) */
[Bool:is_merge_common_ancestor_encryption_key_stretched] /* only present for Commit version 4 to 7 */
[Date:creation_date]
[UInt64:num_failed_files] /* only present for Commit version 3 or later */
(
[String:"<relative_path>"] /* only present for Commit version 3 or later */
[String:"<error_message>"] /* only present for Commit version 3 or later */
) /* repeat num_failed_files times */
[Bool:has_missing_nodes] /* only present for Commit version 8 or later */
[Bool:is_complete] /* only present for Commit version 9 or later */
[Data:config_plist_xml] /* a copy of the XML file as described above */
[String:arq_version] /* the version of the Arq app that created this Commit */
The SHA1 of the most recent Commit is stored in
/<computer_uuid>/bucketdata/<folder_uuid>/refs/heads/master
appended with a "Y" for
historical reasons.
In addition, Arq writes a file in
/<computer_uuid>/bucketdata/<folder_uuid>/refs/logs/master
each time a new Commit is
created (the filename is a timestamp). It's a plist containing the previous and current
Commit SHA1s, the SHA1 of the pack file containing the new Commit, and whether the new
Commit is a "rewrite" (because the user deleted a backup record for instance).
Fields
version: u32
comment: String
parent_commits: ParentCommits
tree_sha1: String
tree_encryption_key_stretched: bool
tree_compression_type: CompressionType
folder_path: String
creation_date: Date
failed_files: Vec<FailedFile>
has_missing_nodes: bool
is_complete: bool
config_plist_xml: Vec<u8>
arq_version: String
Methods
impl Commit
[src]
pub fn is_commit(content: &[u8]) -> bool
[src]
pub fn new<R: ArqRead>(reader: R) -> Result<Commit>
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Same<T> for T
type Output = T
Should always be Self