mirror of
https://gitee.com/BDWare/cp.git
synced 2025-01-10 01:44:08 +00:00
fix doip local singleton
This commit is contained in:
parent
35e39f3dd9
commit
8ffaa3f535
@ -51,7 +51,7 @@ dependencies {
|
|||||||
implementation 'com.sun.mail:javax.mail:1.6.2'
|
implementation 'com.sun.mail:javax.mail:1.6.2'
|
||||||
implementation 'com.squareup.okhttp3:okhttp:4.9.1'
|
implementation 'com.squareup.okhttp3:okhttp:4.9.1'
|
||||||
implementation 'org.bdware.bdcontract:sdk-java:1.0.2'
|
implementation 'org.bdware.bdcontract:sdk-java:1.0.2'
|
||||||
implementation 'org.bdware.doip:doip-audit-tool:1.3.6'
|
implementation 'org.bdware.doip:doip-audit-tool:1.3.7'
|
||||||
implementation 'org.bdware.doip:doip-sdk:1.4.9'
|
implementation 'org.bdware.doip:doip-sdk:1.4.9'
|
||||||
implementation fileTree(dir: 'lib', include: '*.jar')
|
implementation fileTree(dir: 'lib', include: '*.jar')
|
||||||
testImplementation 'junit:junit:4.13.2'
|
testImplementation 'junit:junit:4.13.2'
|
||||||
@ -70,8 +70,8 @@ jar {
|
|||||||
// uncomment this when publish,
|
// uncomment this when publish,
|
||||||
// while develop at local use "false"
|
// while develop at local use "false"
|
||||||
configurations.runtimeClasspath.filter {
|
configurations.runtimeClasspath.filter {
|
||||||
it.getAbsolutePath().contains("/lib/")
|
// it.getAbsolutePath().contains("/lib/")
|
||||||
// false
|
false
|
||||||
}.collect {
|
}.collect {
|
||||||
it.isDirectory() ? it : zipTree(it)
|
it.isDirectory() ? it : zipTree(it)
|
||||||
}
|
}
|
||||||
|
@ -78,7 +78,7 @@ public class DOIPUtil {
|
|||||||
if (msg != null) {
|
if (msg != null) {
|
||||||
return msg;
|
return msg;
|
||||||
} else
|
} else
|
||||||
return DoipMessageFactory.createTimeoutResponse(message.requestID);
|
return DoipMessageFactory.createTimeoutResponse(message.requestID, "timeout");
|
||||||
} catch (Exception ie) {
|
} catch (Exception ie) {
|
||||||
ie.printStackTrace();
|
ie.printStackTrace();
|
||||||
return DoipMessageFactory.createConnectFailedResponse(message.requestID);
|
return DoipMessageFactory.createConnectFailedResponse(message.requestID);
|
||||||
@ -219,7 +219,7 @@ public class DOIPUtil {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static IRPClientWrapper createIrpClient(String uri, String pubkey, String privateKey,
|
public static IRPClientWrapper createIrpClient(String uri, String pubkey, String privateKey,
|
||||||
String repoName) {
|
String repoName) {
|
||||||
EndpointConfig config = new EndpointConfig();
|
EndpointConfig config = new EndpointConfig();
|
||||||
config.routerURI = uri;
|
config.routerURI = uri;
|
||||||
config.repoName = repoName;
|
config.repoName = repoName;
|
||||||
|
@ -95,7 +95,7 @@ public class DoipLocalSingleton {
|
|||||||
DOOPRequestHandler handler = ContractProcess.instance.doopRequestHandler;
|
DOOPRequestHandler handler = ContractProcess.instance.doopRequestHandler;
|
||||||
server.setRequestCallback(handler);
|
server.setRequestCallback(handler);
|
||||||
if (config != null)
|
if (config != null)
|
||||||
SharableVarManager.initSharableVarManager(info.id, config);
|
SharableVarManager.initSharableVarManager(info.id, config);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user