	How to license-enable a server application with EasyLicenser
	------------------------------------------------------------

Types of server architectures
-----------------------------

	A server architecture can take many shapes and forms.  Here are a
	few examples:

	1. Multithreaded server
	2. Multiprocess server with shared memory
	3. Multiprocess server with no shared memory
	4. Clustered server

	In most instances, a server application supports the notion of a session,
	and the challenge is to reliably manage the count of active sessions
	independent of the server architecture.

Selection of licensing models
-----------------------------

	The most common server licensing model is "concurrent user", where
	the active session count is throttled to a specified license limit.
	This model is applicable to server applications that support sessions.
    The second most common model is "CPU", which is applicable to all
	server applications.  In a few instances, a "named user" server
	licensing model may be applicable, when a given user account is
	concurrently accessed by multiple sessions.

Getting host environment parameters in Java
-------------------------------------------	

	You will need to obtain information on CPU counts and 
	other hardware parameters via a property or configuration file, 
	which will most likely be the file containing the license key.

	Alternatively, you can execute a trusted system program that
	returns this information.

	Typically, this information is obtained one-time, at application
	startup.

Concurrent-user licensing
-------------------------

	Getting the active-session count
	--------------------------------
	The optimal mechanism for obtaining an active-session varies with
	the application architecture and the server architecture, but is
	usually a trivial operation.  Here are a few representative
	examples:

	Case 1: application has business methods for "signon" and "signoff".

			Conceptually, what's needed is to maintain an active-session-
			count variable.  The variable is incremented upon "signon",
			and decremented upon "signoff" or session timeout.

			The variable can be realized as a function of the application
			server architecture as follows:

			Multithreaded server architecture:
				Maintain the session count in a synchronized (ie.,
				mutex-protected) thread-global variable.
			Multiprocess server architecture with shared memory:
				Maintain the session count in a variable in shared-global
				memory.  As part of dead-process cleanup, decrement the
				count.
			Multiprocess server architecture with no shared memory:
				Maintain the session count in the persistent store used
				for session state management, for example a file system or
				database.
			Clustered architecture:
				This is somewhat similar to a multiprocess-with-no-shared-memory 
				scenario, except that it is not an option to count processes.
				The ideal solution is to add session-count tracking in the
				database, assuming such an application is a database application.  
				Such a solution has the added advantage of being insensitive to
				the application architecture.

			Case 1 applies to the vast majority of enterprise and hosted
			applications.  These include applications that are web-based
			as well as those using distributed object technologies such
			as RMI and CORBA.

	Case 2: a raw C based dedicated-server multiprocess server application 
		    with implicit session initiation upon a socket "accept", and 
		    no shared memory.

			A Unix "ps -ef" or equivalent command, filtered by the program
			executable name can be issued at the time of socket acceptance 
			to give an accurate active-session count.

Invoking the license key checking API
-------------------------------------

	When to invoke
	--------------
		CPU-based licensing: typically, it is sufficient to perform the check
			at application startup.

		Named-user licensing: it is sufficient to perform the check whenever
			an administrative action is performed to add a user.

		Concurrent-user licensing: the check should be performed whenever the
			active-session-count is about to be incremented.

	How to invoke
	-------------

		The CPU count / CPU MHZ / concurrent-user count / named-user count
		value is passed into the license-key check API call as the "current
		usage value" together with the other parameters.  The API validates 
		the count against the usage limit that is encoded into the key.

		For specific examples on what the code looks like, refer to the
		"Java ISV Application Development Guide" / "C/C++ ISV Application
		Development Guide" / "Visual Basic ISV Application Development Guide"
		according to your programming language.

						-x-
