PHPackages                             silantifross/phpcassa - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. silantifross/phpcassa

ActiveLibrary[Database &amp; ORM](/categories/database)

silantifross/phpcassa
=====================

PHP Cassandra Library

v2.0.0(1y ago)041MITShellPHP &gt;=8.1

Since Dec 27Pushed 1y agoCompare

[ Source](https://github.com/SilantiFross/phpcassa)[ Packagist](https://packagist.org/packages/silantifross/phpcassa)[ Docs](https://github.com/thobbs/phpcassa)[ RSS](/packages/silantifross-phpcassa/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

phpcassa
========

[](#phpcassa)

phpcassa is a PHP client library for [Apache Cassandra](http://cassandra.apache.org).

- Compatible with Cassandra 0.7 through 1.2
- Optional C extension for improved performance

This fork of phpcassa is compatible with PHP 8.1+

phpcassa is open source under the [MIT license](http://www.opensource.org/licenses/mit-license.php).

Documentation
-------------

[](#documentation)

While this README includes some useful information, the official and more thorough documentation can be found here:

Examples
--------

[](#examples)

You can find a few fully working example scripts in the `examples/` directory.

### Opening Connections

[](#opening-connections)

```
$pool = new ConnectionPool('Keyspace1');
```

or

```
$pool = new ConnectionPool('Keyspace1', array('localhost'));
```

### Create a column family object

[](#create-a-column-family-object)

```
$users = new ColumnFamily($pool, 'Standard1');
$super = new SuperColumnFamily($pool, 'Super1');
```

### Inserting

[](#inserting)

```
$users->insert('key', array('column1' => 'value1', 'column2' => 'value2'));
```

### Querying

[](#querying)

```
$users->get('key');
$users->multiget(array('key1', 'key2'));
```

### Removing

[](#removing)

```
$users->remove('key1'); // removes whole row
$users->remove('key1', 'column1'); // removes 'column1'
```

### Other

[](#other)

```
$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'
```

Using the C Extension
---------------------

[](#using-the-c-extension)

The C extension is crucial for phpcassa's performance.

You need to configure and make to be able to use the C extension.

*Note*: if `checkinstall` is available, run `sudo checkinstall` in place of `sudo make install`.

```
cd ext/thrift_protocol
phpize
./configure
make
sudo make install
```

Add the following line to your php.ini file:

```
extension=thrift_protocol.so

```

Getting Help
------------

[](#getting-help)

- Mailing list: [phpcassa on google groups](http://groups.google.com/group/phpcassa)
- IRC: Channel #cassandra on irc.freenode.net

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance40

Moderate activity, may be stable

Popularity8

Limited adoption so far

Community16

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 80% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

508d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/a6378a10f500eba602712961f6dc21e925aed81bb0b1c20ffa87944cefe95090?d=identicon)[happySisyphus](/maintainers/happySisyphus)

---

Top Contributors

[![thobbs](https://avatars.githubusercontent.com/u/355580?v=4)](https://github.com/thobbs "thobbs (361 commits)")[![hoan](https://avatars.githubusercontent.com/u/71050?v=4)](https://github.com/hoan "hoan (38 commits)")[![ricardclau](https://avatars.githubusercontent.com/u/613725?v=4)](https://github.com/ricardclau "ricardclau (21 commits)")[![mcd-php](https://avatars.githubusercontent.com/u/3469206?v=4)](https://github.com/mcd-php "mcd-php (9 commits)")[![udat](https://avatars.githubusercontent.com/u/437040?v=4)](https://github.com/udat "udat (4 commits)")[![maxwheeler](https://avatars.githubusercontent.com/u/768720?v=4)](https://github.com/maxwheeler "maxwheeler (3 commits)")[![Maescool](https://avatars.githubusercontent.com/u/197110?v=4)](https://github.com/Maescool "Maescool (3 commits)")[![lafka](https://avatars.githubusercontent.com/u/287792?v=4)](https://github.com/lafka "lafka (3 commits)")[![karlhiramoto](https://avatars.githubusercontent.com/u/22713?v=4)](https://github.com/karlhiramoto "karlhiramoto (2 commits)")[![winglian](https://avatars.githubusercontent.com/u/381258?v=4)](https://github.com/winglian "winglian (1 commits)")[![oberman](https://avatars.githubusercontent.com/u/971773?v=4)](https://github.com/oberman "oberman (1 commits)")[![portsnap](https://avatars.githubusercontent.com/u/81493?v=4)](https://github.com/portsnap "portsnap (1 commits)")[![SilantiFross](https://avatars.githubusercontent.com/u/9060566?v=4)](https://github.com/SilantiFross "SilantiFross (1 commits)")[![uCrypTex](https://avatars.githubusercontent.com/u/2658801?v=4)](https://github.com/uCrypTex "uCrypTex (1 commits)")[![wajamjenkins](https://avatars.githubusercontent.com/u/7011770?v=4)](https://github.com/wajamjenkins "wajamjenkins (1 commits)")[![CoolCold](https://avatars.githubusercontent.com/u/316482?v=4)](https://github.com/CoolCold "CoolCold (1 commits)")

---

Tags

cassandra

### Embed Badge

![Health badge](/badges/silantifross-phpcassa/health.svg)

```
[![Health](https://phpackages.com/badges/silantifross-phpcassa/health.svg)](https://phpackages.com/packages/silantifross-phpcassa)
```

###  Alternatives

[doctrine/orm

Object-Relational-Mapper for PHP

10.2k285.3M6.2k](/packages/doctrine-orm)[phpfastcache/phpfastcache

PHP Abstract Cache Class - Reduce your database call using cache system. Phpfastcache handles a lot of drivers such as Apc(u), Cassandra, CouchBase, Couchdb, Dynamodb, Firestore, Mongodb, Files, (P)redis, Leveldb, Memcache(d), Ravendb, Ssdb, Sqlite, Wincache, Xcache, Zend Data Cache.

2.4k5.0M130](/packages/phpfastcache-phpfastcache)[datastax/php-driver

DataStax PHP Driver for Apache Cassandra

437521.5k19](/packages/datastax-php-driver)[cubettech/lacassa

Cassandra based query builder for laravel.

358.5k](/packages/cubettech-lacassa)[mroosz/php-cassandra

A pure-PHP client for Apache Cassandra and ScyllaDB with support for CQL binary protocol v3, v4 and v5 (Cassandra 2.1+ incl. 3.x-5.x; ScyllaDB 6.2 and 2025.x), synchronous and asynchronous APIs, prepared statements, batches, result iterators, object mapping, SSL/TLS, and LZ4 compression.

205.6k2](/packages/mroosz-php-cassandra)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
