Pavlo Yatsukhnenko
9e504ede34
Set priority to 60
2025-01-02 14:40:59 -08:00
OHZEKI Naoki
5cad207637
Fix phpdoc type of '$pattern'
2025-01-02 12:11:49 -08:00
peter15914
43e6cab879
Fix potential NULL dereference
...
The return value of INI_STR() is always checked for NULL.
2025-01-02 11:34:52 -08:00
Bentley O'Kane-Chase
044b30386f
Reduce buffer size for signed integer, strlen(-9223372036854775808) = 20 + 1 for '\0'
2024-12-17 17:08:36 -08:00
Bentley O'Kane-Chase
35c5988027
Formatting improvements
2024-12-17 17:08:36 -08:00
Bentley O'Kane-Chase
138d07b67c
Print cursor as unsigned 64 bit integer
2024-12-17 17:08:36 -08:00
Jakub Onderka
f68544f703
Refactor and avoid allocation in rawcommand method
2024-12-10 09:52:35 -08:00
michael-grunder
42a427695e
Use defines for callback growth + sanity check
...
See #2595
2024-12-10 09:51:49 -08:00
Jakub Onderka
a551fdc94c
Switch from linked list to growing array for reply callbacks
...
Reduce allocation and deallocation count and also memory usage when using pipelining
2024-12-09 10:40:39 -08:00
Jakub Onderka
be38856205
Reuse redis_sock_append_auth method
...
In library.c, there are currently two methods for constructing AUTH command, so we can reuse code from redis_sock_append_auth also in redis_sock_auth_cmd method
2024-12-01 11:44:53 -08:00
Jakub Onderka
571ffbc8e0
Switch pipeline_cmd from smart_str to smart_string
...
As we don't need to extract zend_string from pipeline_cmd, we can use simple smart_string structure
2024-12-01 11:39:55 -08:00
Jakub Onderka
7895636a3a
Remove unused redis_debug_response method from library.c
2024-11-27 11:25:05 -08:00
Jakub Onderka
2434ba294c
Optimise HMGET method
...
Allocate output array to expected size and reuse already allocated string for output array keys
2024-11-27 10:33:42 -08:00
Jakub Onderka
aba09933db
Avoid unnecessary allocation in redis_hset_cmd
...
This will slightly reduce memory usage for HSET command
2024-11-26 18:28:09 -08:00
Jakub Onderka
4082dd07f7
Avoid unnecessary allocation in redis_hdel_cmd
...
This will slightly reduce memory usage for HDEL command
2024-11-26 18:28:09 -08:00
Jakub Onderka
99650e1545
Avoid unnecessary allocation in redis_key_varval_cmd
...
This will slightly reduce memory usage for commands like RPUSH, LPUSH, SADD, SREM, etc
2024-11-26 18:28:09 -08:00
Jakub Onderka
f6906470a5
Use zval_get_tmp_string method that is faster when provided zval is string
2024-11-26 18:28:09 -08:00
Jakub Onderka
2a2f908f2b
Optimise constructing Redis command string
...
Instead of snprintf method, use zend_print_long_to_buf that can be inlined
2024-11-26 17:20:11 -08:00
Jakub Onderka
5156e03202
If no command is issued in multi mode, return immutable empty array
2024-11-26 10:39:23 -08:00
Jakub Onderka
426de2bb71
Test for empty pipeline and multi
2024-11-26 10:39:23 -08:00
Jakub Onderka
400503b871
Optimise method array_zip_values_and_scores
...
Initialize array with know size and reuse already allocated keys
2024-11-26 10:39:23 -08:00
Jakub Onderka
83a19656f4
Faster parameter parsing in redis_key_cmd and redis_key_long_val_cmd
2024-11-26 10:39:23 -08:00
Jakub Onderka
3a2f3f45fc
Use immutable empty array in Redis::hKeys
2024-11-26 10:39:23 -08:00
Jakub Onderka
60b5a8860a
Use immutable empty array in Redis::exec
2024-11-26 10:39:23 -08:00
Jakub Onderka
64da891e6f
Do not allocate empty string or string with one character
...
From PHP 8, empty strings or string with one character don't need to be allocated. This change will reduce memory usage.
2024-11-26 10:39:23 -08:00
Jakub Onderka
99beb9221c
Initialize arrays with known size
...
We know in advance the array size, so it makes sense to avoid reallocation when adding new elements. Also use immutable empty array in when we know in advance that redis will return zero elements.
2024-11-26 10:39:23 -08:00
Jakub Onderka
b665925eed
Use smart str for constructing pipeline cmd
2024-11-25 09:41:27 -08:00
Pavlo Yatsukhnenko
6097e7ba50
Add PHP 8.4 to CI
2024-11-25 08:31:33 -08:00
michael-grunder
4cd3f59356
Implement KeyDB's EXPIREMEMBER[AT] commands
2024-11-15 08:59:10 -08:00
Jacob Brown
8144db3743
better documentation for the $tlsOptions parameter of RedisCluster
2024-11-04 17:29:03 -08:00
michael-grunder
0fe45d24d4
Fix XAUTOCLAIM argc when sending COUNT
...
Add 2 to argc not 1 + count when sending a specific COUNT.
2024-10-17 08:21:54 -07:00
michael-grunder
085d61ecfb
Create a strncmp wrapper
...
On some glibc implementations strncmp is a macro. This commit simply creates a
`redis_strncmp` static inline wrapper function so we can `ZEND_STRL` instead of
manually counting the length or using `sizeof(s)-1` each time.
Fixes #2565
2024-10-15 10:40:15 -07:00
michael-grunder
eb66fc9e2f
Pin ubuntu version for KeyDB
2024-10-15 10:40:15 -07:00
michael-grunder
985b0313fb
KeyDB doesn't have a noble release yet.
2024-10-14 14:00:21 -07:00
Pavlo Yatsukhnenko
a53bf38b83
Merge pull request #2557 from cmb69/cmb/win-ci
...
Windows CI: update setup-php-sdk to v0.10 and enable caching
2024-10-08 12:57:37 +03:00
michael-grunder
5419cc9c60
Prepare for 6.1.0 GA
6.1.0
2024-10-04 11:28:33 -07:00
Remi Collet
52e69edefd
improve package summary and description ( #2558 )
...
* improve package summary and description
* improve package summary and description
2024-10-03 11:06:56 -07:00
Christoph M. Becker
f89d4d8f6e
Windows CI: update setup-php-sdk to v0.10 and enable caching
2024-09-30 15:39:25 +02:00
Remi Collet
5f241d8913
Merge pull request #2555 from phpredis/issue-redis62
...
fix 2 tests with redis 6.2
2024-09-24 16:15:31 +02:00
Remi Collet
cc1be32294
fix 2 tests with redis 6.2
2024-09-24 14:47:04 +02:00
Vincent Langlet
0bae4bb044
Fix urls
2024-09-23 15:58:45 -07:00
Michael Grunder
909c5cc13c
Finalize 6.1.0RC2 changelog for completeness. ( #2554 )
...
* Finalize 6.1.0RC2 changelog for completeness.
* Fix CHANGELOG.md formatting + link to contributor users
6.1.0RC2
2024-09-23 13:56:48 -07:00
Remi Collet
bff3a22e9d
fix implicit nullable (8.4)
2024-09-23 11:08:56 -07:00
Remi Collet
30c8f90cd9
bump version
2024-09-23 11:08:56 -07:00
michael-grunder
9bd2aaace4
Prepare for 6.1.0RC2
2024-09-23 11:08:56 -07:00
James Titcumb
b59e35a64f
Added a composer.json to enable support for PIE
2024-09-20 09:03:11 -07:00
michael-grunder
a75a7e5a36
Fix SIGABRT in PHP 8.4
...
PHP switched from `ZEND_ASSUME` to `ZEND_ASSERT` when making sure
`Z_PTR_P(zv)` was nonnull in `zend_hash_str_update_ptr`.
This commit just switches to `zend_hash_str_add_empty_element` which
is semantically more correct anyway.
Fixes #2539
2024-09-19 22:41:28 -07:00
michael-grunder
9d38050093
Upload artifact v2 is deprecated
2024-09-19 14:51:09 -07:00
michael-grunder
40c897364f
Remove erroneously duplicated changelog entries.
...
When constructing the 6.1.0RC1 CHANGELOG.md and package.xml a few
commits from older releases were accidentally included.
See #2474
2024-08-06 17:57:10 -07:00
Remi Collet
37cebdd70b
cleanup code for unsupported versions
2024-08-05 08:58:58 -07:00