Maybe this behaviour is expected, but at least to me it was a massive time-killer yesterday. Here is what happened:
write 2 POST endpoints, both identical except of two lines
the first one uses:
log.info("QueryParams: " + request.queryParams().toString());
log.info("Request: " + request.body());
the second one uses the same but calls the body() method first:
log.info("Request: " + request.body());
log.info("QueryParams: " + request.queryParams().toString());
Outcome is that in the 2nd endpoint request.body() will show the correct body but no query params and in the 1st one request.body() will be empty but queryParams correct.
Maybe this behaviour is expected, but at least to me it was a massive time-killer yesterday. Here is what happened:
Outcome is that in the 2nd endpoint request.body() will show the correct body but no query params and in the 1st one request.body() will be empty but queryParams correct.