[Mono-bugs] [Bug 59624][Cri] Changed - Remoting over HTTP creates new thread for each request.

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Mon, 7 Jun 2004 11:57:37 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by lluis@ximian.com.

http://bugzilla.ximian.com/show_bug.cgi?id=59624

--- shadow/59624	2004-06-07 11:35:50.000000000 -0400
+++ shadow/59624.tmp.17211	2004-06-07 11:57:37.000000000 -0400
@@ -430,6 +430,32 @@
 
 ------- Additional Comments From ryoung@novell.com  2004-06-07 11:35 -------
 Besides the memory leak.  It doesn't seem like the thread pool is 
 working over HTTP.  When over TCP it looks like the request are 
 being handled by the thread pool, but over HTTP every request causes 
 a new thread to be created, then exited.
+
+------- Additional Comments From lluis@ximian.com  2004-06-07 11:57 -------
+Besides the thread issue :-). Notice that the test case is causing a
+memory leak itself. Since Server.InitializeLifetimeService() returns
+null, it means that the object will never expire and will never be
+collected by the GC. Every GetServer() creates a new Server instance
+that is never disposed. The following implementation should be ok for
+the test:
+
+public override Object InitializeLifetimeService()
+{
+	ILease lease = (ILease)base.InitializeLifetimeService();
+	if (lease.CurrentState == LeaseState.Initial)
+	{
+		lease.InitialLeaseTime = TimeSpan.FromSeconds(5);
+		lease.SponsorshipTimeout = TimeSpan.FromSeconds(10);
+		lease.RenewOnCallTime = TimeSpan.FromSeconds(2);
+	}
+	return lease;
+}
+
+However, even with this fixed I still get some memory leakage. Can you
+run the fixed test and tell me if you get the leak?. It would be also
+interesting to know if you get memory leaks when running the test case
+in bug 59597.
+