// CFG: STACKER-CRUNCHER-TEST-UNIT-MAX-SIZE
$cfg->setConfigEntry('stacker_cruncher_test_unit_max_size', 20);
+// CFG: STACKER-OUTGOING-QUEUE-MAX-SIZE
+$cfg->setConfigEntry('stacker_outgoing_queue_max_size', 2000);
+
// CFG: CRUNCHER-TEST-UNIT-MAX-COUNT
$cfg->setConfigEntry('cruncher_test_unit_max_count', 1000);
$cfg->setConfigEntry('cruncher_virgin_state_class', 'CruncherVirginState');
// CFG: CRUNCHER-PER-UNIT-KEY-LIMIT
-$cfg->setConfigEntry('cruncher_per_unit_key_limit', 10000);
+$cfg->setConfigEntry('cruncher_per_unit_key_limit', 1000);
///////////////////////////////////////////////////////////////////////////////
// Chat Configuration
*/
protected function isInBufferQueueFilled () {
// Determine it
- $isFilled = ($this->bufferInstance->getStackCount('in_queue') > $this->getConfigInstance()->getConfigEntry('cruncher_in_buffer_min_threshold'));
+ $isFilled = ($this->bufferInstance->getStackCount(self::STACKER_NAME_IN_QUEUE) > $this->getConfigInstance()->getConfigEntry('cruncher_in_buffer_min_threshold'));
// And return the result
return $isFilled;
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-class CruncherUnitDatabaseWrapper extends BaseDatabaseWrapper implements UnitDatabaseWrapper {
+class CruncherUnitDatabaseWrapper extends BaseDatabaseWrapper implements UnitDatabaseWrapper, Registerable {
// Constants for database table names
const DB_TABLE_CRUNCHER_UNITS = 'cruncher_units';
* @param $configEntry Configuration entry where the limit is stored
* @return $isReached Whether the limit is reached
*/
- protected function isOutgoingQueueLimitReached($configEntry) {
+ protected function isOutgoingQueueLimitReached ($configEntry) {
return ($this->getConfigInstance()->getConfigEntry($configEntry) <= $this->getOutgoingQueueInstance()->getStackCount(self::STACKER_NAME_OUT_QUEUE));
}