public void Run() { blockMiner.Start(); rpcServer.Start(); Console.ReadKey(); blockMiner.Stop(); rpcServer.Stop(); }
/// <summary> /// 停止RPC服务器 /// </summary> /// <returns></returns> public static bool StopRpcServer() { if (_server != null) { _server.Stop(); } LogHelper.Info("停止数据处理模块【停止RPC服务处理完成】!"); return(true); }
public void Stop_Rpc_Server_After_Running_Tests() { var dotNetTestRunner = new DotNetTestRunner(_rpcServerMock, _process); var testProjectOutputPath = "bin/debug"; var coverageContext = new CoverageContext(); dotNetTestRunner.Run(coverageContext, testProjectOutputPath); Received.InOrder(() => { _process.Execute(Arg.Any <string>(), Arg.Any <string>(), Arg.Any <string>()); _rpcServerMock.Stop(); }); }
public void Run(CoverageContext coverageContext, string testProjectOutputPath) { var testProjectPath = GetTestProjectPath(testProjectOutputPath); _rpcServer.Start(coverageContext); /* * It is important that the --no-build flag is used, otherwise dotnet-test will run a new build of the project * which will overwrite the assembly files that were instrumented. */ _process.Execute("dotnet", "test --no-build", testProjectPath); _rpcServer.Stop(); }
/// <summary> /// 停止RPC服务器 /// </summary> /// <returns></returns> public bool StopRpcServer() { _server.Stop(); LogHelper.Debug("停止RPC服务器成功"); return(true); }
public void Dispose() { _slaveServer.Stop().Wait(); }
public void Dispose() { _agentServer.Stop().Wait(); }
public void RpcStopCommand() => _rpc?.Stop();