phpcassa 介绍
phpcassa是为Apache Cassandra的一个PHP客户端库。
与Cassandra的0.7,0.8,1.0,和1.1兼容
可选C扩展以提高性能
phpcassa兼容PHP5.3+
示例代码:
$pool = new ConnectionPool('Keyspace1', array('localhost')); $users = new ColumnFamily($pool, 'Standard1'); $super = new SuperColumnFamily($pool, 'Super1'); $users->insert('key', array('column1' => 'value1', 'column2' => 'value2')); $users->get('key'); $users->multiget(array('key1', 'key2')); $users->remove('key1'); // removes whole row $users->remove('key1', 'column1'); // removes 'column1' $users->get_count('key1'); // counts the number of columns in row 'key1' $users->get_range('key1', 'key9'); // gets all rows with keys between '1' and '9'
phpcassa 官网
https://github.com/thobbs/phpcassa
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。