These utilities are provided to help perform operations on files and I/O streams.
◆ read_entire_file()
Returns all bytes from the file until eof, accessible in chunks.
- Note
- use only on short files to avoid running out of memory.
- Parameters
-
path | path of the file to be read. |
◆ read_entire_file_contiguous()
future<sstring> seastar::util::read_entire_file_contiguous |
( |
std::filesystem::path |
path | ) |
|
Returns all bytes from the file until eof as a single buffer.
- Note
- use only on short files to avoid running out of memory.
- Parameters
-
path | path of the file to be read. |