diff options
author | Matthew Newhook <matthew@zeroc.com> | 2014-09-03 11:01:11 -0230 |
---|---|---|
committer | Matthew Newhook <matthew@zeroc.com> | 2014-09-03 11:01:11 -0230 |
commit | 3b0588532354adf7bf3b86e611a8ae4996bfe6ad (patch) | |
tree | 253961cb83af7bc3b1dfc7633a8f934789476cd1 /java/src/IceInternal/Network.java | |
parent | More work on ICE-2400: the send log thread now uses a separate communicator t... (diff) | |
download | ice-3b0588532354adf7bf3b86e611a8ae4996bfe6ad.tar.bz2 ice-3b0588532354adf7bf3b86e611a8ae4996bfe6ad.tar.xz ice-3b0588532354adf7bf3b86e611a8ae4996bfe6ad.zip |
- C#, Java: Removed Outgoing, fixed generated code to make synchronous
requests using AMI.
- Java: AsyncResult is now an interface.
- Added --arg to allTests.py.
- Fixed operations, adapterDeactivation and metrics test to work with
background IO.
- Added Collocated interrupt test.
- Added support for batch oneway requests using AMI.
- Added test in operations for batch oneway requests using AMI.
Diffstat (limited to 'java/src/IceInternal/Network.java')
-rw-r--r-- | java/src/IceInternal/Network.java | 104 |
1 files changed, 0 insertions, 104 deletions
diff --git a/java/src/IceInternal/Network.java b/java/src/IceInternal/Network.java index c06e7bf9550..324ccbe124d 100644 --- a/java/src/IceInternal/Network.java +++ b/java/src/IceInternal/Network.java @@ -487,94 +487,6 @@ public final class Network } } - public static java.nio.channels.SocketChannel - doAccept(java.nio.channels.ServerSocketChannel fd, int timeout) - { - java.nio.channels.SocketChannel result = null; - while(result == null) - { - try - { - result = fd.accept(); - if(result == null) - { - java.nio.channels.Selector selector = java.nio.channels.Selector.open(); - - try - { - while(true) - { - try - { - fd.register(selector, java.nio.channels.SelectionKey.OP_ACCEPT); - int n; - if(timeout > 0) - { - n = selector.select(timeout); - } - else if(timeout == 0) - { - n = selector.selectNow(); - } - else - { - n = selector.select(); - } - - if(n == 0) - { - throw new Ice.TimeoutException(); - } - - break; - } - catch(java.io.IOException ex) - { - if(interrupted(ex)) - { - continue; - } - throw new Ice.SocketException(ex); - } - } - } - finally - { - try - { - selector.close(); - } - catch(java.io.IOException ex) - { - // Ignore - } - } - } - } - catch(java.io.IOException ex) - { - if(interrupted(ex)) - { - continue; - } - throw new Ice.SocketException(ex); - } - } - - try - { - java.net.Socket socket = result.socket(); - socket.setTcpNoDelay(true); - socket.setKeepAlive(true); - } - catch(java.io.IOException ex) - { - throw new Ice.SocketException(ex); - } - - return result; - } - public static void setSendBufferSize(java.nio.channels.SocketChannel fd, int size) { @@ -1189,22 +1101,6 @@ public final class Network } public static String - fdToString(java.net.Socket fd) - { - if(fd == null) - { - return "<closed>"; - } - - java.net.InetAddress localAddr = fd.getLocalAddress(); - int localPort = fd.getLocalPort(); - java.net.InetAddress remoteAddr = fd.getInetAddress(); - int remotePort = fd.getPort(); - - return addressesToString(localAddr, localPort, remoteAddr, remotePort); - } - - public static String addressesToString(java.net.InetAddress localAddr, int localPort, java.net.InetAddress remoteAddr, int remotePort, NetworkProxy proxy, java.net.InetSocketAddress target) { |