Caché System Administration Guide - InterSystems Documentation
Caché System Administration Guide - InterSystems Documentation
Caché System Administration Guide - InterSystems Documentation
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Managing <strong>Caché</strong> Licensing<br />
You modify how you specify the license user ID using the $SYSTEM.License.UserNameLicensing()<br />
method of the %SYSTEM.License class. By default, <strong>Caché</strong> uses the client IP address to identify a user<br />
to the license tracking subsystem. If you installed <strong>Caché</strong> with higher than Minimal initial security<br />
settings, each process has a user ID ($USERNAME). You can call the<br />
$SYSTEM.License.UserNameLicensing() system method to make the <strong>Caché</strong> license subsystem use<br />
$USERNAME as the license user identifier.<br />
The $SYSTEM.License.UserNameLicensing() method modifies the system state. You can also call<br />
it from SYSTEM^%ZSTART to enable username licensing at instance startup. The method has the<br />
following functions:<br />
• $SYSTEM.License.UserNameLicensing(1) — enables $USERNAME based licensing and returns<br />
the previous state.<br />
• $SYSTEM.License.UserNameLicensing(0) — disables $USERNAME based licensing and returns<br />
the previous state.<br />
• $SYSTEM.License.UserNameLicensing() — returns the current state. May return an error if<br />
called with an argument for license types that use special login rules.<br />
For example, the following displays whether username licensing is currently enabled or disabled:<br />
Write " Username Licensing",!<br />
Write " 1-enabled, 0-disabled",!<br />
Write $SYSTEM.License.UserNameLicensing(),!<br />
The following example enables, then disables username licensing:<br />
Set RC=$SYSTEM.License.UserNameLicensing(1)<br />
Write RC,!<br />
Set RC=$SYSTEM.License.UserNameLicensing(0)<br />
Write RC<br />
See the $USERNAME special variable entry in the <strong>Caché</strong> ObjectScript Reference for more information.<br />
4.4.3 CSP Connections and Other Special Cases<br />
CSP connections are a special case for logins. Inter<strong>System</strong>s strongly recommends that CSP applications<br />
use the %CSP.Session equivalent method, %CSP.Session.Login, to identify a user for licensing purposes.<br />
If they do not, the CSP session ID is used as the license user ID. Each session consumes a license<br />
unit, which in many cases is unsuitable. For example, a user can have several browser windows open<br />
concurrently. Alternatively, a user can connect via several pathways (CSP, a terminal window, and a<br />
<strong>Caché</strong> Direct connection from a Visual Basic client). In this case, you can use the %CSP.Session<br />
method, %CSP.Session.Login(username, password) to perform an explicit license login for the<br />
session.<br />
Any SOAP request in which the user is not identified does not use a license unit because it is considered<br />
a “machine request”; however, any SOAP request that identifies the user requires a license because it<br />
62 <strong>Caché</strong> <strong>System</strong> <strong>Administration</strong> <strong>Guide</strong>