Skip to content

Commit ce1072f

Browse files
authored
add interfaces for sdk proxy (#235)
1 parent 7725790 commit ce1072f

File tree

4 files changed

+10
-2
lines changed

4 files changed

+10
-2
lines changed

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ ext {
3636
// integrationTest.mustRunAfter test
3737
allprojects {
3838
group = 'org.fisco-bcos.java-sdk'
39-
version = '2.7.1'
39+
version = '2.7.2-SNAPSHOT'
4040
apply plugin: 'maven'
4141
apply plugin: 'maven-publish'
4242
apply plugin: 'idea'

sdk-core/src/main/java/org/fisco/bcos/sdk/network/ConnectionManager.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@ protected void removeConnectionContext(String ip, int port, ChannelHandlerContex
426426
}
427427
}
428428

429-
protected void removeConnection(String peerIpPort) {
429+
public void removeConnection(String peerIpPort) {
430430
for (ConnectionInfo conn : connectionInfoList) {
431431
String ipPort = conn.getIp() + ":" + conn.getPort();
432432
if (ipPort.equals(peerIpPort)) {

sdk-core/src/main/java/org/fisco/bcos/sdk/network/Network.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,9 @@ static Network build(ConfigOption configOption, MsgHandler handler) throws Confi
9292
*/
9393
void setMsgHandleThreadPool(ExecutorService threadPool);
9494

95+
/** Get connection manager */
96+
ConnectionManager getConnManager();
97+
9598
/** Exit gracefully */
9699
void stop();
97100
}

sdk-core/src/main/java/org/fisco/bcos/sdk/network/NetworkImp.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,11 @@ public void setMsgHandleThreadPool(ExecutorService threadPool) {
222222
connManager.setMsgHandleThreadPool(threadPool);
223223
}
224224

225+
@Override
226+
public ConnectionManager getConnManager() {
227+
return connManager;
228+
}
229+
225230
@Override
226231
public void stop() {
227232
logger.debug("stop Network...");

0 commit comments

Comments
 (0)