summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--PHPINFO4
-rw-r--r--REFLECTION63
-rw-r--r--php-pecl-amqp.spec27
3 files changed, 76 insertions, 18 deletions
diff --git a/PHPINFO b/PHPINFO
index c4dcb7c..37c8854 100644
--- a/PHPINFO
+++ b/PHPINFO
@@ -1,8 +1,8 @@
amqp
-Version => 2.0.0
-Compiled => Aug 21 2023 @ 00:00:00
+Version => 2.1.0
+Compiled => Sep 7 2023 @ 00:00:00
AMQP protocol version => 0-9-1
librabbitmq version => 0.13.0
Default max channels per connection => 256
diff --git a/REFLECTION b/REFLECTION
index 5504ed9..58d5df0 100644
--- a/REFLECTION
+++ b/REFLECTION
@@ -1,4 +1,4 @@
-Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
+Extension [ <persistent> extension #125 amqp version 2.1.0 ] {
- INI {
Entry [ amqp.host <ALL> ]
@@ -79,12 +79,12 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
}
- Constants [32] {
- Constant [ string AMQP_EXTENSION_VERSION ] { 2.0.0 }
+ Constant [ string AMQP_EXTENSION_VERSION ] { 2.1.0 }
Constant [ int AMQP_EXTENSION_VERSION_MAJOR ] { 2 }
- Constant [ int AMQP_EXTENSION_VERSION_MINOR ] { 0 }
+ Constant [ int AMQP_EXTENSION_VERSION_MINOR ] { 1 }
Constant [ int AMQP_EXTENSION_VERSION_PATCH ] { 0 }
Constant [ string AMQP_EXTENSION_VERSION_EXTRA ] { }
- Constant [ int AMQP_EXTENSION_VERSION_ID ] { 20000 }
+ Constant [ int AMQP_EXTENSION_VERSION_ID ] { 20100 }
Constant [ int AMQP_NOPARAM ] { 0 }
Constant [ int AMQP_JUST_CONSUME ] { 1 }
Constant [ int AMQP_DURABLE ] { 2 }
@@ -113,7 +113,7 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
Constant [ int AMQP_DELIVERY_MODE_PERSISTENT ] { 2 }
}
- - Classes [15] {
+ - Classes [16] {
Class [ <internal:amqp> class AMQPException extends Exception implements Throwable, Stringable ] {
- Constants [0] {
@@ -1251,7 +1251,7 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
Property [ private array $arguments = [] ]
}
- - Methods [26] {
+ - Methods [27] {
Method [ <internal:amqp, ctor> public method __construct ] {
- Parameters [1] {
@@ -1405,6 +1405,14 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
- Return [ void ]
}
+ Method [ <internal:amqp> public method recover ] {
+
+ - Parameters [1] {
+ Parameter #0 [ <optional> bool $requeue = true ]
+ }
+ - Return [ void ]
+ }
+
Method [ <internal:amqp> public method purge ] {
- Parameters [0] {
@@ -2088,7 +2096,30 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
}
}
- Class [ <internal:amqp> final class AMQPTimestamp implements Stringable ] {
+ Interface [ <internal:amqp> interface AMQPValue ] {
+
+ - Constants [0] {
+ }
+
+ - Static properties [0] {
+ }
+
+ - Static methods [0] {
+ }
+
+ - Properties [0] {
+ }
+
+ - Methods [1] {
+ Method [ <internal:amqp> abstract public method toAmqpValue ] {
+
+ - Parameters [0] {
+ }
+ }
+ }
+ }
+
+ Class [ <internal:amqp> final class AMQPTimestamp implements Stringable, AMQPValue ] {
- Constants [2] {
Constant [ public float MAX ] { 1.844674407371E+19 }
@@ -2105,7 +2136,7 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
Property [ private float $timestamp ]
}
- - Methods [3] {
+ - Methods [4] {
Method [ <internal:amqp, ctor> public method __construct ] {
- Parameters [1] {
@@ -2126,10 +2157,16 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
}
- Return [ string ]
}
+
+ Method [ <internal:amqp, prototype AMQPValue> public method toAmqpValue ] {
+
+ - Parameters [0] {
+ }
+ }
}
}
- Class [ <internal:amqp> final class AMQPDecimal ] {
+ Class [ <internal:amqp> final class AMQPDecimal implements AMQPValue ] {
- Constants [4] {
Constant [ public int EXPONENT_MIN ] { 0 }
@@ -2149,7 +2186,7 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
Property [ private int $significand ]
}
- - Methods [3] {
+ - Methods [4] {
Method [ <internal:amqp, ctor> public method __construct ] {
- Parameters [2] {
@@ -2171,6 +2208,12 @@ Extension [ <persistent> extension #125 amqp version 2.0.0 ] {
}
- Return [ int ]
}
+
+ Method [ <internal:amqp, prototype AMQPValue> public method toAmqpValue ] {
+
+ - Parameters [0] {
+ }
+ }
}
}
}
diff --git a/php-pecl-amqp.spec b/php-pecl-amqp.spec
index 6bbc596..63fad4b 100644
--- a/php-pecl-amqp.spec
+++ b/php-pecl-amqp.spec
@@ -12,12 +12,13 @@
%{?scl:%scl_package php-pecl-amqp}
-%bcond_with tests
+%bcond_without tests
+%bcond_with server
%global with_zts 0%{!?_without_zts:%{?__ztsphp:1}}
%global pecl_name amqp
%global ini_name 40-%{pecl_name}.ini
-%global upstream_version 2.0.0
+%global upstream_version 2.1.0
#global upstream_prever RC1
%global upstream_lower %(echo %{upstream_prever} | tr '[:upper:]' '[:lower:]')
%global sources %{pecl_name}-%{upstream_version}%{?upstream_prever}
@@ -28,7 +29,7 @@
Summary: Communicate with any AMQP compliant server
Name: %{?scl_prefix}php-pecl-amqp
Version: %{upstream_version}%{?upstream_prever:~%{upstream_lower}}
-Release: 2%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
+Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
License: PHP-3.01
URL: https://pecl.php.net/package/amqp
Source0: https://pecl.php.net/get/%{pecl_name}-%{upstream_version}%{?upstream_prever}.tgz
@@ -39,7 +40,7 @@ BuildRequires: %{?scl_prefix}php-devel >= 7.4
BuildRequires: %{?scl_prefix}php-pear
BuildRequires: librabbitmq-devel >= 0.8.0
Requires: librabbitmq%{?_isa} >= %{buildver}
-%if %{with tests}
+%if %{with server}
BuildRequires: rabbitmq-server
BuildRequires: hostname
%endif
@@ -215,29 +216,38 @@ done
%endif
%if %{with tests}
+pushd %{sources}
+
+# online
+rm tests/amqpconnection_construct_with_connect_timeout.phpt
+
+%if %{with server}
mkdir log run base
: Launch the RabbitMQ service
export LANG=C.UTF-8
export RABBITMQ_PID_FILE=$PWD/run/pid
export RABBITMQ_LOG_BASE=$PWD/log
export RABBITMQ_MNESIA_BASE=$PWD/base
+export PHP_AMQP_HOST=localhost
/usr/lib/rabbitmq/bin/rabbitmq-server &>log/output &
/usr/lib/rabbitmq/bin/rabbitmqctl wait $RABBITMQ_PID_FILE
+%endif
ret=0
-pushd %{sources}
-
: Run the upstream test Suite for NTS extension
TEST_PHP_ARGS="-n -d extension=$PWD/../NTS/modules/%{pecl_name}.so" \
+SKIP_ONLINE_TESTS=1 \
REPORT_EXIT_STATUS=1 \
%{__php} -n run-tests.php -q -x -P --show-diff || ret=1
popd
+%if %{with server}
: Cleanup
if [ -s $RABBITMQ_PID_FILE ]; then
kill $(cat $RABBITMQ_PID_FILE)
fi
rm -rf log run base
+%endif
exit $ret
%endif
@@ -278,6 +288,11 @@ fi
%changelog
+* Thu Sep 7 2023 Remi Collet <remi@remirepo.net> - 2.1.0-1
+- update to 2.1.0
+- enable test suite
+- add option --with server to run full test suite
+
* Wed Aug 30 2023 Remi Collet <remi@remirepo.net> - 2.0.0-2
- rebuild for PHP 8.3.0RC1