mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jan Schlicht <...@mesosphere.io>
Subject Re: Review Request 42794: URL query string order is defined.
Date Tue, 26 Jan 2016 15:42:46 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/42794/#review116362
-----------------------------------------------------------




3rdparty/libprocess/src/http.cpp (line 787)
<https://reviews.apache.org/r/42794/#comment177405>

    Renaming this to `sortedQuery` better reflects the property of this map.



3rdparty/libprocess/src/http.cpp (line 788)
<https://reviews.apache.org/r/42794/#comment177406>

    The size of `query` is know here, please reserve it for `_query`:
    
    ```cpp
    _query.reserve(query.size());
    ```



3rdparty/libprocess/src/http.cpp (lines 789 - 791)
<https://reviews.apache.org/r/42794/#comment177404>

    Please add a comment above this statement to explain what's happening here. I.e. "Adding
`query` to a map will sort them alphabetically by their fields".



3rdparty/libprocess/src/http.cpp (line 790)
<https://reviews.apache.org/r/42794/#comment177407>

    Why not use `map::emplace` here, to avoid unnecessary copies?


- Jan Schlicht


On Jan. 26, 2016, 11:55 a.m., Abhishek Dasgupta wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/42794/
> -----------------------------------------------------------
> 
> (Updated Jan. 26, 2016, 11:55 a.m.)
> 
> 
> Review request for mesos, Jan Schlicht and Vinod Kone.
> 
> 
> Bugs: MESOS-3317
>     https://issues.apache.org/jira/browse/MESOS-3317
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> URL query string order is defined.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/src/http.cpp 762da9a9038fc0a81156b5c03b556084df1bd7e0 
>   3rdparty/libprocess/src/tests/http_tests.cpp 66d185e3fd8a165d8a98d3d2752e756f8de3499b

> 
> Diff: https://reviews.apache.org/r/42794/diff/
> 
> 
> Testing
> -------
> 
> The following test cases in http_test.cpp have been modified -
> HTTPTest.QueryEncodeDecode to check generated query strings in URL to be according alphabatic
order.
> URLTest.Stringification to check generated query strings in URL to be according alphabatic
order.
> 
> 
> Thanks,
> 
> Abhishek Dasgupta
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message