Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Nov 12, 2025

Implements Milestone 1 from docs/release/remove-v1-checklist.md: flip build and docker targets to produce v2 artifacts by default while preserving explicit v1 override capability.

Changes

  • BuildBinaries.mk: Added JAEGER_VERSION variable (defaults to 2). Four exception targets remain v1: build-all-in-one, build-query, build-collector, build-ingester. All other targets now use BUILD_INFO_V$(JAEGER_VERSION).

  • BuildInfo.mk: Added missing BUILD_INFO_V1 definition (was causing v1 builds to lack version info).

  • build-upload-a-docker-image.sh: Defaults JAEGER_VERSION=2, passes to compute-tags.sh.

  • compute-tags.sh: Accepts JAEGER_VERSION variable (defaults to 2).

  • test-v2-defaults.sh: Test script verifying defaults and override mechanism (15/15 tests pass).

Usage

# Default: v2 for most targets
make build-jaeger        # → v2.11.0
make build-tracegen      # → v2.11.0

# Exceptions: v1 by default
make build-collector     # → v1.74.0
make build-all-in-one    # → v1.74.0

# Override mechanism
JAEGER_VERSION=1 make build-jaeger     # → v1.74.0
JAEGER_VERSION=2 make build-collector  # → v2.11.0

v1 publish/push code paths remain intact (Milestone 3 will remove them).

Original prompt

Create a branch chore/reassign-to-v2-defaults and open a PR that implements Milestone 1 from docs/release/remove-v1-checklist.md: re-number build and docker targets so v2 is the default for most developer/CI convenience flows while preserving the ability to explicitly request v1 artifacts.

Scope (minimal, non-publishing changes):

  • Flip default version variables and tag computation so v2 is implied by default across Makefiles and helper scripts used by maintainers and CI.
  • Preserve explicit override to v1 via environment variable or Makefile variable (e.g., JAEGER_VERSION=1).
  • Do not remove v1 publish/push code paths (Milestone 3 covers that).
  • Keep four exception targets defaulting to v1: build-all-in-one, build-query, build-collector, build-ingester.

