File tree 5 files changed +10
-11
lines changed
lib/Phpfastcache/Drivers/Predis
5 files changed +10
-11
lines changed Original file line number Diff line number Diff line change 12
12
build :
13
13
dependencies :
14
14
override :
15
- - " composer require -W --ignore-platform-reqs phpfastcache/phpssdb:~1.1 predis/predis:~1.1 aws/aws-sdk-php:~3.2 google/cloud-firestore:~1.20 solarium/solarium:~6.1 "
15
+ - " composer require -W --ignore-platform-reqs phpfastcache/phpssdb:^1.2 predis/predis:^2.0 "
16
16
nodes :
17
17
analysis :
18
18
project_setup :
Original file line number Diff line number Diff line change 3
3
composer self-update
4
4
composer validate
5
5
composer install
6
- composer require -W phpfastcache/phpssdb:~ 1.2 predis/predis:~ 1.1
6
+ composer require -W phpfastcache/phpssdb:^ 1.2 predis/predis:^2.0
Original file line number Diff line number Diff line change 51
51
"ext-wincache" : " *" ,
52
52
"ext-leveldb" : " *" ,
53
53
"ext-couchbase" : " ^3.0" ,
54
- "predis/predis" : " ^1.1 " ,
54
+ "predis/predis" : " ^2.0 " ,
55
55
"phpfastcache/phpssdb" : " ~1.1.0" ,
56
56
"phpfastcache/arangodb-extension" : " ^9.2" ,
57
57
"phpfastcache/couchbasev4-extension" : " ^9.2" ,
Original file line number Diff line number Diff line change @@ -68,8 +68,8 @@ public function getHelp(): string
68
68
public function getStats (): DriverStatistic
69
69
{
70
70
$ info = $ this ->instance ->info ();
71
- $ size = (isset ( $ info ['Memory ' ]['used_memory ' ]) ? $ info [ ' Memory ' ][ ' used_memory ' ] : 0 );
72
- $ version = (isset ( $ info ['Server ' ]['redis_version ' ]) ? $ info [ ' Server ' ][ ' redis_version ' ] : 0 );
71
+ $ size = ($ info ['Memory ' ]['used_memory ' ] ?? 0 );
72
+ $ version = ($ info ['Server ' ]['redis_version ' ] ?? 0 );
73
73
$ date = (isset ($ info ['Server ' ]['uptime_in_seconds ' ]) ? (new DateTime ())->setTimestamp (time () - $ info ['Server ' ]['uptime_in_seconds ' ]) : 'unknown date ' );
74
74
75
75
return (new DriverStatistic ())
@@ -78,8 +78,9 @@ public function getStats(): DriverStatistic
78
78
->setSize ((int )$ size )
79
79
->setInfo (
80
80
sprintf (
81
- "The Redis daemon v%s is up since %s. \n For more information see RawData. \n Driver size includes the memory allocation size. " ,
81
+ "The Redis daemon v%s (with Predis v%s) is up since %s. \n For more information see RawData. \n Driver size includes the memory allocation size. " ,
82
82
$ version ,
83
+ PredisClient::VERSION ,
83
84
$ date ->format (DATE_RFC2822 )
84
85
)
85
86
);
@@ -93,7 +94,7 @@ public function getStats(): DriverStatistic
93
94
protected function driverConnect (): bool
94
95
{
95
96
/**
96
- * In case of an user-provided
97
+ * In case of a user-provided
97
98
* Predis client just return here
98
99
*/
99
100
if ($ this ->getConfig ()->getPredisClient () instanceof PredisClient) {
Original file line number Diff line number Diff line change @@ -8,14 +8,12 @@ parameters:
8
8
- '#PHPDoc tag @ (.*)#'
9
9
# Phpstan is not able to know the magic of Ssdb __call() implementation
10
10
- '#Call to an undefined method phpssdb (.*)#'
11
+
11
12
# Phpstan not differencing couchbase and couchbase_v3 stubs from jetbrains/phpstorm-stubs
12
13
-
13
14
message : ' #(Method|Class) Couchbase(.*)#'
14
15
path : lib/Phpfastcache/Drivers/Couchbasev3/Driver.php
15
- # Issue in predis/predis => https://github.com/predis/predis/pull/710
16
- -
17
- message : ' #Cannot call method getPayload\(\) on int#'
18
- path : lib/Phpfastcache/Drivers/Predis/Driver.php
16
+
19
17
# See https://github.com/phpstan/phpstan/issues/10315
20
18
-
21
19
message : ' #Dead catch - Phpfastcache\\Exceptions\\PhpfastcacheUnsupportedMethodException is never thrown in the try block.#'
You can’t perform that action at this time.
0 commit comments