Spring.NET 1.3.0 RC1 for .NET 2.0 API Reference

BaseRemoteObject.InitializeLifetimeService Method

Obtains a lifetime service object to control the lifetime policy for this instance.

[Visual Basic]
Public Overrides Sub InitializeLifetimeService()
public override object InitializeLifetimeService();

Return Value

An object of type ILease used to control the lifetime policy for this instance. This is the current lifetime service object for this instance if one exists; otherwise, a new lifetime service object initialized to the value of the LeaseManagerPollTime property.


This method uses property values to configure ILease for this object.

It is very much inspired by Ingo Rammer's example in Chapter 6 of "Advanced .NET Remoting", but is modified slightly to make it more "Spring-friendly". Basically, the main difference is that instead of pulling lease configuration from the .NET config file, this implementation relies on Spring DI to get appropriate values injected, which makes it much more flexible.


Exception Type Condition
SecurityException The immediate caller does not have infrastructure permission.

See Also

BaseRemoteObject Class | Spring.Remoting.Support Namespace