Пример #1
0
		public void MakePersistent(String PlayerName, DateTime ActionTime, String ActionID, ServiceFailedArgs ServiceFailed)
			{
			String DateTimeDirectoryPart = ActionTime.ToString("yyyy_MM_dd") + "\\"
					+ PlayerName + "\\"
					+ ActionTime.ToString("HH") + "-"
					+ ActionTime.AddHours(1).ToString("HH");
			String RootDirectory = System.IO.Path.Combine(MaschinenStatusRoot, DateTimeDirectoryPart);
			if (!Directory.Exists(RootDirectory))
				Directory.CreateDirectory(RootDirectory);
			String FileName = ActionTime.ToString("mm_ss_") + "_710-_" + ActionID + ".ServiceFailed";
			RefreshHistoricCounter(FileName);
			WMB.Basics.SerializeObjectToFile(System.IO.Path.Combine(RootDirectory, FileName), ServiceFailed);
			}
Пример #2
0
		internal void ServiceFailed(ServiceFailedArgs.Regions region, Tcp.Service service, Exception exc)
		{
			ServiceFailedArgs args = new ServiceFailedArgs() { Region = region, Exception = exc, ServiceName = service.Name, ServiceNumber = service.Number };
			BaseConnection.Log(service, args.ToString());
			if (BaseConnection.IsOpened)
			{
				ServiceSend(args, Guid.Empty, 502);
			}
		}