Skip to content

Re-use previous Pipeline results rather than relying on BuildKit caching #591

Closed

Description

@aluzzardi

See #193 for previous attempt.

This has been causing massive headaches and some issues are still not fixed.

There's a few causes, some of the most recent ones:

  • always: true only guarantees the instructions to run ONCE for each dagger up.
    • things like generating a random number with always: true will yield the same random number for everything using it in the plan
    • if that wasn't the case, mount: from: would generate a different random number

Activity

  1. added
    kind/bug
    on Jun 8, 2021
  2. added this to the v0.1.0 milestone on Jun 8, 2021
  3. aluzzardi commented on Jun 9, 2021

    @aluzzardi
    ContributorAuthor

    It's actually worse than this:

    BuildKit de duplicates the same requests even if they come from the different sessions.

    Meaning that calling random.#String in two different dagger up results in the same random string being generated

  4. self-assigned this
    on Aug 25, 2021
  5. aluzzardi commented on Oct 19, 2021

    @aluzzardi
    ContributorAuthor

    Another couple of issues:

    • Side requests are not being cached. Operations such as DockerPush are not LLB but gRPC calls, those get re-issued every time we encounter a DockerPush operation
    • It's impossible to get a "stable key". This affects more than always: true. For instance, DockerSave needs to generate a temporary file. If we use os.CreateTemp, then each execution (e.g. each reference) gets a different path. If we use the CUE path as key, each reference also gets a different key
  6. aluzzardi commented on Jan 7, 2022

    @aluzzardi
    ContributorAuthor

    Implemented in Europa

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

kind/bug

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions