Skip to content

Commit

Permalink
pw_rpc: Remove the default abandon() implementation
Browse files Browse the repository at this point in the history
This reverts commit c294be0, which was
a temporary workaround.

Change-Id: I865a6c7d67bc8803ad3f0e8b5e4d73b38a5d46ee
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/97747
Pigweed-Auto-Submit: Wyatt Hepler <hepler@google.com>
Commit-Queue: Auto-Submit <auto-submit@pigweed.google.com.iam.gserviceaccount.com>
Reviewed-by: Alexei Frolov <frolv@google.com>
  • Loading branch information
255 authored and CQ Bot Account committed Jun 10, 2022
1 parent 88ee2e6 commit 2f9247f
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions pw_rpc/java/main/dev/pigweed/pw_rpc/Call.java
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,7 @@ public interface Call {
void cancel() throws ChannelOutputException;

/** Cancels the RPC as in cancel(), but does not send a cancellation packet to the server. */
default void abandon() {
// By default, call cancel() and ignore exceptions.
// TODO(b/235513314): Remove this default implementation once users have
// implemented abandon().
try {
cancel();
} catch (ChannelOutputException e) {
// Ignore the exception, since abandon() isn't supposed to send packets.
}
}
void abandon();

/** True if the RPC has not yet completed. */
default boolean active() {
Expand Down

0 comments on commit 2f9247f

Please sign in to comment.