Skip to content

Commit

Permalink
[Synthtrace] Fix synthtrace to work with 7.x clusters (elastic#209447)
Browse files Browse the repository at this point in the history
## Summary

While working on 9.x Upgrade testing, i found that when running
synthtrace scenarios pointing to a 7.x cluster, it tries to fetch the
latest version of the APM package. In 7.x, the `latestVersion` item was
present under a different node in the API response. Hence adding this
fix.
  • Loading branch information
achyutjhunjhunwala authored Feb 4, 2025
1 parent 433fd8c commit 0323373
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,11 @@ export class ApmSynthtraceKibanaClient {
);
}

// Add support for 7.x stack as latest version is available under different node
if (responseJson.response && responseJson.response.latestVersion) {
return responseJson.response.latestVersion as string;
}

return responseJson.item.latestVersion as string;
};

Expand Down

0 comments on commit 0323373

Please sign in to comment.