cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From DuyHai Doan <doanduy...@gmail.com>
Subject Re: Can I call getBytes on a text column to get the raw (already encoded UTF8)
Date Tue, 24 Jun 2014 05:23:48 GMT
Good idea, bytes are merely processed by the server so you're saving a lot
of Cpu. AFAIK getBytes should work fine.
Le 24 juin 2014 05:50, "Kevin Burton" <burton@spinn3r.com> a écrit :

> I'm building a webservice whereby I read the data from cassandra, then
> write it over the wire.
>
> It's going to push LOTS of content, and encoding/decoding performance has
> really bitten us in the future.  So I try to avoid transparent
> encoding/decoding if I can avoid it.
>
> So right now, I have a huge blob of text that's a 'text' column.
>
> Logically it *should* be text, because that's what it is...
>
> Can I just keep it as text so our normal tools work on it, but get it as
> raw UTF8 if I call getBytes?
>
> This way I can call getBytes and then send it right over the wire as
> pre-encoded UTF8 data.
>
> ... and of course the question is whether it will continue working in the
> future :-P
>
> I'll write a test of it of course but I wanted to see what you guys
> thought of this idea.
>
> --
>
> Founder/CEO Spinn3r.com
> Location: *San Francisco, CA*
> Skype: *burtonator*
> blog: http://burtonator.wordpress.com
> … or check out my Google+ profile
> <https://plus.google.com/102718274791889610666/posts>
> <http://spinn3r.com>
> War is peace. Freedom is slavery. Ignorance is strength. Corporations are
> people.
>
>

Mime
View raw message