clusterpoint/php-client-api-v4
Composer 安装命令:
composer require clusterpoint/php-client-api-v4
包简介
README 文档
README
Clusterpoint is a NoSQL document database known for its innovative Cloud-based distributed architecture, fast processing speed, and a flexible "pay as you use" pricing model. The database also features a developer-friendly API suitable for many popular modern programming languages, including PHP -- the specific API which is the focus of this document. Its full support for ACID-compliant transactions is a rarity among NoSQL databases, making the product useful for situations where data integrity is a must.
The recently introduced fourth edition of Clusterpoint added a unique JavaScript/SQL query language with computational capabilities,, allowing you to create powerful queries to store, retrieve, and transform data. The PHP API is flexible enough to allow you to use either interface methods or raw JS/SQL queries to accomplish your database tasks. The decision to use either approach ultimately depends on programmer preference and the individual development scenario.
Clusterpoint 4.x PHP Client API
Official Documentation
Documentation for the API can be found on the Clusterpoint website.
Requirements
PHP >= 5.4.0
cURL PHP Extension
Composer
Getting Started
- Sign up for Clusterpoint – Before you begin, you need to sign up for a Clusterpoint account and retrieve your Clusterpoint credentials.
- Minimum requirements – To run the PHP Client API, your system will need to meet the minimum requirements, including having **PHP >= 5.4.0 compiled with the cURL extension and cURL 4.0.2+.
- Install the API – Composer is the right way to install the PHP Client API.
composer require clusterpoint/php-client-api-v4 - Publish config file - this is optional step, you can pass access points during workflow, but this might make your development process easier.
php -r "copy('vendor/clusterpoint/php-client-api-v4/src/config.example', 'clusterpoint.php');" - Access – You can pass the credentials inside on
Clusterpoint\Clientclass construction, or use clusterpoint.php inside your project root folder, to manage your access points.
Quick Example
<?php require 'vendor/autoload.php'; // or if you installed api without composer: // require 'api_install_folder/Clusterpoint.php' use Clusterpoint\Client; //Initialize the service $cp = new Client([ 'host' => 'https://api-eu.clusterpoint.com/v4', 'account_id' => '1', 'username' => 'root', 'password' => 'password', 'debug' => true, ]); // Set the database.collection to initalize the query builder for it. $bikes = $cp->database("shop.bikes"); // Build your query $results = $bikes->where('color', 'red') ->where('availability', true) ->limit(5) ->groupBy('category') ->orderBy('price') ->select(['name', 'color', 'price', 'category']) ->get(); // Access your results echo "First bike price: ".$results[0]->price;
Support, Feature Requests & Bug Reports
- GitHub issues for bug reports and feature requests
- StackOverflow to ask questions (please make sure to use the clusterpoint tag)
- You can also send an e-mail to our support team at support@clusterpoint.com
License
Clusterpoint 4.x PHP Client API is open-sourced software licensed under the MIT license
clusterpoint/php-client-api-v4 适用场景与选型建议
clusterpoint/php-client-api-v4 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 2.85k 次下载、GitHub Stars 达 2, 最近一次更新时间为 2016 年 02 月 12 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「nosql」 「database」 「php」 「api」 「clusterpoint」 「jssql」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 clusterpoint/php-client-api-v4 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 clusterpoint/php-client-api-v4 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 clusterpoint/php-client-api-v4 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Dibi is Database Abstraction Library for PHP
The DreamFactory(tm) CouchDB Service.
Store your language lines in the database, yaml or other sources
The CodeIgniter Redis package
A package for automatically encrypting and decrypting Eloquent attributes in Laravel 5.5+, based on configuration settings.
Symfony lock Tarantool store
统计信息
- 总下载量: 2.85k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 14
- 依赖项目数: 2
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2016-02-12