Age | Commit message (Collapse) | Author | Files | Lines |
|
- Previously, Process constants were used in a few locations throughout
the code. Capture the needed PRIORITY_CLASS constants in our local
Windows Process class, and also define CREATE_NEW_CONSOLE. These
constants have moved in new versions of the win32-process gem.
- Note that ext/windows/service/daemon.rb doesn't load Puppet code.
The daemon only loads what it explicitly needs, so ensure the
CREATE_NEW_CONSOLE constant is defined there.
|
|
Needs to be BELOW_NORMAL_PRIORITY_CLASS.
|
|
This commit adds a Puppet::Util::Limits module for specifying process
priority, and mixes the module into Puppet::Util::CommandLine. Since
the CommandLine is the application entry point for puppet it seemed
sensible to have it set the process priority there, and to have it done
as early as possible.
Another option would have been to set the priority in the base
Application, after the application-specific settings have been
initialized. But this would mean you couldn't set the process priority
when puppet executes an ExternalSubcommand-based application.
As it stands now, it's not possible to have different priorities for
different sections, e.g. agent vs master, in puppet's configuration
file.
|
|
This commit add a `:priority` type of setting that maps generic priority
labels to operating system specific priorities, e.g. normal priority is
0 on posix, but 32 on Windows.
If the value is specified as an integer, then it is passed as is, so
that specific priority levels can be specified.
This commit also adds the `priority` setting to the main section of
puppet's configuration.
|