Module tar

Module tar 

Source
Expand description

TAR archive processing and split stream conversion.

This module handles the conversion of tar archives (container image layers) into composefs split streams. It provides both synchronous and asynchronous tar processing, intelligently deciding whether to store file content inline in the split stream or externally in the object store based on file size.

Key components include the split() and split_async() functions for converting tar streams, get_entry() for reading back tar entries from split streams, and comprehensive support for tar format features including GNU long names, PAX extensions, and various file types. The TarEntry and TarItem types represent processed tar entries in composefs format.

Structs§

TarEntry
Represents a complete tar entry extracted from a split stream.

Enums§

TarItem
Represents the content type of a tar entry.

Functions§

get_entry
Reads and parses the next tar entry from a split stream.
path_from_tar 🔒
read_header 🔒
read_header_async 🔒
receive_and_finalize_object 🔒
Receive data from channel, write to tmpfile, compute verity, and store object.
split
Splits the tar file from tar_stream into a Split Stream. The store_data function is responsible for ensuring that “external data” is in the composefs repository and returns the fsverity hash value of that data.
split_async
Asynchronously splits a tar archive into a composefs split stream.
symlink_target_from_tar 🔒