< prev index next >
src/java.net.http/share/classes/jdk/internal/net/http/common/SubscriberWrapper.java
Print this page
*** 1,7 ****
/*
! * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
--- 1,7 ----
/*
! * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
*** 21,31 ****
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
! package jdk.incubator.http.internal.common;
import java.io.Closeable;
import java.lang.System.Logger.Level;
import java.nio.ByteBuffer;
import java.util.List;
--- 21,31 ----
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
! package jdk.internal.net.http.common;
import java.io.Closeable;
import java.lang.System.Logger.Level;
import java.nio.ByteBuffer;
import java.util.List;
*** 365,375 ****
logger.log(Level.DEBUG, () -> "onError: " + throwable);
errorCommon(Objects.requireNonNull(throwable));
}
protected boolean errorCommon(Throwable throwable) {
! assert throwable != null;
if (errorRef.compareAndSet(null, throwable)) {
logger.log(Level.DEBUG, "error", throwable);
pushScheduler.runOrSchedule();
upstreamCompleted = true;
cf.completeExceptionally(throwable);
--- 365,376 ----
logger.log(Level.DEBUG, () -> "onError: " + throwable);
errorCommon(Objects.requireNonNull(throwable));
}
protected boolean errorCommon(Throwable throwable) {
! assert throwable != null ||
! (throwable = new AssertionError("null throwable")) != null;
if (errorRef.compareAndSet(null, throwable)) {
logger.log(Level.DEBUG, "error", throwable);
pushScheduler.runOrSchedule();
upstreamCompleted = true;
cf.completeExceptionally(throwable);
< prev index next >