public void ProcessCommand(ClientManager clientManager, object command, short cmdType, long acknowledgementId, UsageStats stats, bool waitforResponse) { Common.Protobuf.ManagementCommand cmd = command as Common.Protobuf.ManagementCommand; if (ServerMonitor.MonitorActivity) { ServerMonitor.LogClientActivity("CmdMgr.PrsCmd", "enter"); } if (ServerMonitor.MonitorActivity) { ServerMonitor.LogClientActivity("CmdMgr.PrsCmd", "" + cmd); } if (SocketServer.Logger.IsDetailedLogsEnabled) { SocketServer.Logger.NCacheLog.Info("ConnectionManager.ReceiveCallback", clientManager.ToString() + " COMMAND to be executed : " + "Management Command" + " RequestId :" + cmd.requestId); } NCManagementCommandBase incommingCmd = null; incommingCmd = new ManagementCommand(); incommingCmd.ExecuteCommand(clientManager, cmd);/**/ if (SocketServer.Logger.IsDetailedLogsEnabled) { SocketServer.Logger.NCacheLog.Info("ConnectionManager.ReceiveCallback", clientManager.ToString() + " after executing COMMAND : " + "Management Command" + " RequestId :" + cmd.requestId); } #if SERVER if (clientManager != null && incommingCmd.OperationResult == OperationResult.Success) { if (clientManager.CmdExecuter != null) { clientManager.CmdExecuter.UpdateSocketServerStats(new SocketServerStats(clientManager.ClientsRequests, clientManager.ClientsBytesSent, clientManager.ClientsBytesRecieved)); } } #endif if (clientManager != null && incommingCmd.SerializedResponsePackets != null && !clientManager.IsCacheStopped) { foreach (IList reponse in incommingCmd.SerializedResponsePackets) { ConnectionManager.AssureSend(clientManager, reponse, false); } } if (ServerMonitor.MonitorActivity) { ServerMonitor.LogClientActivity("CmdMgr.PrsCmd", "exit"); } }
public void ProcessCommand(ClientManager clientManager, object command, long acknowledgementId, UsageStats stats) { Alachisoft.NCache.Common.Protobuf.ManagementCommand cmd = command as Alachisoft.NCache.Common.Protobuf.ManagementCommand; if (ServerMonitor.MonitorActivity) { ServerMonitor.LogClientActivity("CmdMgr.PrsCmd", "enter"); } if (ServerMonitor.MonitorActivity) { ServerMonitor.LogClientActivity("CmdMgr.PrsCmd", "" + cmd); } if (SocketServer.Logger.IsDetailedLogsEnabled) { SocketServer.Logger.NCacheLog.Info("ConnectionManager.ReceiveCallback", clientManager.ToString() + " COMMAND to be executed : " + "Management Command" + " RequestId :" + cmd.requestId); } NCManagementCommandBase incommingCmd = null; incommingCmd = new ManagementCommand(); incommingCmd.ExecuteCommand(clientManager, cmd);/**/ /*****************************************************************/ if (SocketServer.Logger.IsDetailedLogsEnabled) { SocketServer.Logger.NCacheLog.Info("ConnectionManager.ReceiveCallback", clientManager.ToString() + " after executing COMMAND : " + "Management Command" + " RequestId :" + cmd.requestId); } if (clientManager != null && incommingCmd.SerializedResponsePackets != null && !clientManager.IsCacheStopped) { foreach (byte[] reponse in incommingCmd.SerializedResponsePackets) { ConnectionManager.AssureSend(clientManager, reponse, Common.Enum.Priority.Normal); } } if (ServerMonitor.MonitorActivity) { ServerMonitor.LogClientActivity("CmdMgr.PrsCmd", "exit"); } }