Skip to content

CI: SCA critical path averages 40 minutes on ARM runner #28100

Closed

Description

@XuPeng-SH

Problem

The latest ten successful SCA Test on Linux/arm64 jobs average 45m24s end to end. The Static Code Analysis step alone averages 40m34s (89.4% of job time), with a 28m41s–53m10s range on the existing 4-core/8-GiB runner.

In the latest slow successful sample:

  • molint (go vet -vettool=molint ./...): about 15m18s
  • license header scan: about 11m31s
  • golangci-lint: about 26m04s
  • golangci package loading: about 4m44s
  • golangci memory: 5.90 GiB average / 7.96 GiB peak

The module-cache restore is not the main bottleneck (median about 2m05s). The dominant repeated cost is that molint and golangci-lint independently load and analyze the full Go package graph from a cold ephemeral runner.

Goal

Reduce PR SCA wall time without changing runner specifications and without disabling or narrowing any analyzer, package, license check, or rule.

Proposed invariant

A trusted main workflow produces isolated Go build and golangci analysis caches only after a complete successful SCA run. PR jobs are restore-only and still execute the unchanged make static-check; cache misses fall back to the current cold behavior. Keys include platform, toolchain/compiler, analyzer recipe, configuration/module/native inputs, and periodic rotation.

Baseline evidence

Latest sampled job: https://github.com/matrixorigin/matrixone/actions/runs/33809742095/job/100828980198

Rollout acceptance

Because a trusted default-branch cache cannot be safely published by an unmerged fork PR, acceptance is intentionally staged:

  1. merge ci: reuse SCA analysis caches CI#444 first and rerun ci: warm reusable SCA analysis caches #28101 to validate the complete cold consumer/fallback path;
  2. keep this issue open when ci: warm reusable SCA analysis caches #28101 merges and publishes the first bounded main cache;
  3. use the next representative PR SCA runs to record exact/fallback hit state, restore time, analyzer time, total time, cache size, and cache-eviction impact on the same 4-core/8-GiB runner;
  4. close this issue only after the hot result demonstrates a material improvement without reduced coverage or harmful cache churn. Revert only the restore optimization if acceptance fails.

