CREATE TABLE `test`.`test` (
`keyid` varchar(45),
`value` varchar(45),
PRIMARY KEY (`keyid`)
) ENGINE=MyISAM DEFAULT CHARSET=cp1251
$port = 9998;
$hs = new HandlerSocket($host, $port);
$retval = $hs->executeInsert(0, array( '112233090' , '12212212' ));
var_dump($retval);
* This source code was highlighted with Source Code Highlighter .
bool(false);
bool(false);
mode=rd
mode=wr
loose_handlersocket_threads = 16
# the number of worker threads (for read requests)
loose_handlersocket_threads_wr = 1
# the number of worker threads (for write requests)
$host = 'localhost' ;
$port = 9998;
$port_wr = 9999;
$hs = new HandlerSocket($host, $port_ wr);
* This source code was highlighted with Source Code Highlighter .
telnet akalend.local 9998
tlnet: connect to address fe80::217:f2ff:feee:3a60: Connection refused
Trying 192.168.1.10...
Connected to akalend.local.
Escape character is '^]'.
P 0 test test PRIMARY keyid,value
0 1
0 = 1 123123
0 2 123123 asdasdasd
0 = 1 123123 0 0 D
2 1 readonly
telnet akalend.local 9998
tlnet: connect to address fe80::217:f2ff:feee:3a60: Connection refused
Trying 192.168.1.10...
Connected to akalend.local.
Escape character is '^]'.
P 0 test test PRIMARY keyid,value
0 1
0 = 1 123123
0 2 123123 asdasdasd
0 = 1 123123 0 0 D
2 1 readonly
telnet akalend.local 9999
Trying fe80::217:f2ff:feee:3a60...
telnet: connect to address fe80::217:f2ff:feee:3a60: Connection refused
Trying 192.168.1.10...
Connected to akalend.local.
Escape character is '^]'.
P 0 test test PRIMARY keyid,value
0 1
0 = 1 123123 1 0 D
0 1 1
0 + 2 1111 12345
0 1
Here, apparently, everything goes perfectly.bool(true)
noSql | set | get |
---|---|---|
HS | 33.4 | 24.6 * / 26.3 ** |
Mc | 16.7 | 15.6 |
Mcdb | 21.4 | 17.5 |
redis | 19.4 | 19.6 |
TokyoTr | 22.1 | 22,8 |
Source: https://habr.com/ru/post/113039/
All Articles