top | item 45056142

RFC 8594: The Sunset HTTP Header Field (2019)

29 points| aiven | 6 months ago |datatracker.ietf.org

12 comments

order

fogzen|6 months ago

Poor choice of terminology. Why not “Deprecated-After” or something actually descriptive.

“Sunset” is marketing speak.

JdeBP|6 months ago

It is legal, rather than marketing, speak. "Sunset clause" has been widely-used legal jargon for a good half century at this point, possibly longer.

aiven|6 months ago

Why do libraries such as Requests or HTTPX not support this out of the box? It would be really useful to have automatic warning or sentry event after deprecation response.

I understand that this functionality can be easily added as a plugin, but not everyone is aware that such a thing even exists. With default support, it will be easier to upgrade to new API versions and keep stuff up to date.

tveita|6 months ago

How would it behave? The standard as written doesn't suggest any appropriate client behaviour.

It explicitly doesn't have to mean deprecation, the standard says it could also be returned from any short-lived resource. There's no way to see if the header applies to the whole server or just the specific resource or even query parameters, and no way to deduplicate to ignore known warnings.

treve|6 months ago

My REST client emits this to console.log out of the box, and it's been really useful https://github.com/badgateway/ketting

It's nice when tooling builds this sort of stuff in, because it also encourages APIs to implement it.

bayindirh|6 months ago

I'll argue that if these features are more widely known and respected, we wouldn't need to re-invent these kinds of elegant solutions with clunky and thick stacks, over and over again.

marcosdumay|6 months ago

Oh, this creates a header field called "Sunset". The title made me scared for a bit.