Skip to content

Latest commit

 

History

History
17 lines (13 loc) · 708 Bytes

File metadata and controls

17 lines (13 loc) · 708 Bytes

This example demonstrates how to clean up per-client objects through the use of sessions.

When the client starts, a session object is created through which all per-client objects are created. The session object's timestamp must be refreshed by the client on a periodic basis otherwise it will be destroyed. Once the session is destroyed, whether by the client destroying the session upon termination or due to a timeout, all per-client objects are automatically cleaned up by the session object.

The Ice extension for Ruby currently supports only client-side functionality, therefore you must use a server from any other language mapping.

After starting the server, run the Ruby client:

$ ruby Client.rb