Has anyone else discovered a memory leak issue with Pull Subscriptions (ExchangeService.SubscribeToPullNotifications()
) in Exchange Managed Web Services API? When calling PullSubscription.GetEvents()
the memory utilization climbs 4K with nearly every polling call. The only way I've been able to keep the memory utilization down is by forcing garbage collection (via GC.Collect()
) after every call - an unnecessary path.
I am surprised to see the API hasn't changed for almost a year.
This issue was resolved by another post. Essentially EWS was conflicting with another component that failed to release a NetworkStream
(due to a SqlException
). ANTS memory profiler was used to pinpoint the cause and timing of the issue. Without this profiling tool we would have never discovered the problem.