You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Michael Park <mc...@gmail.com> on 2015/08/05 08:05:06 UTC
Re: Review Request 36987: Extended 'getFormValue' to 'getFormValues'
in order to parse input uniformly.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/36987/
-----------------------------------------------------------
(Updated Aug. 5, 2015, 6:05 a.m.)
Review request for mesos, Ben Mahler and Jie Yu.
Changes
-------
* Added a comment
* Removed the implicit empty string check
Summary (updated)
-----------------
Extended 'getFormValue' to 'getFormValues' in order to parse input uniformly.
Repository: mesos
Description (updated)
-------
`getFormValues` takes a `Request` object and a list of required keys, and tries to return a map of the required keys to their corresponding values.
This function helps to reduce the amount of code required to check the each required keys manually as well as to keep the missing parameter error message uniform across multiple endpoints.
This is a short-term solution which improves upon `getFormValue`, but in the future we should consider adding a libprocess level support for processing the required and optional keys from a `Request`.
Diffs (updated)
-----
src/master/http.cpp 76e70801925041f08bc94f0ca18c86f1a573b2b3
src/tests/repair_tests.cpp 4d513ed9e18ebf04a5e5aadb022b064479739e66
Diff: https://reviews.apache.org/r/36987/diff/
Testing
-------
`make check`
Thanks,
Michael Park
Re: Review Request 36987: Extended 'getFormValue' to 'getFormValues'
in order to parse input uniformly.
Posted by Michael Park <mc...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/36987/
-----------------------------------------------------------
(Updated Aug. 5, 2015, 10:38 a.m.)
Review request for mesos, Ben Mahler and Jie Yu.
Changes
-------
Removed temporary variables.
Bugs: MESOS-2600
https://issues.apache.org/jira/browse/MESOS-2600
Repository: mesos
Description
-------
`getFormValues` takes a `Request` object and a list of required keys, and tries to return a map of the required keys to their corresponding values.
This function helps to reduce the amount of code required to check the each required keys manually as well as to keep the missing parameter error message uniform across multiple endpoints.
This is a short-term solution which improves upon `getFormValue`, but in the future we should consider adding a libprocess level support for processing the required and optional keys from a `Request`.
Diffs (updated)
-----
src/master/http.cpp 76e70801925041f08bc94f0ca18c86f1a573b2b3
src/tests/repair_tests.cpp 4d513ed9e18ebf04a5e5aadb022b064479739e66
Diff: https://reviews.apache.org/r/36987/diff/
Testing
-------
`make check`
Thanks,
Michael Park
Re: Review Request 36987: Extended 'getFormValue' to 'getFormValues'
in order to parse input uniformly.
Posted by Michael Park <mc...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/36987/
-----------------------------------------------------------
(Updated Aug. 5, 2015, 10:04 a.m.)
Review request for mesos, Ben Mahler and Jie Yu.
Bugs: MESOS-2600
https://issues.apache.org/jira/browse/MESOS-2600
Repository: mesos
Description
-------
`getFormValues` takes a `Request` object and a list of required keys, and tries to return a map of the required keys to their corresponding values.
This function helps to reduce the amount of code required to check the each required keys manually as well as to keep the missing parameter error message uniform across multiple endpoints.
This is a short-term solution which improves upon `getFormValue`, but in the future we should consider adding a libprocess level support for processing the required and optional keys from a `Request`.
Diffs
-----
src/master/http.cpp 76e70801925041f08bc94f0ca18c86f1a573b2b3
src/tests/repair_tests.cpp 4d513ed9e18ebf04a5e5aadb022b064479739e66
Diff: https://reviews.apache.org/r/36987/diff/
Testing
-------
`make check`
Thanks,
Michael Park
Re: Review Request 36987: Extended 'getFormValue' to 'getFormValues'
in order to parse input uniformly.
Posted by Michael Park <mc...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/36987/
-----------------------------------------------------------
(Updated Aug. 5, 2015, 9:46 a.m.)
Review request for mesos, Ben Mahler and Jie Yu.
Repository: mesos
Description
-------
`getFormValues` takes a `Request` object and a list of required keys, and tries to return a map of the required keys to their corresponding values.
This function helps to reduce the amount of code required to check the each required keys manually as well as to keep the missing parameter error message uniform across multiple endpoints.
This is a short-term solution which improves upon `getFormValue`, but in the future we should consider adding a libprocess level support for processing the required and optional keys from a `Request`.
Diffs (updated)
-----
src/master/http.cpp 76e70801925041f08bc94f0ca18c86f1a573b2b3
src/tests/repair_tests.cpp 4d513ed9e18ebf04a5e5aadb022b064479739e66
Diff: https://reviews.apache.org/r/36987/diff/
Testing
-------
`make check`
Thanks,
Michael Park