Skip to content

Regarding ConsumerOptions #26

@g41797

Description

@g41797

According to implementation

   public function setReceiveQueueSize(int $size)
    {
        if ($size <= 0) {
            $size = 1000;
        }
        $this->data[ self::RECEIVE_QUEUE_SIZE ] = $size;
    }

for $size == 0 actual 'RECEIVE_QUEUE_SIZE' will be 1000.

According to recommendations:
"...set the consumers' receiver queue size very low (potentially even to 0 if necessary)..."

I cannot override setReceiveQueueSize, because ConsumerOptions is final.

If you agree, I will create PR with fix, something like

   public function setReceiveQueueSize(int $size)
    {
        if ($size < 0)
        {
            $size = 1000;
        }
        $this->data[ self::RECEIVE_QUEUE_SIZE ] = $size;
    }

meanwhile I will use public $data directly

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions