From bf88a46e2a58898b7c824791886677b6029adf07 Mon Sep 17 00:00:00 2001 From: Alex Szabo Date: Mon, 1 Jul 2024 16:50:06 +0200 Subject: [PATCH] adjust messaging --- .../trigger-version-dependent-jobs.yml | 2 ++ .../pipeline.ts | 34 ++++++++++++------- 2 files changed, 23 insertions(+), 13 deletions(-) diff --git a/.buildkite/pipeline-resource-definitions/trigger-version-dependent-jobs.yml b/.buildkite/pipeline-resource-definitions/trigger-version-dependent-jobs.yml index b31ca3be76a725c..6df9314fe440e2c 100644 --- a/.buildkite/pipeline-resource-definitions/trigger-version-dependent-jobs.yml +++ b/.buildkite/pipeline-resource-definitions/trigger-version-dependent-jobs.yml @@ -56,8 +56,10 @@ spec: message: Trigger artifact staging builds env: TRIGGER_PIPELINE_SET: artifacts-staging + MESSAGE: Daily staging build Trigger artifact snapshot builds: cronline: 0 7 * * * America/New_York message: Trigger artifact snapshot builds env: TRIGGER_PIPELINE_SET: artifacts-snapshot + MESSAGE: Daily snapshot build diff --git a/.buildkite/scripts/pipelines/trigger_version_dependent_jobs/pipeline.ts b/.buildkite/scripts/pipelines/trigger_version_dependent_jobs/pipeline.ts index af03091ca550d4a..c9ab59c6b7db1c7 100755 --- a/.buildkite/scripts/pipelines/trigger_version_dependent_jobs/pipeline.ts +++ b/.buildkite/scripts/pipelines/trigger_version_dependent_jobs/pipeline.ts @@ -56,23 +56,23 @@ async function main() { emitPipeline(pipelineSteps); } +/** + * This pipeline is testing the forward compatibility of Kibana with different versions of Elasticsearch. + * Should be triggered for combinations of (Kibana@7.17 + ES@8.x {current open branches on the same major}) + */ function getESForwardPipelineTriggers(): BuildkiteTriggerStep[] { const versions = getVersionsFile(); - const prevMajorBranch = versions.find((v) => v.previousMajor)?.branch; - const targetESVersions = versions - .filter((v) => { - return v.currentMajor && (v.currentMinor || v.previousMinor); - }) - .map((v) => v.version); + const kibanaPrevMajor = versions.find((v) => v.previousMajor)?.branch; + const targetESVersions = versions.filter((v) => v.currentMajor).map((v) => v.version); return targetESVersions.map((version) => { return { trigger: 'kibana-es-forward', async: true, - label: `ES ${version} forward compatibility`, + label: `Triggering Kibana ${kibanaPrevMajor} + ES ${version} forward compatibility`, build: { - message: `Triggering es-forward-compatibility test for ES ${version}`, - branch: prevMajorBranch, + message: process.env.MESSAGE || `ES forward-compatibility test for ES ${version}`, + branch: kibanaPrevMajor, commit: 'HEAD', env: { ES_SNAPSHOT_MANIFEST: `https://storage.googleapis.com/kibana-ci-es-snapshots-daily/${version}/manifest-latest-verified.json`, @@ -82,6 +82,10 @@ function getESForwardPipelineTriggers(): BuildkiteTriggerStep[] { }); } +/** + * This pipeline creates Kibana artifact snapshots for all open branches. + * Should be triggered for all open branches in the versions.json: 7.x, 8.x + */ function getArtifactSnapshotPipelineTriggers() { // Trigger for all named branches const versions = getVersionsFile(); @@ -91,9 +95,9 @@ function getArtifactSnapshotPipelineTriggers() { return { trigger: 'kibana-artifacts-snapshot', async: true, - label: `Snapshot artifacts for ${branch}`, + label: `Triggering snapshot artifact builds for ${branch}`, build: { - message: `Triggering artifact snapshot for ${branch}`, + message: process.env.MESSAGE || `Snapshot artifact build for ${branch}`, branch, commit: 'HEAD', }, @@ -101,6 +105,10 @@ function getArtifactSnapshotPipelineTriggers() { }); } +/** + * This pipeline creates Kibana artifacts for branches that are not the current main. + * Should be triggered for all open branches in the versions.json: 7.x, 8.x, but not main. + */ function getArtifactStagingPipelineTriggers() { // Trigger for all branches, that are not current minor+major const versions = getVersionsFile(); @@ -110,9 +118,9 @@ function getArtifactStagingPipelineTriggers() { return { trigger: 'kibana-artifacts-staging', async: true, - label: `Staging artifacts for ${branch}`, + label: `Triggering staging artifact builds for ${branch}`, build: { - message: `Triggering artifact staging for ${branch}`, + message: process.env.MESSAGE || `Staging artifact build for ${branch}`, branch, commit: 'HEAD', },