How licensing works
In this topic: |
How licensing works
This section discusses how licensing works. Basic License Server installation and setup is straightforward, and is covered in Installing Validate.
- build
- user
- web service
- concurrent
Build license
A build license, most often referred to as a fixed build license, allows you to run one or more full analyses on a specific machine. The license is locked to the machine itself and loads results to Validate. This is the kind of license you need if you install and run Validate analyses on a long-lived, dedicated machine.
How the build license works
- A build license is checked out when any of the below tools is started and is returned when the tool exits.
- One build license is checked out for each unique host.
- All tools that consume a build license are reserved for that host.
- If you have installed components from both the Server and desktop analysis plug-in packages on a single host, and you run tools from both packages simultaneously, you will use two licenses (in this case, a user license and a build license).
What tools can consume a build license?
- kwadmin/validate admin (except for
list
,get
andexport
commands) - kwbuildproject
- kwecbuild
- kwstruct101
User license
A user license allows you to run the Desktop tools, plug-ins, or log in to Validate.
How the user license works
Once a license is checked out by a user, the rest of the user tools listed below are reserved for them. You can use any number of the tools listed below with a single user license, as long as you log in with the same user ID.
If you have different user IDs when you log in to different operating systems, Validate consumes one license for each. For example, if your Windows login is "John Smith" and your Linux login is jsmith, Validate consumes two licenses.
Example 1: LDAP or Single sign-on
If you have LDAP or Single sign-on configured and you attempt to log in to both a Windows and a Linux machine where the user credentials are different, two licenses are consumed.
For example, a user, John Smith, logs into Windows with full name ('John Smith'), and logs into his Linux machine which uses a short name like 'jsmith'. In this case, if John Smith uses Validate from Windows and Linux, two licenses are consumed.
Example 2: Alternate access methods
If you use an alternate access method such as NIS or Basic, a license is checked out for each user that logs into Validate. When logging in, be sure to use the same login credentials that you use when running the command line tools.
What tools can consume a user license?
- Validate portal
- IDE plug-ins
- kwcheck
Web service license
A web service license allows you to run the Validate Server.
How the web service license works
After you install the Validate package, one of the steps is to start the Validate Server. Starting the Validate Server, either by using the validate service command or as a Windows Service, requires a web service license. Validate releases the license when you stop the Validate Server. Each projects_root directory consumes an instance of validate service.
What tools can consume a web service license?
- validate service
Concurrent licenses
There are two types of concurrent licenses: a build agent license and a CI agent license.
How the build agent license works
A build agent license allows you to run a single analysis on any machine and load the results to Validate. This is the kind of license you need if you're using containers or spinning up machines in the cloud to do the analysis--wherever you have temporary environments.
A build agent license provides the tools listed below with the proper license to run a single analysis on a single server at one time. To run analyses concurrently, you need multiple build agent licenses. For example, if you want to run five analyses at once, you need to have five build agent licenses. Validate checks out a license when you run the command and returns it when the command completes.
What tools can consume a build agent license?
- kwbuildproject
- validate admin
- kwstruct101
How the CI agent license works
The CI agent license is useful for analysis in a CI environment because it allows you to do a quick analysis of parts of an application--one or more files. Use this license type when you want to analyze only a single file or set of files, not an entire application. To make it possible, you need to connect to a project.
This capability is useful in a pre-check-in environment, where you can, for example, set up the build to fail under certain conditions, such as if there are new issues detected.
The CI agent output can be directed to a text file. Whereas the kwbuildproject analysis results (used by other license types) are loaded to Validate, the kwciagent analysis results are local to the CI agent workspace. You cannot load results to Validate and you need a connected project.
A CI agent license is checked out when you run the command and returns it when the command completes.
What tools can consume a CI agent license?
- kwciagent
Detailed look at how the user license works
Many of the tools that consume a user license have a time-out period associated with them.
Tool | Licensing behavior |
---|---|
Validate | Checks out a license when you log in and returns it when you log out or after 30 minutes of inactivity. You can have Validate open in two different browsers, for example Chrome and Firefox, and as long as you are logged into both with the same user ID you will only consume one user license. Logging in to Validate with the same user ID on an additional machine will cause any existing sessions for that user ID to be logged out. Returning to a machine logged out in such a way and performing any action will cause the Login dialog to appear. |
Visual Studio C/C++ extension | Checks out a license when you open a solution or workspace. Returns the license when you close Visual Studio or when the 20-minute time-out period expires. |
Plug-ins for Visual Studio C#, Eclipse Java, Eclipse C/C++ and IntelliJ IDEA | Checks out a license when you run a Validate task, such as running an analysis (including C/C++ continuous analysis). Returns the license when you close Visual Studio or after 20 minutes of inactivity. In Eclipse, the license is returned after 20 minutes of inactivity, if Eclipse is closed or restarted, or if the user switches workspaces. |
kwcheck | Checks out a license when you run the command and returns it when the command completes. This command has no time-out period. |