Beispiel #1
0
        public async Task InitialDump(DumpingDepth depth)
        {
            Stopwatch sw = new Stopwatch();

            sw.Start();
            await _dumper.DumpUser(_userId, depth);

            sw.Stop();
            Logger.Out("Done in {0} seconds", MessageType.Verbose, sw.ElapsedMilliseconds / 1000);
        }
Beispiel #2
0
        private static void BigDump(Deanon deanon, DumpingDepth depth)
        {
            Stopwatch _watches;

            _watches = StartOperation();
            deanon.InitialDump(depth).Wait();                      //7
            CompleteRelations(deanon);
            Person[] hiddenFriendsBig = deanon.GetHiddenFriends(); //8
            OutputUsers(hiddenFriendsBig);                         //9
            RestartWatchesAndShowTime(_watches, "big initial dump and complete relations");
        }
Beispiel #3
0
        public void ExpansionDump(DumpingDepth depth)
        {
            var people   = _analyzer.GetPeopleInCycles();
            int maxCount = people.Count();
            int counter  = 0;

            foreach (var person in people)
            {
                Logger.Out("Current expansion is {0}%", MessageType.Verbose, (double)100 / maxCount * (++counter));
                #region Timer start
                Stopwatch sw = new Stopwatch();
                sw.Start();
                #endregion
                _dumper.DumpUser(person.Id, depth).Wait();
                sw.Stop(); Logger.Out("Expansion node added in {0} seconds", MessageType.Verbose, sw.Elapsed.TotalSeconds);
            }
        }