-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[DLS-10533] migrating from http client to http client v2 #287
base: main
Are you sure you want to change the base?
[DLS-10533] migrating from http client to http client v2 #287
Conversation
f8ca6bf
to
4c4ae8e
Compare
test/uk/gov/hmrc/helptosave/modules/UCThresholdOrchestratorSpec.scala
Outdated
Show resolved
Hide resolved
Also, now that they are resolved, can we remove the test failure descriptions from the PR comment. Thanks |
Removed them |
ec: ExecutionContext): Future[HttpResponse] = | ||
http.post(barsEndpoint, bodyJson(request), headers.+("X-Tracking-Id" -> trackingId.toString)) | ||
ec: ExecutionContext): Future[HttpResponse] = { | ||
http.post(barsEndpoint).withBody(bodyJson(request)).transform(_.addHttpHeaders(headers, "X-Tracking-Id" -> trackingId.toString)).execute[HttpResponse] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, missed this in previous review.
Would it also make sense to capture the return type as Either[UpstreamErrorResponse, HttpResponse]
here? This might need tests being tidied up to reflect the change
While doing that, could you also check on other connectors making sure of the return type and error handling in calling code.
No description provided.