Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: benchmarking and Cachix improvements #1230

Merged
merged 2 commits into from
Apr 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 0 additions & 23 deletions .buildkite/cachix-push.yaml

This file was deleted.

9 changes: 0 additions & 9 deletions .buildkite/pipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,3 @@ steps:
agents:
queue: "nix-build"
os: "darwin"

- label: ":nixos: :buildkite: :stopwatch: Run benchmarks"
command: nix-buildkite
agents:
queue: "nix-benchmark"
plugins:
- hackworthltd/nix#v1.0.0:
file: ci-benchmarks.nix
agent-tags: queue=nix-benchmark
2 changes: 0 additions & 2 deletions ci-benchmarks.nix

This file was deleted.

41 changes: 4 additions & 37 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@

imports = [
inputs.pre-commit-hooks-nix.flakeModule
./nix/flake-parts/benchmarks.nix
];
systems = [ "x86_64-linux" "aarch64-darwin" ];

Expand Down Expand Up @@ -158,7 +157,6 @@
baseName == "SECURITY.md" ||
baseName == "bugreport.sh" ||
pkgs.lib.hasPrefix "cabal.project.local" baseName ||
baseName == "ci-benchmarks.nix" ||
baseName == "ci.nix" ||
baseName == "default.nix" ||
baseName == "docs" ||
Expand Down Expand Up @@ -255,6 +253,9 @@
}
// (pkgs.lib.optionalAttrs (system == "x86_64-linux") {
inherit (pkgs) primer-service-docker-image;
inherit (pkgs) primer-benchmark-results-json;
inherit (pkgs) primer-criterion-results-github-action-benchmark;
inherit (pkgs) primer-benchmark-results-github-action-benchmark;
})
// primerFlake.packages;

Expand Down Expand Up @@ -340,20 +341,6 @@
];
};
};

# This is a non-standard flake output, but we don't want to
# include benchmark runs in `packages`, because we don't
# want them to be part of the `hydraJobs` or `ciJobs`
# attrsets. The benchmarks need to be run in a more
# controlled environment, and this gives us that
# flexibility.
benchmarks = {
inherit (pkgs) primer-benchmark-results-json;
inherit (pkgs) primer-criterion-results-github-action-benchmark;
}
// (pkgs.lib.optionalAttrs (system == "x86_64-linux")
{ inherit (pkgs) primer-benchmark-results-github-action-benchmark; }
);
};

flake =
Expand All @@ -368,18 +355,6 @@
};
overlays = allOverlays;
};

benchmarkJobs = {
inherit (inputs.self.benchmarks) x86_64-linux;

required-benchmarks = pkgs.releaseTools.aggregate {
name = "required-benchmarks";
constituents = builtins.map builtins.attrValues (with inputs.self; [
benchmarks.x86_64-linux
]);
meta.description = "Required CI benchmarks";
};
};
in
{
overlays.default = (final: prev:
Expand Down Expand Up @@ -635,7 +610,7 @@
# them.
benchmarks =
let
lastEnvChange = "20240408.01";
lastEnvChange = "20240408.02";
in
final.callPackage ./nix/pkgs/benchmarks {
inherit lastEnvChange;
Expand Down Expand Up @@ -667,13 +642,6 @@

inherit primer-openapi-spec;

# Note to the reader: these derivations run benchmarks
# and collect the results in various formats. They're
# part of the flake's overlay, so they appear in any
# `pkgs` that uses this overlay. Hoewver, we do *not*
# include these in the flake's `packages` output,
# because we don't want them to be built/run when CI
# evaluates the `hydraJobs` or `ciJobs` outputs.
inherit (benchmarks) primer-benchmark-results-json;
inherit (benchmarks) primer-criterion-results-github-action-benchmark;
inherit (benchmarks) primer-benchmark-results-github-action-benchmark;
Expand Down Expand Up @@ -702,7 +670,6 @@
};

ciJobs = inputs.hacknix.lib.flakes.recurseIntoHydraJobs inputs.self.hydraJobs;
ciBenchmarks = inputs.hacknix.lib.flakes.recurseIntoHydraJobs benchmarkJobs;
};
};
}
25 changes: 0 additions & 25 deletions nix/flake-parts/benchmarks.nix

This file was deleted.

Loading