我在我的 UCMA 应用程序上运行一个内存分析器,它作为一个客户端,将记录器参与者添加到会话中,我注意到很多字符串实例占用了内存(即使参与者被删除并且在一段时间不活动后我注意到这些字符串不'不要收集垃圾):
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.DiagnosticsInformation..ctor( int,DiagnosticVisibility )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.DiagnosticsInformation.CreateOutgoingDiagnosticsInformation( uint )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Collaboration.Call.SignalingSession_StateChanged( object,SignalingStateChangedEventArgs )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.EventWorkitem<TEventArgs>.Process()
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.WorkitemQueue.ProcessItems()
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.SerializationQueue<T>.ResumeProcessing()
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.SerializationQueue<T>.ResumeProcessingCallback( object )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.QueueWorkItemState.ExecuteWrappedMethod( WaitCallback,object )
mscorlib!System.Threading.ExecutionContext.Run( ExecutionContext,ContextCallback,object )
mscorlib!System.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal( _ThreadPoolWaitCallback )
mscorlib!System.Threading._ThreadPoolWaitCallback.PerformWaitCallback( object )
我看到大约 2000 个这样的实例,它们没有被清理。有没有人以前见过这个并且知道原因可能是什么,或者这是否是框架本身的 UCMA 问题?
编辑:我还看到框架上有很多反序列化(XML 反序列化器对象没有被清理?)
System.Xml!System.Xml.Serialization.XmlSerializer.Deserialize( XmlReader,string,XmlDeserializationEvents )
System.Xml!System.Xml.Serialization.XmlSerializer.Deserialize( XmlReader,string )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.XmlHelper.DeserializeObjectFragment( byte[],XmlSerializer )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Collaboration.Conferencing.ConferenceJoinCommandResponse.TryProcessResponseCore( SipMessageData,ref RealTimeException )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Collaboration.Conferencing.EstablishFocusSessionsAsyncResult.ParticipateCallback( IAsyncResult )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.CompletionCallbackWorkItem.Microsoft.Rtc.Signaling.IWorkitem.Process()
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.WorkitemQueue.ProcessItems()
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.SerializationQueue<T>.ResumeProcessing()
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.SerializationQueue<T>.ResumeProcessingCallback( object )
Microsoft.Rtc.Collaboration!Microsoft.Rtc.Signaling.QueueWorkItemState.ExecuteWrappedMethod( WaitCallback,object )
mscorlib!System.Threading.ExecutionContext.Run( ExecutionContext,ContextCallback,object )
mscorlib!System.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal( _ThreadPoolWaitCallback )
mscorlib!System.Threading._ThreadPoolWaitCallback.PerformWaitCallback( object )