-
Notifications
You must be signed in to change notification settings - Fork 297
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
FailsafeCall micro refactoring, plus World-Wide Nr.1 duplicated utility method for OkHttp #351
Comments
OK
Aren't those braces ignored, anyway? It's just a single expression. (The indenting of the modified code is off, btw.)
Does this utility belong in |
IntelliJ IDEA's work :-) As I know, the resulting byte code is the same.
To be honest, not 100%... but I really want to drop such "one method utility class" in my codebase. 🙏 If you do some research in Internet, you will find that people reinvent this wheel over and over, write almost the same method over and over. As a small sign of gratitude, I won't then write an issue about a large PR to concurrentunit (Excellent library BTW) |
Your wish is my command. Tell me if I should send an PR. |
Not up to me. |
As you can see here:
magicprinc@c517e3e
FailsafeCall micro refactoring:
AtomicBoolean fields are final
lambda expression instead of code block
World-Wide Nr.1 duplicated utility method for OkHttp
`/** [OkHttp Callback to JDK CompletableFuture]
Helps eliminate dozens of utility classes World-wide with exactly this same method.
Can be the first small step towards FailSafe.
Returns normal JDK {@link CompletableFuture} without FailSafe policies.
*/
public static CompletableFuture asPromise (okhttp3.Call call)`
All around the World, people write this method again and again. I have done it too.
We really need "The Chosen One". I recommend you to be this one :-)
If you like it, I will send it as PR.
The text was updated successfully, but these errors were encountered: