Conversation
There was a problem hiding this comment.
Pull request overview
This PR migrates the Elasticsearch release data source from the legacy https://artifacts.elastic.co/releases/stack.json endpoint to the new https://ela.st/past-stack-releases endpoint across multiple language implementations (Python, .NET, Java, JavaScript) of the same Elasticsearch version lookup functionality.
Key changes:
- Updated the fetch URL in all four language implementations to use the new endpoint
- Updated the Python test cassette to reflect the new endpoint in the recorded HTTP interactions
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
genai-function-calling/vercel-ai/index.js |
Updated fetch URL in getLatestElasticsearchVersion function |
genai-function-calling/spring-ai/src/main/java/example/ElasticsearchTools.java |
Updated WebClient URI in getLatestElasticsearchVersion method; comment about old endpoint needs updating |
genai-function-calling/semantic-kernel-dotnet/Program.cs |
Updated HttpClient request URL in GetLatestVersion method |
genai-function-calling/openai-agents/main.py |
Updated HTTP GET request URL in get_latest_elasticsearch_version function |
genai-function-calling/openai-agents/cassettes/test_main.yaml |
Updated request URI and manifest field; manifest field contains incorrect value for one release entry |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "is_retired": false, | ||
| "retired_date": null, | ||
| "manifest": "https://artifacts.elastic.co/releases/stack.json" | ||
| "manifest": "https://ela.st/past-stack-releases" |
There was a problem hiding this comment.
The manifest field for this release entry is incorrectly set to https://ela.st/past-stack-releases. Based on the pattern used for all other release entries in this file, this should be https://artifacts.elastic.co/downloads/8.18.8.json (a version-specific download manifest, not the releases list endpoint). Note that there's also a duplicate entry for version "8.18.8" at lines 2425-2433 with the correct manifest value.
| ReleasesResponse response = WebClient.create().get().uri("https://artifacts.elastic.co/releases/stack.json") | ||
| ReleasesResponse response = WebClient.create().get().uri("https://ela.st/past-stack-releases") | ||
| .exchangeToMono(res -> res.mutate() | ||
| // Fix incorrect content-type from artifacts.elastic.co |
There was a problem hiding this comment.
The comment references the old endpoint artifacts.elastic.co but the code now uses https://ela.st/past-stack-releases. The comment should be updated to reflect the current endpoint being used.
| // Fix incorrect content-type from artifacts.elastic.co | |
| // Fix incorrect content-type from ela.st/past-stack-releases |
This pull request updates the source URL used to fetch Elasticsearch release data across multiple implementations in the codebase. The main change is switching from the legacy
https://artifacts.elastic.co/releases/stack.jsonendpoint to the newhttps://ela.st/past-stack-releasesendpoint, ensuring consistent and up-to-date data retrieval for Elasticsearch versions.Endpoint update for Elasticsearch release data:
main.py): Changed the fetch URL inget_latest_elasticsearch_versionto use the new endpoint.Program.cs): Updated the HTTP request inGetLatestVersionto use the new URL.ElasticsearchTools.java): Modified theWebClientrequest to point to the new endpoint.index.js): Updated the fetch call ingetLatestElasticsearchVersionto use the new URL.Test and cassette updates:
test_main.yaml): Updated both the request URI and the returned manifest field to reflect the new endpoint, ensuring test coverage matches the production change. [1] [2]