prolic / HumusAmqp

PHP 7.4 AMQP library
https://humusamqp.readthedocs.io/
MIT License
76 stars 17 forks source link

Make RPC-Client delivery mode configurable. #104

Open ghost opened 2 years ago

ghost commented 2 years ago

https://github.com/prolic/HumusAmqp/blob/7feace69bd981b6a12c6916fc33da8d34e3ffc47/src/JsonRpc/JsonRpcClient.php#L140

The delivery mode for RPC-Client messages is hardcoded set to 2. If there are no technical reasons, it would be advantageous to make this configurable.

Our use case is to send up to a few 1000 msg/sec. A RPC call should be handled immediately, so a message never remains more then a few millisec in the queue. To persist it, is a massive overhead for such a short lifetime and if the server restarts there is no use for old entries in the rpc queue because the tmp queue for delivering the result is also not persistant.

prolic commented 2 years ago

Feel free to submit a pull request

prolic commented 2 years ago

Can you submit a pull request?

On Tue, Aug 2, 2022, 10:28 Herbert Roth @.***> wrote:

https://github.com/prolic/HumusAmqp/blob/7feace69bd981b6a12c6916fc33da8d34e3ffc47/src/JsonRpc/JsonRpcClient.php#L140

The delivery mode for RPC-Client messages is hardcoded set to 2. If there are no technical reasons, it would be advantageous to make this configurable.

Our use case is to send up to a few 1000 msg/sec. A RPC call should be handled immediately, so a message never remains more then a few millisec in the queue. To persist it, is a massive overhead for such a short lifetime and if the server restarts there is no use for old entries in the rpc queue because the tmp queue for delivering the result is also not persistant.

— Reply to this email directly, view it on GitHub https://github.com/prolic/HumusAmqp/issues/104, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADAJPAHCIOXFRQAXXNVIILVXEV7NANCNFSM55LMB66Q . You are receiving this because you are subscribed to this thread.Message ID: @.***>