[Git][java-team/jboss-xnio][master] 4 commits: New upstream version 3.8.6
Markus Koschany (@apo)
gitlab at salsa.debian.org
Fri Feb 11 18:06:40 GMT 2022
Markus Koschany pushed to branch master at Debian Java Maintainers / jboss-xnio
Commits:
f55457ce by Markus Koschany at 2022-02-11T18:36:40+01:00
New upstream version 3.8.6
- - - - -
2dd08f7a by Markus Koschany at 2022-02-11T18:36:41+01:00
Update upstream source from tag 'upstream/3.8.6'
Update to upstream version '3.8.6'
with Debian dir 66347064b97878e295765c26c0383f95d06555bf
- - - - -
48f34067 by Markus Koschany at 2022-02-11T18:37:14+01:00
Update copyright years
- - - - -
7e8a74f2 by Markus Koschany at 2022-02-11T18:37:48+01:00
Update changelog
- - - - -
11 changed files:
- api/pom.xml
- api/src/main/java/org/xnio/StreamConnection.java
- api/src/main/java/org/xnio/channels/PushBackStreamChannel.java
- api/src/main/java/org/xnio/conduits/PushBackStreamSourceConduit.java
- api/src/main/java/org/xnio/ssl/JsseSslConduitEngine.java
- api/src/main/java/org/xnio/ssl/JsseSslConnection.java
- debian/changelog
- debian/copyright
- nio-impl/pom.xml
- nio-impl/src/main/java/org/xnio/nio/NioSocketStreamConnection.java
- pom.xml
Changes:
=====================================
api/pom.xml
=====================================
@@ -37,7 +37,7 @@
<parent>
<groupId>org.jboss.xnio</groupId>
<artifactId>xnio-all</artifactId>
- <version>3.8.5.Final</version>
+ <version>3.8.6.Final</version>
</parent>
<dependencies>
=====================================
api/src/main/java/org/xnio/StreamConnection.java
=====================================
@@ -18,6 +18,7 @@
package org.xnio;
+import java.io.IOException;
import java.util.concurrent.atomic.AtomicReference;
import org.xnio.channels.CloseListenerSettable;
@@ -80,6 +81,23 @@ public abstract class StreamConnection extends Connection implements CloseListen
};
}
+ @Override protected void notifyReadClosed() {
+
+ try {
+ this.getSourceChannel().shutdownReads();
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ }
+
+ @Override protected void notifyWriteClosed() {
+ try {
+ this.getSinkChannel().shutdownWrites();
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ }
+
public ChannelListener<? super StreamConnection> getCloseListener() {
return closeListener.get();
}
=====================================
api/src/main/java/org/xnio/channels/PushBackStreamChannel.java
=====================================
@@ -254,8 +254,7 @@ public final class PushBackStreamChannel implements StreamSourceChannel, Wrapped
cnt = target.write(src, position);
if (cnt == rem) {
// we emptied our buffer
- channel = next;
- buffer.free();
+ moveToNext();
} else {
return cnt;
}
@@ -263,7 +262,7 @@ public final class PushBackStreamChannel implements StreamSourceChannel, Wrapped
count -= cnt;
}
} catch (IllegalStateException ignored) {
- channel = next;
+ moveToNext();
cnt = 0L;
}
return cnt + next.transferTo(position, count, target);
@@ -289,14 +288,13 @@ public final class PushBackStreamChannel implements StreamSourceChannel, Wrapped
cnt = target.write(src);
if (cnt == rem) {
// we emptied our buffer
- channel = next;
- buffer.free();
+ moveToNext();
} else {
return cnt;
}
}
} catch (IllegalStateException ignored) {
- channel = next;
+ moveToNext();
cnt = 0L;
}
final long res = next.transferTo(count - cnt, throughBuffer, target);
@@ -318,7 +316,7 @@ public final class PushBackStreamChannel implements StreamSourceChannel, Wrapped
return cnt;
}
} catch (IllegalStateException ignored) {
- channel = next;
+ moveToNext();
cnt = 0;
}
final long res = next.read(dsts, offset, length);
@@ -340,14 +338,13 @@ public final class PushBackStreamChannel implements StreamSourceChannel, Wrapped
if (src.hasRemaining()) {
return cnt;
}
- final StreamSourceChannel next = channel = this.next;
- buffer.free();
+ final StreamSourceChannel next = moveToNext();
if (cnt > 0 && next == firstChannel) {
// don't hit the main channel until the user wants to
return cnt;
}
} catch (IllegalStateException ignored) {
- channel = next;
+ moveToNext();
cnt = 0;
}
final int res = next.read(dst);
@@ -427,5 +424,10 @@ public final class PushBackStreamChannel implements StreamSourceChannel, Wrapped
public <T> T setOption(final Option<T> option, final T value) throws IllegalArgumentException, IOException {
throw new UnsupportedOperationException();
}
+
+ private final StreamSourceChannel moveToNext() {
+ buffer.free();
+ return channel = next;
+ }
}
}
=====================================
api/src/main/java/org/xnio/conduits/PushBackStreamSourceConduit.java
=====================================
@@ -111,6 +111,17 @@ public final class PushBackStreamSourceConduit extends AbstractStreamSourceCondu
next.wakeupReads();
}
+ public void terminateReads() throws IOException {
+ try {
+ super.terminateReads();
+ } finally {
+ if (pooledBuffer != null) {
+ pooledBuffer.free();
+ }
+ next.terminateReads();
+ }
+ }
+
public void awaitReadable(final long time, final TimeUnit timeUnit) throws IOException {
// readable
}
@@ -131,14 +142,13 @@ public final class PushBackStreamSourceConduit extends AbstractStreamSourceCondu
if (src.hasRemaining()) {
return cnt;
}
- current = next;
- pooledBuffer.free();
+ moveToNext();
if (cnt > 0 && next == PushBackStreamSourceConduit.this.next) {
// don't hit the main channel until the user wants to
return cnt;
}
} catch (IllegalStateException ignored) {
- current = next;
+ moveToNext();
cnt = 0;
}
final int res = next.read(dst);
@@ -154,14 +164,13 @@ public final class PushBackStreamSourceConduit extends AbstractStreamSourceCondu
if (src.hasRemaining()) {
return cnt;
}
- current = next;
- pooledBuffer.free();
+ moveToNext();
if (cnt > 0L && next == PushBackStreamSourceConduit.this.next) {
// don't hit the main channel until the user wants to
return cnt;
}
} catch (IllegalStateException ignored) {
- current = next;
+ moveToNext();
cnt = 0;
}
final long res = next.read(dsts, offs, len);
@@ -186,8 +195,7 @@ public final class PushBackStreamSourceConduit extends AbstractStreamSourceCondu
cnt = target.write(src, position);
if (cnt == rem) {
// we emptied our buffer
- current = next;
- pooledBuffer.free();
+ moveToNext();
} else {
return cnt;
}
@@ -195,7 +203,7 @@ public final class PushBackStreamSourceConduit extends AbstractStreamSourceCondu
count -= cnt;
}
} catch (IllegalStateException ignored) {
- current = next;
+ moveToNext();
cnt = 0L;
}
return cnt + next.transferTo(position, count, target);
@@ -231,8 +239,7 @@ public final class PushBackStreamSourceConduit extends AbstractStreamSourceCondu
cnt = target.write(src);
if (cnt == rem) {
// we emptied our buffer
- current = next;
- pooledBuffer.free();
+ moveToNext();
} else {
if (cnt == 0) {
//a bit yuck, but if we have filed to copy anything we need to transfer data into the throughbuffer
@@ -249,11 +256,16 @@ public final class PushBackStreamSourceConduit extends AbstractStreamSourceCondu
}
}
} catch (IllegalStateException ignored) {
- current = next;
+ moveToNext();
cnt = 0L;
}
final long res = next.transferTo(count - cnt, throughBuffer, target);
return res > 0L ? cnt + res : cnt > 0L ? cnt : res;
}
+
+ private final void moveToNext() {
+ current = next;
+ pooledBuffer.free();
+ }
}
}
=====================================
api/src/main/java/org/xnio/ssl/JsseSslConduitEngine.java
=====================================
@@ -747,7 +747,7 @@ final class JsseSslConduitEngine {
}
}
case CLOSED: {
- // if unwrap processed any data, it should return bytes produced instead of -1
+ // if unwrap processed any data, it should return bytes consumed instead of -1
if (result.bytesConsumed() > 0) {
return result.bytesConsumed();
}
@@ -1207,7 +1207,7 @@ final class JsseSslConduitEngine {
public boolean isDataAvailable() {
synchronized (getUnwrapLock()) {
try {
- return readBuffer.getResource().hasRemaining() || (receiveBuffer.getResource().hasRemaining() && !isUnderflow());
+ return readBuffer.getResource().position() > 0 || (receiveBuffer.getResource().hasRemaining() && !isUnderflow());
} catch (IllegalStateException ignored) {
return false;
}
=====================================
api/src/main/java/org/xnio/ssl/JsseSslConnection.java
=====================================
@@ -67,10 +67,6 @@ public final class JsseSslConnection extends SslConnection {
}
}
- protected void notifyWriteClosed() {}
-
- protected void notifyReadClosed() {}
-
public SocketAddress getPeerAddress() {
return streamConnection.getPeerAddress();
}
=====================================
debian/changelog
=====================================
@@ -1,3 +1,9 @@
+jboss-xnio (3.8.6-1) unstable; urgency=medium
+
+ * New upstream version 3.8.6.
+
+ -- Markus Koschany <apo at debian.org> Fri, 11 Feb 2022 18:37:30 +0100
+
jboss-xnio (3.8.5-1) unstable; urgency=medium
* New upstream version 3.8.5.
=====================================
debian/copyright
=====================================
@@ -3,7 +3,7 @@ Upstream-Name: Jboss XNIO
Source: https://github.com/xnio/xnio
Files: *
-Copyright: 2015-2021, Red Hat, Inc.
+Copyright: 2015-2022, Red Hat, Inc.
License: Apache-2.0
Files: nio-impl/src/test/java/org/xnio/nio/test/NioHalfDuplexChannelPipeTestCase.java
@@ -17,7 +17,7 @@ Copyright: 2010-2015, Red Hat, Inc
License: LGPL-2.1+
Files: debian/*
-Copyright: 2015-2021, Markus Koschany <apo at debian.org>
+Copyright: 2015-2022, Markus Koschany <apo at debian.org>
License: Apache-2.0 or LGPL-2.1+
License: Apache-2.0
=====================================
nio-impl/pom.xml
=====================================
@@ -31,7 +31,7 @@
<parent>
<groupId>org.jboss.xnio</groupId>
<artifactId>xnio-all</artifactId>
- <version>3.8.5.Final</version>
+ <version>3.8.6.Final</version>
</parent>
<properties>
=====================================
nio-impl/src/main/java/org/xnio/nio/NioSocketStreamConnection.java
=====================================
@@ -142,10 +142,12 @@ final class NioSocketStreamConnection extends AbstractNioStreamConnection {
protected void notifyWriteClosed() {
conduit.writeTerminated();
+ super.notifyWriteClosed();
}
protected void notifyReadClosed() {
conduit.readTerminated();
+ super.notifyReadClosed();
}
SocketChannel getChannel() {
=====================================
pom.xml
=====================================
@@ -25,14 +25,14 @@
<parent>
<groupId>org.jboss</groupId>
<artifactId>jboss-parent</artifactId>
- <version>35</version>
+ <version>39</version>
</parent>
<groupId>org.jboss.xnio</groupId>
<artifactId>xnio-all</artifactId>
<packaging>pom</packaging>
<name>XNIO Parent POM</name>
- <version>3.8.5.Final</version>
+ <version>3.8.6.Final</version>
<description>The aggregator POM of the XNIO project</description>
<licenses>
@@ -49,15 +49,15 @@
</modules>
<properties>
- <byteman-version>4.0.8</byteman-version>
- <version.org.jboss.logging.jboss-logging>3.4.1.Final</version.org.jboss.logging.jboss-logging>
+ <byteman-version>4.0.18</byteman-version>
+ <version.org.jboss.logging.jboss-logging>3.4.3.Final</version.org.jboss.logging.jboss-logging>
<version.org.jboss.logging.jboss-logging-tools>2.2.1.Final</version.org.jboss.logging.jboss-logging-tools>
- <version.org.jboss.logmanager.jboss-logmanager>2.1.14.Final</version.org.jboss.logmanager.jboss-logmanager>
- <version.org.jboss.threads>2.3.3.Final</version.org.jboss.threads>
- <version.org.wildfly.common>1.5.2.Final</version.org.wildfly.common>
+ <version.org.jboss.logmanager.jboss-logmanager>2.1.18.Final</version.org.jboss.logmanager.jboss-logmanager>
+ <version.org.jboss.threads>2.3.6.Final</version.org.jboss.threads>
+ <version.org.wildfly.common>1.5.4.Final</version.org.wildfly.common>
<version.org.wildfly.client-config>1.0.1.Final</version.org.wildfly.client-config>
- <version.bridger.plugin>1.5.Final</version.bridger.plugin>
- <version.junit>4.12</version.junit>
+ <version.bridger.plugin>1.6.Final</version.bridger.plugin>
+ <version.junit>4.13.2</version.junit>
<version.jmock>2.12.0</version.jmock>
<org.xnio.ssl.new>false</org.xnio.ssl.new>
@@ -113,6 +113,12 @@
<groupId>org.wildfly.client</groupId>
<artifactId>wildfly-client-config</artifactId>
<version>${version.org.wildfly.client-config}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>org.wildfly.common</groupId>
+ <artifactId>wildfly-common</artifactId>
+ </exclusion>
+ </exclusions>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
View it on GitLab: https://salsa.debian.org/java-team/jboss-xnio/-/compare/ec14c063db5bb71dedc53b3fb22d3d57701addfb...7e8a74f21f08ce91323c870d18c5349d067eb78e
--
View it on GitLab: https://salsa.debian.org/java-team/jboss-xnio/-/compare/ec14c063db5bb71dedc53b3fb22d3d57701addfb...7e8a74f21f08ce91323c870d18c5349d067eb78e
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-java-commits/attachments/20220211/cf3ad612/attachment.htm>
More information about the pkg-java-commits
mailing list