Time |
S |
Nick |
Message |
03:21 |
|
|
tbsf joined #rest |
07:20 |
|
|
Haudegen joined #rest |
08:24 |
|
|
Haudegen joined #rest |
09:27 |
|
|
interop_madness joined #rest |
09:27 |
|
|
interop_madness joined #rest |
09:59 |
|
|
vanHoesel joined #rest |
13:03 |
|
|
Haudegen joined #rest |
14:05 |
|
|
ResidentBiscuit joined #rest |
14:28 |
|
|
tbsf joined #rest |
14:32 |
|
|
mzarella joined #rest |
14:33 |
|
mzarella |
i have a situation where i want to pass in an arbitrary sized list of resource identifiers to my backend service, and i would like it to send back a list of resources from those ids |
14:34 |
|
mzarella |
i have considered using a GET request appending each item in in a query param, but is this appropriate? |
14:34 |
|
mzarella |
what is the maximum length of query params you can have? |
14:34 |
|
mzarella |
or what is the maximum string size a query param? |
14:35 |
|
mzarella |
i'm not creating resource, i'm simple requesting a lot of them |
14:35 |
|
mzarella |
i'm not creating resources, i'm simple requesting a lot of them |
14:35 |
|
mzarella |
simply |
14:36 |
|
mzarella |
i would put the list of resource identifiers in the body, but a stackoverflow post mentioned this shoudn't be done |
14:36 |
|
mzarella |
https://stackoverflow.com/questions/978061/http-get-with-request-body |
14:36 |
|
mzarella |
RFC 2616 (Hypertext Transfer Protocol — HTTP/1.1) states there is no limit to the length of a query string (section 3.2.1). |
14:37 |
|
mzarella |
so is the query param the best way to do this? |
14:56 |
|
mdk |
mzarella: there IS a limit in length in the implementations of HTTP servers |
14:56 |
|
mdk |
mzarella: but giving "?thing_ids=1,2,3,4,5,6" looks legit to me |
14:57 |
|
mzarella |
i'll go with this until there's a problem |
14:58 |
|
mzarella |
probably better to use websockets at some point |
14:58 |
|
mzarella |
thanks for responding mdk |
14:58 |
|
mdk |
mzarella: you may also enforce a known and documented limit like 100 items, forcing the clients to "paginate" |
15:00 |
|
mdk |
If your ids are integers you may introduce ranges like ?thing_ids=1..1000 but I don't like it (still don't know why) |
15:15 |
|
|
zarella joined #rest |
15:59 |
|
|
tbsf joined #rest |
16:00 |
|
|
tbsf joined #rest |
16:00 |
|
|
tbsf joined #rest |
16:01 |
|
|
tbsf_ joined #rest |
16:49 |
|
|
Haudegen joined #rest |
17:03 |
|
|
tbsf joined #rest |
17:19 |
|
|
interop_madness joined #rest |
20:19 |
|
|
Guest5920 joined #rest |
22:12 |
|
|
tbsf joined #rest |
22:25 |
|
|
tbsf joined #rest |