private void SendBulkEvents()
        {
            if (wrappedEventsCache.HasReachedMaxSize())
            {
                Logger.Warn("Split SDK events queue is full. Events may have been dropped. Consider increasing capacity.");
            }

            var wrappedEvents = wrappedEventsCache.FetchAllAndClear();

            if (wrappedEvents.Count > 0)
            {
                try
                {
                    var events = wrappedEvents
                                 .Select(x => x.Event)
                                 .ToList();

                    apiClient.SendBulkEvents(events);

                    AcumulateSize = 0;
                }
                catch (Exception e)
                {
                    Logger.Error("Exception caught updating events.", e);
                }
            }
        }
        private void SendBulkImpressions()
        {
            if (((InMemorySimpleCache <KeyImpression>)impressionsCache).HasReachedMaxSize())
            {
                Logger.Warn("Split SDK impressions queue is full. Impressions may have been dropped. Consider increasing capacity.");
            }

            var impressions = impressionsCache.FetchAllAndClear();

            if (impressions.Count > 0)
            {
                try
                {
                    apiClient.SendBulkImpressions(impressions);
                }
                catch (Exception e)
                {
                    Logger.Error("Exception caught updating impressions.", e);
                }
            }
        }