enowars/bambiXploit-dotnet

Statistics are only traced over the last 80 seconds

Opened this issue · 1 comments

The Graph-View of "total flags submitted" is completely useless when shown over a region of 80s,
since unless it's just been started this barely amounts to anything other than a flat line

        private static async void Aggregate()
        {
            while (true)
            {
                var newFlagStatistics = FlagStatistics.AsEnumerable().ToList();
                newFlagStatistics.Add(new FlagsStatistic(
                    DateTimeOffset.UtcNow,
                    Interlocked.Read(ref okFlags)));
                if (newFlagStatistics.Count > 8)
                {
                    newFlagStatistics.RemoveAt(0);
                }

                FlagStatistics = newFlagStatistics;
                await Task.Delay(10000);
            }
        }

By multilplying newFlagStatistics.Count * 10s it can be seen that statistics are kept for at most 80s, which is not a useful timeframe for "absolute flags submitted"

Should we also change the y delta which we are showing? Do you have a proposal for the selection of an appropriate ymin and ymax?