api: search: deprecate is_automated field, and is-automated filter#45925
api: search: deprecate is_automated field, and is-automated filter#45925thaJeztah merged 1 commit intomoby:masterfrom
Conversation
corhere
left a comment
There was a problem hiding this comment.
"An external service will no longer be setting this field to true" is not a valid excuse to make unversioned schema-breaking changes to API responses.
ee24950 to
a641a0d
Compare
| } | ||
| } | ||
|
|
||
| // TODO(thaJeztah): reset the "is-automated" filter on API v1.45 and up (once released). |
There was a problem hiding this comment.
Let me update this comment, as we can't realistically version this change, so we should just ignore the filter, and reset the field
There was a problem hiding this comment.
Couldn't we version this change by e.g. making it an invalid request to search using an is-automated filter condition on API v1.45+?
so we should just ignore the filter, and reset the field
We can ignore is-automated=false as that will match all images, but we can't just ignore is-automated=true. It would be more surprising for a client searching with an is-automated=true filter to get results where "is_automated": false than to get no results at all.
a641a0d to
96b2e6f
Compare
96b2e6f to
31281f2
Compare
|
@corhere updated; removed the part about "no longer be returned" in future; PTAL |
31281f2 to
ba1e1a1
Compare
| in the next release. Given that this field is deprecated by an external API, | ||
| the deprecation will not be versioned, and will apply to any API version. |
02d6d11 to
99a814a
Compare
|
@corhere I updated the descriptions with (I think) we came to during the maintainers call
Let me know if that looks good to you. |
corhere
left a comment
There was a problem hiding this comment.
I don't see any mention of the deprecation in https://docs.docker.com/docker-hub/release-notes/
I'm still not entirely happy with the version history entries, but my remaining nitpicks aren't serious enough to continue blocking this PR.
The is-automated field is being deprecated by Docker Hub's search API, and will always be set to "false" in future. This patch deprecates the field and related filter for the Engine's API. In future, the `is-automated` filter will no longer yield any results when searching for `is-automated=true`, and will be ignored when searching for `is-automated=false`. Given that this field is deprecated by an external API, the deprecation will not be versioned, and will apply to any API version. Signed-off-by: Sebastiaan van Stijn <[email protected]>
99a814a to
971083d
Compare
| * Deprecated: The `is_automated` field in the `GET /images/search` response has | ||
| been deprecated and will always be set to false in the future because Docker | ||
| Hub is deprecating the `is_automated` field in its search API. The deprecation | ||
| is_ not versioned, and applies to all API versions. |
There was a problem hiding this comment.
A rogue underscore snuck in. Hope it doesn't mess up the markdown rendering too much
There was a problem hiding this comment.

api: search: deprecate is_automated field, and is-automated filter
The is-automated field is being deprecated by Docker Hub's search API, and will always be set to "false" in future.
This patch deprecates the field and related filter for the Engine's API. In future, the
is-automatedfilter will not yield any results when searching foris-automated=true, and will be ignored when searching foris-automated=false.Given that this field is deprecated by an external API, the deprecation will not be versioned, and will apply to any API version.
- What I did
- How I did it
- How to verify it
- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)