mirror of
https://gitee.com/BDWare/cm
synced 2025-01-10 09:54:03 +00:00
doc: docker deploy
feat: support docker debug
This commit is contained in:
parent
9f79db3a63
commit
90a9d8af37
@ -67,10 +67,14 @@ public class ContractClient {
|
|||||||
isRunning = false;
|
isRunning = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public ContractClient(int startPort) {
|
||||||
|
this("127.0.0.1", startPort);
|
||||||
|
}
|
||||||
|
|
||||||
// Once the reconnect is called, all cp in the same node will reconnect to
|
// Once the reconnect is called, all cp in the same node will reconnect to
|
||||||
// current ContractManager
|
// current ContractManager
|
||||||
// We only consider the.
|
// We only consider the.
|
||||||
public ContractClient(int startPort) {
|
public ContractClient(String host, int startPort) {
|
||||||
// LOGGER.info("ContractClient 构造器 : ");
|
// LOGGER.info("ContractClient 构造器 : ");
|
||||||
contractMeta = new ContractMeta();
|
contractMeta = new ContractMeta();
|
||||||
outputTracer = new ContractPrinter();
|
outputTracer = new ContractPrinter();
|
||||||
@ -82,7 +86,7 @@ public class ContractClient {
|
|||||||
port = startPort;
|
port = startPort;
|
||||||
// LOGGER.info("ContractClient----构造器----- 端口 " + startPort);
|
// LOGGER.info("ContractClient----构造器----- 端口 " + startPort);
|
||||||
|
|
||||||
get = new SocketGet("127.0.0.1", startPort);
|
get = new SocketGet(host, startPort);
|
||||||
// LOGGER.info("ContractClient----构造器----- position---2");
|
// LOGGER.info("ContractClient----构造器----- position---2");
|
||||||
|
|
||||||
String cpCMI = get.syncGet("", "isContractProcess", ""); // CMI
|
String cpCMI = get.syncGet("", "isContractProcess", ""); // CMI
|
||||||
|
@ -389,6 +389,11 @@ public class ContractStatusRecorder extends StatusRecorder<ContractMeta> {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean visit(int i) {
|
public boolean visit(int i) {
|
||||||
|
return visit("127.0.0.1", i);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean visit(String host, int i) {
|
||||||
if (i == ContractManager.cPort.getCMPort()) {
|
if (i == ContractManager.cPort.getCMPort()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -396,7 +401,7 @@ public class ContractStatusRecorder extends StatusRecorder<ContractMeta> {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
ContractClient client = new ContractClient(i);
|
ContractClient client = new ContractClient(host, i);
|
||||||
// LOGGER.info("[CM重连] position-----1");
|
// LOGGER.info("[CM重连] position-----1");
|
||||||
if (client.isRunning) {
|
if (client.isRunning) {
|
||||||
LOGGER.debug("CP listened to port " + i + " is running");
|
LOGGER.debug("CP listened to port " + i + " is running");
|
||||||
|
Loading…
Reference in New Issue
Block a user