Don't forward skip or only to aggregator
These two parameters are not idempotent, and are currently being run
first on the satellite, then again on the aggregator. This results in
errors and unexpected results.
This commit detects when we're parsing a top collection, and filters out
those two parameters from being applied to the satellite request.
To accomplish rewriting the URI, a new Request API needs added for
non-const access to the URI object.
Tested: Aggregator shows results as expected. Query params are not
forwarded to satellite
Change-Id: I99cbbb08da9fcd06c9ee10d371b253e32d01f59b
Signed-off-by: Ed Tanous <etanous@nvidia.com>
diff --git a/http/http_request.hpp b/http/http_request.hpp
index 7cf2842..74681cc 100644
--- a/http/http_request.hpp
+++ b/http/http_request.hpp
@@ -111,6 +111,11 @@
return req.target();
}
+ boost::urls::url& url()
+ {
+ return urlBase;
+ }
+
boost::urls::url_view url() const
{
return {urlBase};