kallaspriit / Cassandra-PHP-Client-Library

Cassandra PHP-based client library for managing and querying your Cassandra cluster
http://cassandra-php-client-library.com
103 stars 25 forks source link

Unusable RowKey after $cassandra->set() #22

Closed skywaymsn closed 12 years ago

skywaymsn commented 12 years ago

After calling set() I get a RowKey name that is useless! Adding more columns in the same manner adds them to the same row so I'm thinking this must be an encoding problem, but who's?

    $cassandra->set(
        'SomeColumnFamily.ColAssetMetricGUID',
        array(
            'localhost::cpu_sys' => $myhost.'::localhost::cpu_sys'
        )
    );

[default@MyApp] list SomeColumnFamily; Using default limit of 100

Using default column limit of 100

RowKey: 436f6c41737365744d657472696347554944 => (column=localhost::cpu_sys, value=hostname::localhost::cpu_sys, timestamp=1346448764354892)

1 Row Returned. Elapsed time: 2 msec(s).

skywaymsn commented 12 years ago

Again, I was premature. Problem solved on my end.

kallaspriit commented 12 years ago

Good but what was the problem?

skywaymsn commented 12 years ago

I failed to assume key type :-) n00b error. My default display encoding was ASCII, but everything I had in Cassandra I did with UTF8.