feature: please add DgsQueryExecutor.executeAndExtractJsonPath method overload that allows overriding WebRequest
Please read our contributor guide before creating an issue. Also consider discussing your idea on the discussion forum first.
Describe the Feature Request
Please add DgsQueryExecutor.executeAndExtractJsonPath method overload that allows overriding WebRequest (similarly to DgsQueryExecutor.execute()).
The reason why overload with headers:
<T> T executeAndExtractJsonPath(String query, String jsonPath, HttpHeaders headers);
doesn't work is that we additionally need to set Cookies.
Currently, DgsQueryExecutor.executeAndExtractJsonPath() sets webRequest to null without a possibility to override it. As an alternative, we are using DgsQueryExecutor.execute() so it's nice-to-have feature request, not a blocker.
Describe Preferred Solution
Add and implement
<T> T executeAndExtractJsonPath(String query, String jsonPath, WebRequest webRequest);
Describe Alternatives
Thanks for reporting!
Feature is already implemented : executeAndExtractJsonPath(query: String, jsonPath: String, servletWebRequest: ServletWebRequest)