dapr / dapr/java-sdk

Add HTTP Client Factory into Java SDK

Open
#1,319 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
300
Forks
230
Avg merge
1d 20h
Merged PRs (30d)
4

Description

As we do in Dotnet today, it would be nice to give users the option to create an HTTP Client via the Java SDK through a factory. This would remove the current encapsulation around the existing invokeMethod and allow users additional options for HTTP Client without having to have all the method overloads.

For example in Dotnet:

```
var httpClient = DaprClient.CreateInvokeHttpClient();
var response = await httpClient.PostAsJsonAsync("http://order-processor/orders", order);
```

In the past we simplified this and now there is only HTTP for methodInvoke() and waitForSidecar(), but would be nice to standardize the SDKs: https://github.com/dapr/java-sdk/pull/1051

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.