Files to change (start here; scan repo for similar patterns and update as needed):

  • scripts/makefiles/BuildBinaries.mk

    • Set JAEGER_VERSION default to 2 unless one of the four exception targets is requested or the caller explicitly sets JAEGER_VERSION.
    • Ensure build rules reference $(JAEGER_VERSION) so behavior follows the variable.
    • Add a short header comment explaining the default flip and how to override to v1.
  • scripts/build/build-upload-a-docker-image.sh

    • Default to JAEGER_VERSION=2 unless overridden by env var or --version flag.
    • Use scripts/utils/compute-tags.sh to compute tags (which will produce v2-first ordering).
    • Keep v1 push logic present but only exercised when JAEGER_VERSION=1 (explicit request).
    • Add header comment describing change and override method.
  • scripts/utils/compute-tags.sh

    • Default tag computation to v2-first ordering when no explicit version is provided.
    • When VERSION=2 (or unspecified), output v2 tags first. Only include v1 tags if explicitly requested via env var/flag (e.g., INCLUDE_LEGACY_V1=1) or VERSION=1.
    • Maintain backward-compatible output format for callers.
  • Scan and update other convenience Makefiles or build helper scripts that currently default to v1 (examples to check: docker-compose/* Makefiles, scripts/build/* other scripts). Flip defaults where they affect maintainer/CI convenience flows.

Branch and PR metadata:

  • Branch: chore/reassign-to-v2-defaults
  • PR title: chore(release): reassign build and docker targets to use v2 by default
  • Base branch: main
  • Requested reviewers: @yurishkuro and @jaegertracing/ci (or equivalent maintainers)

PR description (to include in PR body):

  • Short summary of change and rationale (reference docs/release/remove-v1-checklist.md Milestone 1).
  • List of changed files with brief explanation of each change.
  • Acceptance criteria (as in checklist): default production of v2 artifacts for most targets, four exceptions remain v1, explicit override works.
  • Test plan with commands and verification steps:
    1. Checkout branch and run representative make targets and confirm produced artifact tags are v2 by default.
    2. Verify override: JAEGER_VERSION=1 make produces v1 artifacts.
    3. Dry-run Docker builder: scripts/build/build-upload-a-docker-image.sh --dry-run and confirm v2 tags are computed first.
    4. Run scripts/utils/compute-tags.sh with representative inputs to confirm v2-first ordering.
    5. Request a staging CI run to ensure CI convenience targets no longer use v1 by default.

Implementation notes:

  • Keep changes minimal, clearly commented and reversible.
  • Do not modify release/publish workflows that must remain capable of producing v1 until Milestone 3.
  • If additional files are updated beyond the three primary ones, include them in the PR and list them in the PR description.

Please create commits that make the minimal edits necessary and open the PR so reviewers can run CI and perform validation. Include the test plan and acceptance criteria in the PR body.

This pull request was created as a result of the following prompt from Copilot chat.

Create a branch chore/reassign-to-v2-defaults and open a PR that implements Milestone 1 from docs/release/remove-v1-checklist.md: re-number build and docker targets so v2 is the default for most developer/CI convenience flows while preserving the ability to explicitly request v1 artifacts.

Scope (minimal, non-publishing changes):

  • Flip default version variables and tag computation so v2 is implied by default across Makefiles and helper scripts used by maintainers and CI.
  • Preserve explicit override to v1 via environment variable or Makefile variable (e.g., JAEGER_VERSION=1).
  • Do not remove v1 publish/push code paths (Milestone 3 covers that).
  • Keep four exception targets defaulting to v1: build-all-in-one, build-query, build-collector, build-ingester.

Files to change (start here; scan repo for similar patterns and update as needed):

  • scripts/makefiles/BuildBinaries.mk

    • Set JAEGER_VERSION default to 2 unless one of the four exception targets is requested or the caller explicitly sets JAEGER_VERSION.
    • Ensure build rules reference $(JAEGER_VERSION) so behavior follows the variable.
    • Add a short header comment explaining the default flip and how to override to v1.
  • scripts/build/build-upload-a-docker-image.sh

    • Default to JAEGER_VERSION=2 unless overridden by env var or --version flag.
    • Use scripts/utils/compute-tags.sh to compute tags (which will produce v2-first ordering).
    • Keep v1 push logic present but only exercised when JAEGER_VERSION=1 (explicit request).
    • Add header comment describing change and override method.
  • scripts/utils/compute-tags.sh

    • Default tag computation to v2-first ordering when no explicit version is provided.
    • When VERSION=2 (or unspecified), output v2 tags first. Only include v1 tags if explicitly requested via env var/flag (e.g., INCLUDE_LEGACY_V1=1) or VERSION=1.
    • Maintain backward-compatible output format for callers.
  • Scan and update other convenience Makefiles or build helper scripts that currently default to v1 (examples to check: docker-compose/* Makefiles, scripts/build/* other scripts). Flip defaults where they affect maintainer/CI convenience flows.

Branch and PR metadata:

  • Branch: chore/reassign-to-v2-defaults
  • PR title: chore(release): reassign build and docker targets to use v2 by default
  • Base branch: main
  • Requested reviewers: @yurishkuro and @jaegertracing/ci (or equivalent maintainers)

PR description (to include in PR body):

  • Short summary of change and rationale (reference docs/release/remove-v1-checklist.md Milestone 1).
  • List of changed files with brief explanation of each change.
  • Acceptance criteria (as in checklist): default production of v2 artifacts for most targets, four exceptions remain v1, explicit override works.
  • Test plan with commands and verification steps:
    1. Checkout branch and run representative make targets and confirm produced artifact tags are v2 by default.
    2. Verify override: JAEGER_VERSION=1 make produces v1 artifacts.
    3. Dry-run Docker builder: scripts/build/build-upload-a-docker-image.sh --dry-run and confirm v2 tags are computed first.
    4. Run scripts/utils/compute-tags.sh with representative inputs to confirm v2-first ordering.
    5. Request a staging CI run to ensure CI convenience targets no longer use v1 by default.

Implementation notes:

  • Keep changes minimal, clearly commented and reversible.
  • Do not modify release/publish workflows that must remain capable of producing v1 until Milestone 3.
  • If additional files are updated beyond the three primary ones, include them in the PR and list them in the PR description.

Please create commits that make the minimal edits necessary and open the PR so reviewers can run CI and perform validation. Include the test plan and acceptance criteria in the PR body.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 3 commits November 12, 2025 19:37
- Update BuildBinaries.mk to default JAEGER_VERSION=2 for most targets
- Keep four exception targets as v1: build-all-in-one, build-query, build-collector, build-ingester
- Update build-upload-a-docker-image.sh to default JAEGER_VERSION=2
- Update compute-tags.sh with v2-first documentation
- Add header comments explaining override mechanism

Co-authored-by: yurishkuro <[email protected]>
The BUILD_INFO_V1 variable was not explicitly defined, causing v1
exception targets to build without version info. This fix ensures
both BUILD_INFO_V1 and BUILD_INFO_V2 are properly defined.

Co-authored-by: yurishkuro <[email protected]>
Created test-v2-defaults.sh to verify:
- v2 is default for non-exception targets
- v1 is default for four exception targets
- Override mechanism works correctly

All 15 tests pass successfully.

Co-authored-by: yurishkuro <[email protected]>
Copilot AI changed the title [WIP] Implement milestone 1 to reassign default version to v2 chore(release): reassign build targets to default to v2 (Milestone 1) Nov 12, 2025
Copilot AI requested a review from yurishkuro November 12, 2025 19:53
Copilot finished work on behalf of yurishkuro November 12, 2025 19:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants