src/Extender.php 1 location
|
@@ 324-330 (lines=7) @@
|
| 321 |
|
* |
| 322 |
|
* @return Extender $this |
| 323 |
|
*/ |
| 324 |
|
final public function setMaxChildsRuntime($time) { |
| 325 |
|
|
| 326 |
|
$this->max_childs_runtime = filter_var($time, FILTER_VALIDATE_INT, array("min_range" => 1, "default" => 300)); |
| 327 |
|
|
| 328 |
|
return $this; |
| 329 |
|
|
| 330 |
|
} |
| 331 |
|
|
| 332 |
|
/** |
| 333 |
|
* Get maximum time (in seconds) the parent will wait for child tasks to be completed (in miltithread mode) |
src/Comodojo/Extender/Base/Daemon.php 1 location
|
@@ 187-196 (lines=10) @@
|
| 184 |
|
|
| 185 |
|
} |
| 186 |
|
|
| 187 |
|
public static function getLoopTime($looptime) { |
| 188 |
|
|
| 189 |
|
return filter_var($looptime, FILTER_VALIDATE_INT, array( |
| 190 |
|
'options' => array( |
| 191 |
|
'default' => 1, |
| 192 |
|
'min_range' => 1 |
| 193 |
|
) |
| 194 |
|
)); |
| 195 |
|
|
| 196 |
|
} |
| 197 |
|
|
| 198 |
|
} |
| 199 |
|
|
src/Comodojo/Extender/Components/ProcessUtils.php 1 location
|
@@ 82-92 (lines=11) @@
|
| 79 |
|
|
| 80 |
|
} |
| 81 |
|
|
| 82 |
|
public static function filterNiceness($niceness=null) { |
| 83 |
|
|
| 84 |
|
return filter_var($niceness, FILTER_VALIDATE_INT, array( |
| 85 |
|
'options' => array( |
| 86 |
|
'default' => 0, |
| 87 |
|
'min_range' => -10, |
| 88 |
|
'max_range' => 10 |
| 89 |
|
) |
| 90 |
|
)); |
| 91 |
|
|
| 92 |
|
} |
| 93 |
|
|
| 94 |
|
} |
src/Comodojo/Extender/Jobs/Runner.php 1 location
|
@@ 63-72 (lines=10) @@
|
| 60 |
|
|
| 61 |
|
|
| 62 |
|
|
| 63 |
|
private static function getLaggerTimeout(Configuration $configuration) { |
| 64 |
|
|
| 65 |
|
return filter_var($configuration->get('child-lagger-timeout'), FILTER_VALIDATE_INT, array( |
| 66 |
|
'options' => array( |
| 67 |
|
'default' => 5, |
| 68 |
|
'min_range' => 0 |
| 69 |
|
) |
| 70 |
|
)); |
| 71 |
|
|
| 72 |
|
} |
| 73 |
|
|
| 74 |
|
} |
| 75 |
|
|