fix:some function rename

This commit is contained in:
tanyawen
2019-12-29 20:53:37 +08:00
parent 82105c4483
commit 98f55774cf
7 changed files with 84 additions and 129 deletions

View File

@@ -47,34 +47,5 @@ public class TrackerServer {
public InetSocketAddress getInetSocketAddress() {
return this.inetSockAddr;
}
public void close(Connection connection) throws IOException {
if (connection == null) {
return;
}
//if connection enabled get from connection pool
if (ClientGlobal.g_connection_pool_enabled) {
ConnectionPool.closeConnection(connection);
} else {
connection.close();
}
}
/**
* releaseConnection connection
* @param connection
* @throws IOException
*/
public void releaseConnection(Connection connection) throws IOException {
if (connection == null) {
return;
}
if (ClientGlobal.g_connection_pool_enabled) {
ConnectionPool.releaseConnection(connection);
} else {
connection.close();
}
}
}