asp.net - .NET "Timer" would block other method calls? -
In ASP.Net 3.5, we suspect that a representative triggering by a "timer" will stop another method call . From the log, some function calls will wait for the representative to finish and will continue to work.
Is this true? If so, what can I do?
PS: Representative includes code for using WCF to obtain data and the following code
Change private zeros & lt; T & gt; (Referee LIIL & lt; T & gt; src, IList & lt; T & gt; des) {lock (src) {while (src.Count> 0) {GC.SuppressFinalize (src.ElementAt (0)) ; Src.RemoveAt (0); } GC.SuppressFinalize (src); Src = des; }}
Thanks a lot
It depends on the timer
implementation you are using - There are at least three if you use the timer
, which sets a fire on a pool bridge without any synchronization object, then it should not be a problem.
The fact is that for the period you are locking, the call will stop locking on the same object, of course.
Comments
Post a Comment