You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cassandra.apache.org by Nipuni Piyabasi Perera <ni...@gmail.com> on 2013/08/23 03:16:34 UTC
Secondary Index Storage
Hi,
I need to do a secondary index access improvement with a little
modification to Cassandra. I could see in [1], that the performance of
secondary index querying can be increased via splitting the column family
data and secondary index data.
Currently Cassandra saves keyspace data and secondary indices data in
"var/lib/cassandra/data/".
According to my understanding the data saves in the "data_file_directories"
location of conf/cassandra.yaml file. If I can enter new variable into
"cassandra.yaml" file and address it in the place where Cassandra stores
secondary indexes, this can be fixed.
Can anyone give some guidance regarding this improvement.
[1] https://issues.apache.org/jira/browse/CASSANDRA-5502
Thanks,
Nipuni
--
Nipuni Piyabasi Perera
Undergraduate
Department of Computer Science And Engineering
University of Moratuwa
Sri Lanka
Re: Secondary Index Storage
Posted by Dave Brosius <db...@mebigfatguy.com>.
the location is loaded from the
cassandra.yaml,
specifically the entry
data_file_directories
This is loaded into the class
Config.java
using 3rdparty library snakeyaml
On 08/23/2013 06:34 AM, Nipuni Piyabasi Perera wrote:
> Hi,
>
> Ok, so if I want to make it separate and test, where should I refer? From
> where the keyspace refer to the location "/var/lib/cassandra/data". I have
> debug the code, and could see some variables (e.g jdk location etc) can be
> accessed from :
>
> System.getProperty("");
>
> But this does not contain the disk location to keyspace.
>
> Thanks,
> Nipuni
>
>
> On Fri, Aug 23, 2013 at 9:52 AM, Jonathan Ellis <jb...@gmail.com> wrote:
>
>> Sorry, Aleksey pointed out that the index directory isn't separate from the
>> "parent" table. Probably so that we can snapshot them both together, which
>> is why the separate config in .yaml doesn't make sense either.
>>
>>
>> On Thu, Aug 22, 2013 at 11:07 PM, Jonathan Ellis <jb...@gmail.com>
>> wrote:
>>
>>> You can already symlink the index directory anywhere you like. I'm not
>>> convinced that special-casing indexes is a good approach in general vs
>>> looking at performance of all tables.
>>>
>>>
>>> On Thu, Aug 22, 2013 at 8:16 PM, Nipuni Piyabasi Perera <
>>> nipuni880917@gmail.com> wrote:
>>>
>>>> Hi,
>>>>
>>>> I need to do a secondary index access improvement with a little
>>>> modification to Cassandra. I could see in [1], that the performance of
>>>> secondary index querying can be increased via splitting the column
>> family
>>>> data and secondary index data.
>>>> Currently Cassandra saves keyspace data and secondary indices data in
>>>> "var/lib/cassandra/data/".
>>>> According to my understanding the data saves in the
>>>> "data_file_directories"
>>>> location of conf/cassandra.yaml file. If I can enter new variable into
>>>> "cassandra.yaml" file and address it in the place where Cassandra stores
>>>> secondary indexes, this can be fixed.
>>>>
>>>> Can anyone give some guidance regarding this improvement.
>>>>
>>>> [1] https://issues.apache.org/jira/browse/CASSANDRA-5502
>>>>
>>>> Thanks,
>>>> Nipuni
>>>>
>>>> --
>>>> Nipuni Piyabasi Perera
>>>> Undergraduate
>>>> Department of Computer Science And Engineering
>>>> University of Moratuwa
>>>> Sri Lanka
>>>>
>>>
>>>
>>> --
>>> Jonathan Ellis
>>> Project Chair, Apache Cassandra
>>> co-founder, http://www.datastax.com
>>> @spyced
>>>
>>
>>
>> --
>> Jonathan Ellis
>> Project Chair, Apache Cassandra
>> co-founder, http://www.datastax.com
>> @spyced
>>
>
>
Re: Secondary Index Storage
Posted by Nipuni Piyabasi Perera <ni...@gmail.com>.
Hi,
Ok, so if I want to make it separate and test, where should I refer? From
where the keyspace refer to the location "/var/lib/cassandra/data". I have
debug the code, and could see some variables (e.g jdk location etc) can be
accessed from :
System.getProperty("");
But this does not contain the disk location to keyspace.
Thanks,
Nipuni
On Fri, Aug 23, 2013 at 9:52 AM, Jonathan Ellis <jb...@gmail.com> wrote:
> Sorry, Aleksey pointed out that the index directory isn't separate from the
> "parent" table. Probably so that we can snapshot them both together, which
> is why the separate config in .yaml doesn't make sense either.
>
>
> On Thu, Aug 22, 2013 at 11:07 PM, Jonathan Ellis <jb...@gmail.com>
> wrote:
>
> > You can already symlink the index directory anywhere you like. I'm not
> > convinced that special-casing indexes is a good approach in general vs
> > looking at performance of all tables.
> >
> >
> > On Thu, Aug 22, 2013 at 8:16 PM, Nipuni Piyabasi Perera <
> > nipuni880917@gmail.com> wrote:
> >
> >> Hi,
> >>
> >> I need to do a secondary index access improvement with a little
> >> modification to Cassandra. I could see in [1], that the performance of
> >> secondary index querying can be increased via splitting the column
> family
> >> data and secondary index data.
> >> Currently Cassandra saves keyspace data and secondary indices data in
> >> "var/lib/cassandra/data/".
> >> According to my understanding the data saves in the
> >> "data_file_directories"
> >> location of conf/cassandra.yaml file. If I can enter new variable into
> >> "cassandra.yaml" file and address it in the place where Cassandra stores
> >> secondary indexes, this can be fixed.
> >>
> >> Can anyone give some guidance regarding this improvement.
> >>
> >> [1] https://issues.apache.org/jira/browse/CASSANDRA-5502
> >>
> >> Thanks,
> >> Nipuni
> >>
> >> --
> >> Nipuni Piyabasi Perera
> >> Undergraduate
> >> Department of Computer Science And Engineering
> >> University of Moratuwa
> >> Sri Lanka
> >>
> >
> >
> >
> > --
> > Jonathan Ellis
> > Project Chair, Apache Cassandra
> > co-founder, http://www.datastax.com
> > @spyced
> >
>
>
>
> --
> Jonathan Ellis
> Project Chair, Apache Cassandra
> co-founder, http://www.datastax.com
> @spyced
>
--
Nipuni Piyabasi Perera
Undergraduate
Department of Computer Science And Engineering
University of Moratuwa
Sri Lanka
Re: Secondary Index Storage
Posted by Jonathan Ellis <jb...@gmail.com>.
Sorry, Aleksey pointed out that the index directory isn't separate from the
"parent" table. Probably so that we can snapshot them both together, which
is why the separate config in .yaml doesn't make sense either.
On Thu, Aug 22, 2013 at 11:07 PM, Jonathan Ellis <jb...@gmail.com> wrote:
> You can already symlink the index directory anywhere you like. I'm not
> convinced that special-casing indexes is a good approach in general vs
> looking at performance of all tables.
>
>
> On Thu, Aug 22, 2013 at 8:16 PM, Nipuni Piyabasi Perera <
> nipuni880917@gmail.com> wrote:
>
>> Hi,
>>
>> I need to do a secondary index access improvement with a little
>> modification to Cassandra. I could see in [1], that the performance of
>> secondary index querying can be increased via splitting the column family
>> data and secondary index data.
>> Currently Cassandra saves keyspace data and secondary indices data in
>> "var/lib/cassandra/data/".
>> According to my understanding the data saves in the
>> "data_file_directories"
>> location of conf/cassandra.yaml file. If I can enter new variable into
>> "cassandra.yaml" file and address it in the place where Cassandra stores
>> secondary indexes, this can be fixed.
>>
>> Can anyone give some guidance regarding this improvement.
>>
>> [1] https://issues.apache.org/jira/browse/CASSANDRA-5502
>>
>> Thanks,
>> Nipuni
>>
>> --
>> Nipuni Piyabasi Perera
>> Undergraduate
>> Department of Computer Science And Engineering
>> University of Moratuwa
>> Sri Lanka
>>
>
>
>
> --
> Jonathan Ellis
> Project Chair, Apache Cassandra
> co-founder, http://www.datastax.com
> @spyced
>
--
Jonathan Ellis
Project Chair, Apache Cassandra
co-founder, http://www.datastax.com
@spyced
Re: Secondary Index Storage
Posted by Jonathan Ellis <jb...@gmail.com>.
You can already symlink the index directory anywhere you like. I'm not
convinced that special-casing indexes is a good approach in general vs
looking at performance of all tables.
On Thu, Aug 22, 2013 at 8:16 PM, Nipuni Piyabasi Perera <
nipuni880917@gmail.com> wrote:
> Hi,
>
> I need to do a secondary index access improvement with a little
> modification to Cassandra. I could see in [1], that the performance of
> secondary index querying can be increased via splitting the column family
> data and secondary index data.
> Currently Cassandra saves keyspace data and secondary indices data in
> "var/lib/cassandra/data/".
> According to my understanding the data saves in the "data_file_directories"
> location of conf/cassandra.yaml file. If I can enter new variable into
> "cassandra.yaml" file and address it in the place where Cassandra stores
> secondary indexes, this can be fixed.
>
> Can anyone give some guidance regarding this improvement.
>
> [1] https://issues.apache.org/jira/browse/CASSANDRA-5502
>
> Thanks,
> Nipuni
>
> --
> Nipuni Piyabasi Perera
> Undergraduate
> Department of Computer Science And Engineering
> University of Moratuwa
> Sri Lanka
>
--
Jonathan Ellis
Project Chair, Apache Cassandra
co-founder, http://www.datastax.com
@spyced