From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: HTTP with Simple Components: Status.Kind always File
Date: Fri, 21 Jul 2017 09:14:18 +0200
Date: 2017-07-21T09:14:18+02:00 [thread overview]
Message-ID: <oks9ka$hao$2@gioia.aioe.org> (raw)
In-Reply-To: 2017072023125178180-contact@flyx.org
On 20/07/2017 23:12, Felix Krause wrote:
> On 2017-07-20 20:57:35 +0000, Dmitry A. Kazakov said:
>
>> On 2017-07-20 22:29, Simon Wright wrote:
>>>
>>> The RFC that Dmitri quotes is for URIs. You want the one that defines
>>> the HTTP protocol, currently RFC7230 - see section 3, Message Format.
>>> https://tools.ietf.org/html/rfc7230#section-3
>
> Ah, I looked at an older RFC for HTTP 1.1; I wasn't aware there was a newer
> one. This newer one indeed defines query as part of the request target:
>
> https://tools.ietf.org/html/rfc7230#section-5.3
>
> request-target = origin-form
> / absolute-form
> / authority-form
> / asterisk-form
> origin-form = absolute-path [ "?" query ]
>>
>> So, is it OK to always recognize query part in the path. Correct?
>
> Yes, although to avoid confusion, it may be a good idea to not name
> it „Path“. Reading the spec, „Origin“ might be more appropriate. But
> I guess that change would break backwards compatibility.
I think I will just move the Query member out of the variant choice like
this:
type Status_Line
( Kind : Status_Line_Type;
Path_Length : Natural;
Host_Length : Natural;
Query_Length : Natural
) is
record
Query : String (1..Query_Length);
case Kind is
when None =>
null;
when File =>
File : String (1..Path_Length);
when URI =>
Scheme : Scheme_Type;
Host : String (1..Host_Length);
Port : Port_Type;
Path : String (1..Path_Length);
end case;
end record;
That should keep it backward compatible.
--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
next prev parent reply other threads:[~2017-07-21 7:14 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-17 18:30 HTTP with Simple Components: Status.Kind always File Felix Krause
2017-07-17 20:59 ` Dmitry A. Kazakov
2017-07-19 16:09 ` Felix Krause
2017-07-19 16:33 ` Dmitry A. Kazakov
2017-07-19 19:31 ` Randy Brukardt
2017-07-19 21:13 ` Felix Krause
2017-07-20 8:57 ` Dmitry A. Kazakov
2017-07-20 13:35 ` Felix Krause
2017-07-20 13:57 ` Dmitry A. Kazakov
2017-07-20 14:19 ` Felix Krause
2017-07-20 20:29 ` Simon Wright
2017-07-20 20:57 ` Dmitry A. Kazakov
2017-07-20 21:12 ` Felix Krause
2017-07-21 7:14 ` Dmitry A. Kazakov [this message]
2017-07-21 7:06 ` Simon Wright
2017-07-21 7:15 ` Dmitry A. Kazakov
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox