PHPackages                             hendrahuang/cassandra-bundle - 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. hendrahuang/cassandra-bundle

ActiveSymfony-bundle[Database &amp; ORM](/categories/database)

hendrahuang/cassandra-bundle
============================

Symfony2 / Symfony 3 bundle on top of datastax/php-driver

v1.8.0(7y ago)83.3k10[1 PRs](https://github.com/Hendra-Huang/CassandraBundle/pulls)MITPHPPHP &gt;=5.5.9

Since Dec 13Pushed 6y ago5 watchersCompare

[ Source](https://github.com/Hendra-Huang/CassandraBundle)[ Packagist](https://packagist.org/packages/hendrahuang/cassandra-bundle)[ RSS](/packages/hendrahuang-cassandra-bundle/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (8)Dependencies (5)Versions (10)Used By (0)

CassandraBundle
===============

[](#cassandrabundle)

The CassandraBundle provide a Cassandra EntityManager as a Symfony service.

Installation
------------

[](#installation)

**NOTE :** You need to [install the offical datastax php driver extension](https://github.com/datastax/php-driver)

Install the bundle :

```
$ composer require hendrahuang/cassandra-bundle
```

Register the bundle in your kernel :

```
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        new CassandraBundle\CassandraBundle(),
    );
}
```

Example Usage
-------------

[](#example-usage)

Add the `cassandra` section in your configuration file. Here is the minimal configuration required.

```
# app/config/config.yml

cassandra:
    connections:
        default:
            keyspace: "mykeyspace"
            hosts:
                - 127.0.0.1
                - 127.0.0.2
                - 127.0.0.3
            user: ''
            password: ''
```

```
# app/config/config_prod.yml

cassandra:
    dispatch_events: false
```

Create entity for cassandra schema :

```
