File tree Expand file tree Collapse file tree 4 files changed +5
-6
lines changed
api/src/main/java/io/grpc
core/src/main/java/io/grpc/internal Expand file tree Collapse file tree 4 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -38,11 +38,10 @@ private InternalStatus() {}
3838 public static final Metadata .Key <Status > CODE_KEY = Status .CODE_KEY ;
3939
4040 /**
41- * Create a new {@link StatusRuntimeException} with the internal option of skipping the filling
42- * of the stack trace.
41+ * Create a new {@link StatusRuntimeException} skipping the filling of the stack trace.
4342 */
4443 @ Internal
45- public static StatusRuntimeException asRuntimeException (Status status ,
44+ public static StatusRuntimeException asRuntimeExceptionWithoutStacktrace (Status status ,
4645 @ Nullable Metadata trailers ) {
4746 return new InternalStatusRuntimeException (status , trailers );
4847 }
Original file line number Diff line number Diff line change 2626 * @see StatusRuntimeException
2727 */
2828class InternalStatusRuntimeException extends StatusRuntimeException {
29- private static final long serialVersionUID = 5225396310618305864L ;
29+ private static final long serialVersionUID = 0 ;
3030
3131 public InternalStatusRuntimeException (Status status , @ Nullable Metadata trailers ) {
3232 super (status , trailers );
Original file line number Diff line number Diff line change @@ -375,7 +375,7 @@ private void closedInternal(Status status) {
375375 listener .onCancel ();
376376 // The status will not have a cause in all failure scenarios, but we want to make sure
377377 // we always cancel the context with one to keep the context cancelled state consistent.
378- cancelCause = InternalStatus .asRuntimeException (
378+ cancelCause = InternalStatus .asRuntimeExceptionWithoutStacktrace (
379379 Status .CANCELLED .withDescription ("RPC cancelled" ), null );
380380 }
381381 } finally {
Original file line number Diff line number Diff line change @@ -887,7 +887,7 @@ private void closedInternal(final Status status) {
887887 // failed status has an exception we will create one here if needed.
888888 Throwable cancelCause = status .getCause ();
889889 if (cancelCause == null ) {
890- cancelCause = InternalStatus .asRuntimeException (
890+ cancelCause = InternalStatus .asRuntimeExceptionWithoutStacktrace (
891891 Status .CANCELLED .withDescription ("RPC cancelled" ), null );
892892 }
893893
You can’t perform that action at this time.
0 commit comments