예제 #1
0
        static void Main(string[] args)
        {
            var mainService = new MainService();
            var consoleInfo = ConsoleInfo.GetInstance();

            new Thread(o => mainService.Start(100000)).Start();

            var counter = 1;

            while (true)
            {
                Console.WriteLine($"{counter}: {DateTime.Now}.");
                Console.WriteLine($"Sent object count: {consoleInfo.GetSentObjectCount()}.");
                Console.WriteLine($"db object count: {consoleInfo.GetObjectCount()}.");

                Console.WriteLine($"\n \n");
                counter++;

                Thread.Sleep(1000);
            }


            Console.ReadKey();
        }
예제 #2
0
 public MainService()
 {
     _redisService = new RedisService();
     _consoleInfo  = ConsoleInfo.GetInstance();
 }