Re: Migrating a spec to structured fields

Am 09.03.2021 um 17:53 schrieb Roberto Polli:
> Hi folks,
>
> I wanted to migrate the RateLimit headers with roughly the following abnf to S-F
>
> ```
> RateLimit-Limit = expiring-limit [, 1#quota-policy ]
> expiring-limit = request-quota
> quota-policy = request-quota; "w" "=" time-window *( OWS ";" OWS quota-comment)
> quota-comment = token "=" (token / quoted-string)
> request-quota = quota-units
> quota-units = 1*DIGIT
> time-window = delay-seconds (from Section 10.2.4 of [SEMANTICS])
> ```
>
> I stubbed a commentable doc here
> https://docs.google.com/document/d/1e9Vxcmb6hrle8LNKMtQc_eB-p7jdEPrBE1lgzrAqYKo/edit
> for all the willing people that are happy to provide hints.
> This could become a useful migration guide/reference to foster S-F adoption.
>
> Thanks for your help,
> R.

IIUC, the proposal is to use ABNF to specify constraints:

   delay-seconds = sf-integer ; non-negative Integer without parameters

and then to use "delay-seconds" instead of "sf-integer".

I'm not convinced this is a good idea, because if you use structured
fields, there are more things to worry about (extension parameters etc),
so at the end of the say you will have to use prose to specify
additional behaviours anyway. It probably is better to have all of that
in a single place.

Best regards, Julian

Received on Wednesday, 10 March 2021 08:15:39 UTC