Code Monkey home page Code Monkey logo

Comments (9)

ThomasWaldmann avatar ThomasWaldmann commented on July 17, 2024

Just to keep a vague idea:

If the different layers in borg would communicate a bit more (like the compression method being flexibly given by upper layers and the decompression result being able to tell whether its result is data that needs to be written to disk or just a sparse hole that needs to be "seeked"), the adv. sparse file support could maybe be just a special kind of "compression/decompression".

sparse compression would just store: 2 type bytes for "sparse", 8 bytes length of hole
sparse decompression would result in: hole=True, hole length
other decompression would result in: hole=False, data

instead of a hole=X value, it could be also an entry in a more generally useful meta dict, see #765.

from borg.

ThomasWaldmann avatar ThomasWaldmann commented on July 17, 2024

Advanced sparse file support would also save some time for archive creation as it does not have to read all these zeros in the sparse wholes (simple sparse file support just reads them all).

from borg.

enkore avatar enkore commented on July 17, 2024

The less involved feature, not having to chunk-HMAC hole contents is handled in #1354

from borg.

ThomasWaldmann avatar ThomasWaldmann commented on July 17, 2024

@milkey-mouse bs just told me you have started on this. maybe first evaluate how much changes this needs - if it is a bigger change, it might be not applicable to 1.1-maint (and also might conflict with 1.2 goals).

from borg.

milkey-mouse avatar milkey-mouse commented on July 17, 2024

I wrote some C code to list holes in files here which could implement #1354. I can think of a backwards-compatible way of implementing it on the borg side by using the method described in #1354, but putting a list of hole locations in the chunk metadata (#934).

from borg.

ThomasWaldmann avatar ThomasWaldmann commented on July 17, 2024

considering that the new "fixed" chunker is much simpler than the "buzhash" chunker, it might be easy to add sparse file support there.

as the fixed chunker is better suited for block devices and raw disk files, that would be exactly the place where sparse support is most needed.

from borg.

ThomasWaldmann avatar ThomasWaldmann commented on July 17, 2024

I'll try to solve this for the fixed-blocksize chunker...

from borg.

ThomasWaldmann avatar ThomasWaldmann commented on July 17, 2024

Looks like this bounty is too low / too big in scope.

To have a more incremental approach, I created a new issue / new bounty with a more narrow scope:

#5565

So, guess that one will be solved soon and later we can continue with this bounty (after way more backing is added to this bounty).

from borg.

ThomasWaldmann avatar ThomasWaldmann commented on July 17, 2024

there was some more progress in #5620, limited to chunker and hasher. compression and storage not affected yet.

from borg.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.