php-amqplib | The most widely used PHP client for RabbitMQ | Pub Sub library

 by   php-amqplib PHP Version: v3.5.3 License: LGPL-2.1

kandi X-RAY | php-amqplib Summary

kandi X-RAY | php-amqplib Summary

php-amqplib is a PHP library typically used in Messaging, Pub Sub, Docker, RabbitMQ applications. php-amqplib has no bugs, it has no vulnerabilities, it has a Weak Copyleft License and it has medium support. You can download it from GitHub.

The most widely used PHP client for RabbitMQ
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              php-amqplib has a medium active ecosystem.
              It has 4267 star(s) with 1009 fork(s). There are 162 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 7 open issues and 564 have been closed. On average issues are closed in 10 days. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of php-amqplib is v3.5.3

            kandi-Quality Quality

              php-amqplib has 0 bugs and 0 code smells.

            kandi-Security Security

              php-amqplib has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              php-amqplib code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              php-amqplib is licensed under the LGPL-2.1 License. This license is Weak Copyleft.
              Weak Copyleft licenses have some restrictions, but you can use them in commercial projects.

            kandi-Reuse Reuse

              php-amqplib releases are available to install and integrate.
              Installation instructions, examples and code snippets are available.
              php-amqplib saves you 2814 person hours of effort in developing the same functionality from scratch.
              It has 6359 lines of code, 536 functions and 59 files.
              It has high code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi has reviewed php-amqplib and discovered the below as its top functions. This is intended to give you an instant insight into php-amqplib implemented functionality, and help decide if they suit your requirements.
            • Read a value .
            • Write a value
            • Returns a hexadecimal representation of a string .
            • Connects to the AMQP server
            • Read data from the socket
            • Wait for new methods .
            • Serialize the properties .
            • Start a consumer
            • Sets a value .
            • Start consumer .
            Get all kandi verified functions for this library.

            php-amqplib Key Features

            No Key Features are available at this moment for php-amqplib.

            php-amqplib Examples and Code Snippets

            No Code Snippets are available at this moment for php-amqplib.

            Community Discussions

            QUESTION

            Azure Servicebus connection PHP
            Asked 2022-Mar-12 at 09:39

            I would like to connect with Azure Servicebus via PHP. The docs however from Microsoft itself are outdated and the libs mentioned and maintained by Microsoft are mostly abandoned.

            If i am correct the Azure Servicebus follows the AMQP protocol? I am trying to connect via AMQP itself to the servicebus but no succes at all.

            When i try to create a new connection with below an error is returned:

            ...

            ANSWER

            Answered 2022-Mar-12 at 09:39

            I am answering this question on my own since i came to the conclusion that there is actually not a valid answer available. The SDK from Microsoft has been abandoned and there is no actual PHP solution for this at this moment of writing.

            For me this means we will not consume the service but start using RabbitMQ instead.

            Source https://stackoverflow.com/questions/71000374

            QUESTION

            In Centos 7, how do you permanently consume messages with rabbitmq?
            Asked 2022-Jan-27 at 12:09

            Good day,

            I have just uploaded Symfony 3.4 project (PHP 7.2) to Centos server and my application needs to be connected to RabbitMQ. I want to do that in Centos server rabbitmq is constantly consuming messages. I know how to consume those messages temporarily by running this command: bin/console rabbitmq:consumer messaging . But how could permanently I consume the messages on server? I tried to google but didn't find any useful information

            In my application I've installed:

            "php-amqplib/php-amqplib": "*",

            "php-amqplib/rabbitmq-bundle": "*"

            UPDATE:

            I achieved my desired situation with the following command:

            nohup bin/console rabbitmq:consumer &

            ...

            ANSWER

            Answered 2022-Jan-26 at 15:36

            idk if there's an "official" way of doing it, but as with anything in Linux, you could just write a little daemon to do it, a minimum example would be to add this to your crontab -e

            Source https://stackoverflow.com/questions/70865799

            QUESTION

            Symfony RabbitMQ Bundle in AWS (managed service): Any way to get this working?
            Asked 2021-Jun-09 at 09:33

            We really tried a lot but it still can not get the Symfony RabbitMQ bundle (https://github.com/php-amqplib/RabbitMqBundle) running in AWS (with Docker). AWS only allows AMQPS and port 5671 to be opened in the AWS managed service.

            This is our current configuration in detail:

            ...

            ANSWER

            Answered 2021-Jun-09 at 09:33

            Finally solved - you have to define a custom AMQPChannel with a custom AMQPConnection with SSL options and then set this AMQPChannel to the producer:

            Source https://stackoverflow.com/questions/67890842

            QUESTION

            How to close rabbitmq connections from consumer callback using php-amqplib
            Asked 2021-May-21 at 15:14

            I have been able to set up a script that connects to RabbitMQ using the php-amqplib library. However, I want to be able to exit the script, if necessary.

            We thought that creating a stop.txt file would solve the problem. Basically, once a message is received, if the script sees that file, it must stop any further messages from being received, delete the file and exit the script.

            However, although it is deleting the file, it does not prevent further messages from being received, neither does it exit the script.

            As you can see I am using exactly the same function to exit the script as this official example uses: https://github.com/php-amqplib/php-amqplib/blob/master/demo/amqp_consumer.php. See line 54.

            Am I doing something wrong or not understanding something? I am a novice to this library.

            Here is the script I am working with. I have left parts out for brevity.

            ...

            ANSWER

            Answered 2021-May-21 at 15:13

            This seems to close everything off. I do not know whether it is the best solution. I basically close the channel and connection from within the callback.

            Source https://stackoverflow.com/questions/67623431

            QUESTION

            Composer 2.0.8 issue package-versions-deprecated
            Asked 2020-Dec-17 at 14:30

            Using php 7.2

            ...

            ANSWER

            Answered 2020-Dec-17 at 14:30

            This seems to be a problem with the virtual box filesystem. I created an issue to composer and hopefully more insight will be gained.

            https://github.com/composer/package-versions-deprecated/issues/21

            Source https://stackoverflow.com/questions/65149298

            QUESTION

            Class Sensio\Bundle\DistributionBundle\Composer\ScriptHandler is not autoloadable, can not call symfony-scripts script
            Asked 2020-Sep-29 at 19:06

            We have the below contents on composer.json with dependencies and scripts. This comes from a legacy project where the vendors directory was pushed to GitHub. We're trying to remove that vendors directory from the repository to make its creation a part of the build process.

            ...

            ANSWER

            Answered 2020-Sep-29 at 19:06

            I copied your composer.json to my local environment and ran composer update and had the same results. The problem is, that the class Sensio\Bundle\DistributionBundle\Composer\ScriptHandler does not exist with your config. So I executed composer require sensio/distribution-bundle, but then I got a version conflict:

            Source https://stackoverflow.com/questions/64125221

            QUESTION

            Laravel installation and create-project issue
            Asked 2020-Sep-15 at 16:55

            I was facing an issue to install laravel in my ubuntu. Please help me.

            ...

            ANSWER

            Answered 2020-Sep-15 at 16:55

            I used this and It works for me.

            Source https://stackoverflow.com/questions/63856646

            QUESTION

            ACCESS_REFUSED - Login was refused using authentication mechanism AMQPLAIN
            Asked 2020-Jul-14 at 13:33

            We got an error form laravel 7, when rabbitMQ Connection in server. The same server Laravel 5.8 working fine, We use same login details for both 5.8 and 7. But 7 version only we that issue

            ACCESS_REFUSED - Login was refused using the authentication mechanism AMQPLAIN. For details see the broker logfile.(0, 0) vendor/php-amqplib/php-amqplib/PhpAmqpLib/Connection/AbstractConnection.php:745

            ...

            ANSWER

            Answered 2020-Jul-14 at 13:33

            I Found the solution, This is an issue from .env file. Change name of login details from RABBITMQ_LOGIN to RABBITMQ_USER. it working fine.

            Source https://stackoverflow.com/questions/62888633

            QUESTION

            Problem connection from PHP to Apache ActiveMQ using AMQP
            Asked 2020-Jul-04 at 01:46

            I tried searching the web up and down - and either they point me towards RabbitMQ which is out of the question because the customer specifically asked for ActiveMQ / Amazon MQ which is basically ActiveMQ in the amazon cloud. Other results suggest using a different protocol (STOMP) - which I cant do because again the customer allows only the access via AMQP

            So I'm at a loss .. can you help me get going ? I tried with PHPamqplib but I get errors accessing the already running activeMQ broker "Invalid frame type 65 in ....AbstractConnection.php:571" during connection build up.

            ...

            ANSWER

            Answered 2020-Jul-04 at 01:46

            According to the README.md php-amqplib supports AMQP 0.9.1. However, ActiveMQ supports AMQP 1.0. Unfortunately the two protocols are not compatible. You'll need to find a PHP AMQP client which supports 1.0 if you want to communicate with ActiveMQ or Amazon MQ. According to this thread there are no plans to support AMQP 1.0 in php-amqplib.

            The amqpnetlite client supports AMQP 1.0 which is why it works with ActiveMQ.

            Source https://stackoverflow.com/questions/62717182

            QUESTION

            composer, show suggested packages
            Asked 2020-Apr-12 at 07:47

            When I run composer install the first time, or I add a new package, I see a list of suggested packages, for example:

            ...

            ANSWER

            Answered 2020-Apr-12 at 07:47

            From documentation composer suggests :

            Lists all packages suggested by currently installed set of packages. You can optionally pass one or multiple package names in the format of vendor/package to limit output to suggestions made by those packages only.

            Source https://stackoverflow.com/questions/61168117

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install php-amqplib

            Ensure you have composer installed, then run the following command:. That will fetch the library and its dependencies inside your vendor folder. Then you can add the following to your .php files in order to use the library.

            Support

            Starting with version 2.0 this library uses AMQP 0.9.1 by default and thus requires RabbitMQ 2.0 or later version. Usually server upgrades do not require any application code changes since the protocol changes very infrequently but please conduct your own testing before upgrading.
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/php-amqplib/php-amqplib.git

          • CLI

            gh repo clone php-amqplib/php-amqplib

          • sshUrl

            git@github.com:php-amqplib/php-amqplib.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular Pub Sub Libraries

            EventBus

            by greenrobot

            kafka

            by apache

            celery

            by celery

            rocketmq

            by apache

            pulsar

            by apache

            Try Top Libraries by php-amqplib

            RabbitMqBundle

            by php-amqplibPHP

            Thumper

            by php-amqplibPHP