X7ROOT File Manager
Current Path:
/opt/alt/tests/alt-php84-pecl-memcached_3.2.0-2.el8/tests
opt
/
alt
/
tests
/
alt-php84-pecl-memcached_3.2.0-2.el8
/
tests
/
ðŸ“
..
📄
001.phpt
(183 B)
📄
add.phpt
(341 B)
📄
append.phpt
(651 B)
📄
bad_construct.phpt
(781 B)
📄
bad_construct_8.phpt
(701 B)
📄
bug_16084.phpt
(429 B)
📄
bug_16959.phpt
(1.25 KB)
📄
bug_17137.phpt
(921 B)
📄
bug_18639.phpt
(402 B)
📄
cachecallback.phpt
(1.18 KB)
📄
callback_exception.phpt
(903 B)
📄
callback_exception_2.phpt
(976 B)
📄
cas.phpt
(406 B)
📄
cas_multi.phpt
(1012 B)
📄
check_if_persistent.phpt
(795 B)
📄
check_if_pristine.phpt
(629 B)
📄
check_key.phpt
(3.75 KB)
📄
clone.phpt
(324 B)
📄
compression_types.phpt
(1.98 KB)
📄
conf_persist.phpt
(591 B)
📄
config.inc
(1.91 KB)
📄
construct.phpt
(154 B)
📄
construct_persistent.phpt
(447 B)
📄
default_behavior.phpt
(826 B)
📄
deleted.phpt
(435 B)
📄
deletemulti.phpt
(1.59 KB)
📄
deletemultitypes.phpt
(392 B)
📄
expire.phpt
(1.34 KB)
📄
flush_buffers.phpt
(545 B)
📄
get_flags.phpt
(1.13 KB)
📄
getdelayed.phpt
(1.12 KB)
📄
getmulti.phpt
(865 B)
📄
getserverbykey.phpt
(1023 B)
📄
getserverlist.phpt
(1012 B)
📄
gh_155.phpt
(1.2 KB)
📄
gh_21.phpt
(642 B)
📄
gh_500.phpt
(494 B)
📄
gh_77.phpt
(580 B)
📄
gh_90.phpt
(1.78 KB)
📄
gh_93.phpt
(863 B)
📄
incrdecr.phpt
(1.37 KB)
📄
incrdecr_64.phpt
(807 B)
📄
incrdecr_bykey.phpt
(1.39 KB)
📄
incrdecr_initial.phpt
(1.11 KB)
📄
incrdecr_invalid_key.phpt
(302 B)
📄
invalid_options.phpt
(356 B)
📄
invoke_callback.phpt
(540 B)
📄
invoke_callback_2.phpt
(1.48 KB)
📄
invoke_callback_twice.phpt
(357 B)
📄
keys_ascii.phpt
(3.18 KB)
📄
keys_binary.phpt
(3.26 KB)
📄
localserver.phpt
(322 B)
📄
memcachedserver.phpt
(2.84 KB)
📄
memcachedserver6.phpt
(2.72 KB)
📄
multi_order.phpt
(686 B)
📄
no-not-found.phpt
(470 B)
📄
options.phpt
(1.3 KB)
📄
pr_75.phpt
(644 B)
📄
prepend.phpt
(639 B)
📄
replace.phpt
(398 B)
📄
rescode.phpt
(1.78 KB)
📄
reset_keyprefix.phpt
(800 B)
📄
sasl_basic.phpt
(757 B)
📄
server.inc
(2.26 KB)
📄
server.php
(4.68 KB)
📄
session_badconf_emptyprefix.phpt
(629 B)
📄
session_badconf_locktime.phpt
(543 B)
📄
session_badconf_persistent.phpt
(662 B)
📄
session_badconf_prefix.phpt
(655 B)
📄
session_badconf_servers-php72.phpt
(771 B)
📄
session_badconf_servers.phpt
(698 B)
📄
session_basic.phpt
(706 B)
📄
session_basic2.phpt
(726 B)
📄
session_basic3.phpt
(735 B)
📄
session_lazy_warning.phpt
(1 KB)
📄
session_lock-php71.phpt
(1.58 KB)
📄
session_lock.phpt
(1.48 KB)
📄
session_persistent.phpt
(630 B)
📄
session_regenerate.phpt
(485 B)
📄
set_encoding_key2.phpt
(1 KB)
📄
set_large.phpt
(335 B)
📄
setmulti.phpt
(1.14 KB)
📄
setoptions.phpt
(1.05 KB)
📄
skipif.inc
(394 B)
📄
stats.phpt
(447 B)
📄
stats_hang.phpt
(2.17 KB)
📄
testdata.res
(4.76 KB)
📄
touch_binary.phpt
(1.85 KB)
📄
types.inc
(2.76 KB)
📄
types_igbinary.phpt
(451 B)
📄
types_igbinary_multi.phpt
(469 B)
📄
types_json.phpt
(437 B)
📄
types_json_multi.phpt
(455 B)
📄
types_msgpack.phpt
(501 B)
📄
types_msgpack_multi.phpt
(513 B)
📄
types_php.phpt
(348 B)
📄
types_php_multi.phpt
(360 B)
📄
undefined_set.phpt
(633 B)
📄
user-flags.phpt
(2.52 KB)
📄
vbucket.phpt
(627 B)
📄
vbucket_error_7.phpt
(1.03 KB)
📄
vbucket_error_8.phpt
(1.08 KB)
📄
version.phpt
(269 B)
Editing: server.php
<?php $server = new MemcachedServer(); $server->on (Memcached::ON_CONNECT, function ($remote_addr) { echo "Incoming connection from {$remote_addr}" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_ADD, function ($client_id, $key, $value, $flags, $expiration, &$cas) { echo "client_id=[$client_id]: Add key=[$key], value=[$value], flags=[$flags], expiration=[$expiration]" . PHP_EOL; $cas = 15; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_APPEND, function ($client_id, $key, $value, $cas, &$result_cas) { echo "client_id=[$client_id]: Append key=[$key], value=[$value], cas=[$cas]" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_PREPEND, function ($client_id, $key, $value, $cas, &$result_cas) { echo "client_id=[$client_id]: Prepend key=[$key], value=[$value], cas=[$cas]" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_INCREMENT, function ($client_id, $key, $delta, $initial, $expiration, &$result, &$result_cas) { echo "client_id=[$client_id]: Incrementing key=[$key], delta=[$delta], initial=[$initial], expiration=[$expiration]" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_DECREMENT, function ($client_id, $key, $delta, $initial, $expiration, &$result, &$result_cas) { echo "client_id=[$client_id]: Decrementing key=[$key], delta=[$delta], initial=[$initial], expiration=[$expiration]" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_DELETE, function ($client_id, $key, $cas) { echo "client_id=[$client_id]: Delete key=[$key], cas=[$cas]" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_FLUSH, function ($client_id, $when) { echo "client_id=[$client_id]: Flush when=[$when]" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_GET, function ($client_id, $key, &$value, &$flags, &$cas) { echo "client_id=[$client_id]: Get key=[$key]" . PHP_EOL; $value = "Hello to you client!"; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_NOOP, function ($client_id) { echo "client_id=[$client_id]: Noop" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_REPLACE, function ($client_id, $key, $value, $flags, $expiration, $cas, &$result_cas) { echo "client_id=[$client_id]: Replace key=[$key], value=[$value], flags=[$flags], expiration=[$expiration], cas=[$cas]" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_SET, function ($client_id, $key, $value, $flags, $expiration, $cas, &$result_cas) { echo "client_id=[$client_id]: Set key=[$key], value=[$value], flags=[$flags], expiration=[$expiration], cas=[$cas]" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_STAT, function ($client_id, $key, array &$values) { echo "client_id=[$client_id]: Stat key=[$key]" . PHP_EOL; if ($key === "scalar") { $values = "you want it, you get it"; } elseif ($key === "numeric array") { $values = [-1 => "one", "two", "three"]; } elseif ($key === "empty") { $values = []; } else { $values["key"] = $key; $values["foo"] = "bar"; } return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_VERSION, function ($client_id, &$value) { echo "client_id=[$client_id]: Version" . PHP_EOL; $value = "1.1.1"; return Memcached::RESPONSE_SUCCESS; }); $server->on (Memcached::ON_QUIT, function ($client_id) { echo "client_id=[$client_id]: Client quit" . PHP_EOL; return Memcached::RESPONSE_SUCCESS; }); $addr = ($_SERVER['argv'][1] ?? "127.0.0.1:3434"); echo "Listening on $addr" . PHP_EOL; $server->run($addr);
Upload File
Create Folder