Activity

  1. self-assigned this
    on Sep 4, 2026
  2. added
    severity/s0
    on Sep 4, 2026
  3. XuPeng-SH commented on Sep 4, 2026

    @XuPeng-SH
    ContributorAuthor

    Reopening because the staged acceptance in this issue has not completed.

    The trusted producer introduced by #28101 ran golangci-lint successfully twice, but both jobs failed before cache publication because the target arm64-mo-shanghai-4c8g runner does not expose a zstd command:

    The failure occurs after 26–30 minutes of analysis at the archive-size estimate, so no PR consumer has obtained a real analysis-cache hit yet.

    #28166 fixes the portability and late-failure problem by matching actions/cache compression selection: complete zstd when available, otherwise its supported gzip fallback, with capability checks before expensive analysis. Keep this issue open until the producer saves a usable cache and representative PR cache-hit durations are recorded against the baseline.

  4. iamlinjunhong commented on Nov 8, 2026

    @iamlinjunhong
    Contributor

    Recurrence: PR 32366 cold ARM64 SCA exceeds the job budget

    Source PR: #32366
    Exact PR head: c502f42b6d99d3cc0336009fac46dedd413f7bd9
    PR base / merge base: 89ca3dbbf6d594d7614b8e1ca80f6b0300ed3cd2 (main).
    Workflow: https://github.com/matrixorigin/matrixone/actions/runs/42479527946 (attempt 1, pull_request_target).

    Both complete job logs were inspected. The stable terminal signature is the check-run annotation The job has exceeded the maximum execution time of 1h30m0s; the SCA log terminates with The operation was canceled. The required-check script then reports Error: matrixone-ci: cancelled. This is a job-budget cancellation, without a completed golangci-lint verdict.

    Direct runner/cache/provisioning evidence (UTC):

    1. At 12:19:29–12:19:35, the Go module, golangci analysis, native, ONNX fallback, and static-tool restores all reported Cache not found for input keys. The analysis cache had no matched key and was initialized empty.
    2. Native preparation succeeded. Prepare static-check tools then took 12:23:59–12:53:39 (29m40s). After the prebuilt lint binary download, the log records go: downloading github.com/apache/skywalking-eyes v0.4.0 at 12:25:50 and its dependency downloads beginning at 12:53:17. This long interval is in installation of pinned external tools, before MatrixOne SCA begins; the log does not establish which individual proxy/download/compile substep consumed that interval.
    3. The external workflow detected a license recipe/config hash mismatch and conservatively ran complete license checks. Headers completed at 13:09:26 with invalid: 0. SCA selected the full graph because the added .jl regression fixture is outside its incremental allowlist. molint check -mod=readonly ./... ran 13:11:34–13:26:20 and returned successfully.
    4. Final command: CGO_CFLAGS="-I/home/runner/_work/matrixone/matrixone/cgo -I/home/runner/_work/matrixone/matrixone/thirdparties/install/include " golangci-lint run -v --concurrency 1 -c .golangci.yml ./..., launched by GOMEMLIMIT=5GiB make static-check-analysis GOLANGCI_LINT_CONCURRENCY=1. Package loading took 4m59s. GitHub cancelled it at 13:48:03 when the overall 90-minute job budget expired; no analyzer finding, compile/type error, assertion, panic, or race failure was emitted before cancellation. This does not assert the unfinished lint phase passed.

    Attribution: the observed failure is exhaustion of the cold SCA runner's end-to-end capacity budget, the mechanism tracked here. The unusually long pinned-tool installation and every missing cache are direct infrastructure evidence independent of the JSONLINE runtime change. git diff 89ca3dbbf6d594d7614b8e1ca80f6b0300ed3cd2...c502f42b6d99d3cc0336009fac46dedd413f7bd9 -- .github Makefile go.mod go.sum is empty; the base/head install-static-check-tools recipes are identical, including all pinned tool versions. The PR only changes the JSONLINE reader/parser and focused tests/LOAD fixtures, and does not change cache keys, runner settings, tool installation, analyzer rules, or timeouts. No product tests execute in this lane. No local main reproduction is claimed; the attribution uses the direct cache/provisioning and budget evidence, not this closed issue as an open-defect control. Same-head shared build, Ubuntu UT, UT coverage, PROXY/PESSIMISTIC BVT, and merged coverage succeeded as supplementary evidence.

    Reproduction protocol: run this SCA workflow on the 4-core/8-GiB ARM64 worker with all recorded restore keys missing and pinned tools installed cold; include the tool-installation delay in the same 90-minute job budget, then execute the complete license/molint/golangci pipeline. Preserve full analyzer coverage. No unrelated product changes or gate weakening are proposed.

    Searches covered open and closed issues for SCA timeouts, the maximum-execution-time signature, and golangci-lint timeouts. This existing cold SCA critical-path tracker is reused without reopening or changing labels. Planned recovery: request one failed-jobs rerun of run 42479527946 after recording this occurrence, and verify the new attempt is accepted.

  5. iamlinjunhong commented on Nov 29, 2026

    @iamlinjunhong
    Contributor

    Recurrence on 4.2-dev PR 33424

    PR #33424, head 1e91864079d43f1feb836b1c1a850f538865bdd9, tested against 57cd85573cd1d4e1297642010f06094cbfb92320. Run 46107411827 attempt 2.

    • SCA job 140865809086 ran on the standard Linux/arm64 4-core/8-GiB runner with Go 1.26.4. Its annotation reports The job has exceeded the maximum execution time of 1h30m0s. CI Required job 140886900575 then failed in verifyResults with Error: matrixone-ci: cancelled.
    • The Go module, golangci, native, ONNX fallback, and static-tool cache restores all missed. The pinned SkyWalking Eyes install logged its module download at 05:00:13 UTC and its next dependency download at 05:44:39 UTC, before MatrixOne static analysis began. The external-tool installation interval was independent of the Proxy code. The final command was golangci-lint run -v --concurrency 1 -c .golangci.yml <23 selected packages>. It entered analyzer execution at 06:02:26 and was cancelled at 06:06:03 UTC without a terminal lint verdict.
    • The exact PR diff changes five Proxy source and test files. The base/head diff over .github, Makefile, go.mod, go.sum, cgo, and thirdparties is empty. The same head passed shared build, Ubuntu UT, and Proxy Compose BVT. These facts identify the cold runner and its wall-clock budget as the cause of the cancellation. No Linux baseline run is claimed.

    To reproduce, start the pinned SCA workflow on a cold 4-core/8-GiB Linux/arm64 runner with the five restores missing, then run its normal native setup, tool installation, and golangci-lint package analysis under the 90-minute job budget. Attempt 2 already retried this run after an installation API rate limit in attempt 1. The review fixes will trigger a new run on their own head.

  6. iamlinjunhong commented on Nov 30, 2026

    @iamlinjunhong
    Contributor

    ARM64 SCA job-budget recurrence on PR 33424

    PR #33424, exact head 3e4969685b90e488b721c58c84d5ce667c1bf5bf, target 4.2-dev and PR base 70bb7b35155ac33f9a0f6ed4ec5f4a00bbd7b4f3. Run 46373445675 attempt 1, ARM64 SCA job 141696519581, CI Required job 141740753249. The SCA job ran on the 4-core/8-GiB Linux/arm64 runner with Go 1.26.4 and reusable CI revision d1dd33c68b25d1c57f0b4d154de98a6f9dbc711d.

    • GitHub's job annotation reports The job has exceeded the maximum execution time of 1h30m0s. The SCA log ends with The operation was canceled. while go vet -mod=readonly -vettool=molint is running on 21 selected packages. The required check's verifyResults reports Error: matrixone-ci: cancelled.
    • Five cache restores missed (Go modules, golangci analysis, native prerequisites, ONNX fallback, and static tools). Before source analysis, Prepare static-check tools took about 72m23s. At 07:34:18 UTC the log records downloading github.com/apache/skywalking-eyes v0.4.0. At 08:41:32 the tool install failed while verifying github.com/golang/groupcache because the runner's Go checksum proxy returned 500 Internal Server Error for sumdb/sum.golang.org/tile/8/0/161. The retry completed preparation at 08:43:00. Full license headers returned zero invalid, and the job reached molint at 08:48:23 before the outer cutoff at 08:57:31. The logs contain no completed analyzer finding.
    • The PR changes six Proxy files. The verified diff against the PR base has no change to workflows, tool recipes, module files, lint/license config, or native inputs. The current official 4.2-dev tip 47e43f24a51ca72f6ecc8bf7a3655fce418b3bb8 also leaves those files unchanged. The pinned tool install is independent of the Proxy files. The same exact-head run passed Ubuntu/x86 UT and Proxy Compose BVT. The earlier recurrence on this issue is a tracking reference. This occurrence is attributed from the direct runner annotation and the proxy failure in the current logs.

    To reproduce the failure conditions, run the standard ARM64 SCA job with cold caches and its normal tool-install and source-analysis commands under the 90-minute job limit. The checksum proxy error is transient. One failed-jobs rerun is planned for this exact run.

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

Metadata

Metadata

Assignees

Labels

performanceseverity/s0

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions