1Test::AutoBuild::Stage:U:sSeertNCiocnet(r3i)buted Perl DToecsutm:e:nAtuattoiBounild::Stage::SetNice(3)
2
3
4
6 Test::AutoBuild::Stage::SetNice - Alter the scheduling priority of
7 builder
8
10 use Test::AutoBuild::Stage::SetNice
11
13 This module provides the ability to alter the scheduling priority of
14 the build process, typically lowering it to avoid monopolising all the
15 resources of the host machine. This is analogous to launching the
16 builder process through the nice(1) command.
17
19 In addition to the standard parameters defined by the Test::Auto‐
20 Build::Stage module, this module accepts one entry in the "options"
21 parameter:
22
23 nice-level
24 An integer in the range -20 (highest priority) to 19 (lowest prior‐
25 ity) indicating what schedular priority to give to the builder. NB,
26 typically you will be unable to set a priority less than zero,
27 since the builder does not run as root. If omitted, the default
28 value is 19 to ensure lowest priority is taken.
29
30 EXAMPLE
31
32 {
33 name = renice
34 label = Set Process Priority
35 module = Test::AutoBuild::Stage::SetNice
36 critical = 0
37 options = {
38 nice-level = 19
39 }
40 }
41
43 $stage->init(%params);
44 Override super class to initialize the default nice level if non
45 was specified. It is not neccesary to call this method since it is
46 called automatically by the "new" method.
47
48 $stage->process($runtime);
49 Attempt to change the priority of the builder process according to
50 the "nice-level" option. If unsuccessful, marks the stage as having
51 "failed". Since this is a recoverable error, it is usual to set
52 this stage as non-critical.
53
55 Daniel Berrange <dan@berrange.com> Dennis Gregorovic <dgre‐
56 gorovic@alum.mit.edu>
57
59 Copyright (C) 2004 Red Hat, Inc.
60
62 perl(1), Test::AutoBuild::Stage
63
64
65
66perl v5.8.8 2007-12-09Test::AutoBuild::Stage::SetNice(3)