mjpearson / Pandra

Cassandra abstraction layer and keyspace scaffolder for PHP developers --- ABANDONED.
GNU Lesser General Public License v3.0
93 stars 11 forks source link

Call to undefined method TBinaryProtocol #47

Open loretoparisi opened 14 years ago

loretoparisi commented 14 years ago

Unexpected behavior on getRangeKeys:

Fatal error: Call to undefined method TBinaryProtocol::BBBBM3„Š() in /.../pandra/lib/thrift/packages/cassandra/cassandra_types.php on line 1069

Code snippet:

  $res=PandraCore::getRangeKeys(
        'myNS',
        array('start'=>'','finish'=>''),
        new cassandra_ColumnParent(array(
            'column_family' => 'myCF',
        )),
    new PandraSlicePredicate(
        PandraSlicePredicate::TYPE_RANGE,
        array('start' => '',
            'finish' => '',
            'count' => '',
            'reversed' => false))
        );

Any idea?

loretoparisi commented 14 years ago

Same it happens when doing cf slices by the driver Pandra itself:

Stacktrace:

7 0.3672 1494792 PandraSuperColumnFamily->load( ) ../Tester.class.php:1172 8 0.3673 1497524 PandraCore::getCFSlice( ) ../SuperColumnFamily.class.php:174 9 0.3674 1498060 CassandraClient->get_slice( ) ../Core.class.php:664 10 0.3674 1498128 CassandraClient->send_get_slice( ) ../Cassandra.php:168 11 0.3675 1501424 cassandra_Cassandra_get_slice_args->write( ) ../Cassandra.php:188 12 0.3677 1501860 cassandra_SlicePredicate->write( ) ../Cassandra.php:1848 13 0.3677 1501860 cassandra_SliceRange->write( ) ../cassandra_types.php:1188

loretoparisi commented 14 years ago

I tried to update Pandra in order to use new

$keyRange = new cassandra_KeyRange(array(
        'start_key' => '', 'end_key' => '', 'count' => ''
    ));

$res = PandraCore::getRangeSlices(
        'myNS',
        $keyRange,
        new cassandra_ColumnParent(array(
            'column_family' => 'myCF',
        )),
        new PandraSlicePredicate(
            PandraSlicePredicate::TYPE_RANGE,
            array('start' => '',
                'finish' => '',
                'count' => '',
                'reversed' => false)));

No results out of this (new) range keys slice.