Re: which driver to use with cassandra 3

2018-07-20 Thread Patrick McFadin
Vitaliy,

The DataStax Java driver is very actively maintained by a good size team
and a lot of great community contributors. It's version 3.x compatible and
even has some 4.x features starting to creep in. Support for virtual tables
(https://issues.apache.org/jira/browse/CASSANDRA-7622)  was just merged as
an example. Even the largest DataStax customers have a mix of enterprise +
OSS and we want to support them either way. Giving developers the most
consistent experience is part of that goal.

As for spring-data-cassandra, it does pull the latest driver as a part of
its own build, so you will already have it in your classpath. Spring adds
some auto-magic that you should be aware. The part you mentioned about the
schema management, is one to be careful with using. If you use it in dev,
it's not a huge problem. If it gets out to prod, you could potentially have
A LOT of concurrent schema changes happening which can lead to bad things.
Also, some of the spring API features such as findAll() can expose
typical c* anti-patterns such as "allow filtering" Just be aware of what
feature does what. And finally, another potential production problem is
that if you use a lot of keyspaces, Spring will instantiate a new Driver
Session object per keyspace which can lead to a lot of redundant connection
to the database. From the driver, a better way is to specify a keyspace per
query.

As you are using spring-data-cassandra, please share your experiences if
you can. There are a lot of developers that would benefit from some
real-world stories.

Patrick


On Fri, Jul 20, 2018 at 4:54 AM Vitaliy Semochkin 
wrote:

> Thank you very much Duy Hai Doan!
> I have relatively simple demands and since spring using datastax
> driver I can always get back to it,
> though  I would prefer to use spring in order to do bootstrapping and
> resource management for me.
> On Fri, Jul 20, 2018 at 4:51 PM DuyHai Doan  wrote:
> >
> > Spring data cassandra is so so ... It has less features (at last at the
> time I looked at it) than the default Java driver
> >
> > For driver, right now most of people are using Datastax's ones
> >
> > On Fri, Jul 20, 2018 at 3:36 PM, Vitaliy Semochkin 
> wrote:
> >>
> >> Hi,
> >>
> >> Which driver to use with cassandra 3
> >>
> >> the one that is provided by datastax, netflix or something else.
> >>
> >> Spring uses driver from datastax, though is it a reliable solution for
> >> a long term project, having in mind that datastax and cassandra
> >> parted?
> >>
> >> Regards,
> >> Vitaliy
> >>
> >> -
> >> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> >> For additional commands, e-mail: user-h...@cassandra.apache.org
> >>
> >
>
> -
> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> For additional commands, e-mail: user-h...@cassandra.apache.org
>
>


Re: which driver to use with cassandra 3

2018-07-20 Thread Andy Tolbert
Hi Vitaliy,

Spring uses driver from datastax, though is it a reliable solution for
> a long term project, having in mind that datastax and cassandra
> parted?
>

I would definitely consider the DataStax drivers a reliable solution going
forward.  We remain very committed to supporting our C* drivers at
DataStax.  We are actively working to stay on top of supporting C* 4.0
features and we intend that the 3.x driver will support C* 4.0.

We are also hard at work on our next major release of the java driver (4.0)
for which a beta release is imminent.  4.0 has some pretty big changes (see
here ) so
we intend to continue maintaining the 3.x line for quite a while.

Thanks,
Andy

On Fri, Jul 20, 2018 at 9:54 AM, Vitaliy Semochkin 
wrote:

> Thank you very much Duy Hai Doan!
> I have relatively simple demands and since spring using datastax
> driver I can always get back to it,
> though  I would prefer to use spring in order to do bootstrapping and
> resource management for me.
> On Fri, Jul 20, 2018 at 4:51 PM DuyHai Doan  wrote:
> >
> > Spring data cassandra is so so ... It has less features (at last at the
> time I looked at it) than the default Java driver
> >
> > For driver, right now most of people are using Datastax's ones
> >
> > On Fri, Jul 20, 2018 at 3:36 PM, Vitaliy Semochkin 
> wrote:
> >>
> >> Hi,
> >>
> >> Which driver to use with cassandra 3
> >>
> >> the one that is provided by datastax, netflix or something else.
> >>
> >> Spring uses driver from datastax, though is it a reliable solution for
> >> a long term project, having in mind that datastax and cassandra
> >> parted?
> >>
> >> Regards,
> >> Vitaliy
> >>
> >> -
> >> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> >> For additional commands, e-mail: user-h...@cassandra.apache.org
> >>
> >
>
> -
> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> For additional commands, e-mail: user-h...@cassandra.apache.org
>
>


Re: which driver to use with cassandra 3

2018-07-20 Thread Vitaliy Semochkin
Thank you very much Duy Hai Doan!
I have relatively simple demands and since spring using datastax
driver I can always get back to it,
though  I would prefer to use spring in order to do bootstrapping and
resource management for me.
On Fri, Jul 20, 2018 at 4:51 PM DuyHai Doan  wrote:
>
> Spring data cassandra is so so ... It has less features (at last at the time 
> I looked at it) than the default Java driver
>
> For driver, right now most of people are using Datastax's ones
>
> On Fri, Jul 20, 2018 at 3:36 PM, Vitaliy Semochkin  
> wrote:
>>
>> Hi,
>>
>> Which driver to use with cassandra 3
>>
>> the one that is provided by datastax, netflix or something else.
>>
>> Spring uses driver from datastax, though is it a reliable solution for
>> a long term project, having in mind that datastax and cassandra
>> parted?
>>
>> Regards,
>> Vitaliy
>>
>> -
>> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
>> For additional commands, e-mail: user-h...@cassandra.apache.org
>>
>

-
To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
For additional commands, e-mail: user-h...@cassandra.apache.org



Re: how to make cassandra listen not on 127.0.0.1 on 9042

2018-07-20 Thread Vitaliy Semochkin
Thank you very much for fast response Riccardo!
Setting rpc_interface to eth0 did the trick and now listen interface
works on eth0 as was specified.

PS
I wonder is it a bug or a feature?
E.g. I don't want to expose thrift rpc because all clients work via
CQL, why should I keep it exposed in order to expose cql 9042 port?
On Fri, Jul 20, 2018 at 4:25 PM Riccardo Ferrari  wrote:
>
> Hi,
>
> Have a look at the rcp_address description 
> http://cassandra.apache.org/doc/latest/configuration/cassandra_config_file.html?highlight=rpc_address#rpc-address.
>  what does your hostname resolves to?
>
> Best,
>
> On Fri, Jul 20, 2018 at 3:09 PM, Vitaliy Semochkin  
> wrote:
>>
>> Hi
>>
>> I'm building a cluster of cassandra RHEL 7
>> using cassandra 3.11.2 rpm
>>
>> I want cassandra to listen on 9042 on eth0 however
>> no matter what I do, it listens on 127.0.0.1
>> I tried to specify listen_address  instead but it doesn't work too.
>>
>> What am I missing?
>> How to make cassandra listen on 9042 other then 127.0.0.1?
>>
>> Regards,
>> Vitaliy
>>
>> -
>> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
>> For additional commands, e-mail: user-h...@cassandra.apache.org
>>
>

-
To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
For additional commands, e-mail: user-h...@cassandra.apache.org



Re: which driver to use with cassandra 3

2018-07-20 Thread Joseph Arriola
Hi Vitaly!

You can check
https://docs.datastax.com/en/developer/driver-matrix/doc/common/driverMatrix.html



2018-07-20 7:36 GMT-06:00 Vitaliy Semochkin :

> Hi,
>
> Which driver to use with cassandra 3
>
> the one that is provided by datastax, netflix or something else.
>
> Spring uses driver from datastax, though is it a reliable solution for
> a long term project, having in mind that datastax and cassandra
> parted?
>
> Regards,
> Vitaliy
>
> -
> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> For additional commands, e-mail: user-h...@cassandra.apache.org
>
>


Re: Timeout for only one keyspace in cluster

2018-07-20 Thread learner dba
 Anybody has any ideas about this? This is happening in production and we 
really need to fix it.
On Thursday, July 19, 2018, 10:41:59 AM CDT, learner dba 
 wrote:  
 
  Our foreignid is unique idetifier and we did check for wide partitions; 
cfhistorgrams show all partitions are evenly sized:

Percentile  SSTables     Write Latency      Read Latency    Partition Size      
  Cell Count

                              (micros)          (micros)           (bytes)      
            

50%             0.00             29.52              0.00              1916      
          12

75%             0.00             42.51              0.00              2299      
          12

95%             0.00             61.21              0.00              2759      
          14

98%             0.00             73.46              0.00              2759      
          17

99%             0.00             88.15              0.00              2759      
          17

Min             0.00              9.89              0.00               150      
           2

Max             0.00             88.15              0.00           7007506      
       42510
any thing else that we can check?
On Wednesday, July 18, 2018, 10:44:29 PM CDT, wxn...@zjqunshuo.com 
 wrote:  
 
 #yiv4986088840 body {line-height:1.5;}#yiv4986088840 blockquote 
{margin-top:0px;margin-bottom:0px;margin-left:0.5em;}#yiv4986088840 p 
{margin-top:0px;margin-bottom:0px;}#yiv4986088840 
div.yiv4986088840foxdiv20180719114102755131 {}#yiv4986088840 body 
{font-size:10.5pt;color:rgb(0, 0, 0);line-height:1.5;}Your partition key is 
foreignid. You may have a large partition. Why not use foreignid+timebucket as 
partition key?

 From: learner dbaDate: 2018-07-19 01:48To: User cassandra.apache.orgSubject: 
Timeout for only one keyspace in clusterHi,
We have a cluster with multiple keyspaces. All queries are performing good but 
write operation on few tables in one specific keyspace gets write timeout. 
Table has counter column and counter update query times out always. Any idea?

CREATE TABLE x.y (

    foreignid uuid,

    timebucket text,

    key text,

    timevalue int,

    value counter,

    PRIMARY KEY (foreignid, timebucket, key, timevalue)

) WITH CLUSTERING ORDER BY (timebucket ASC, key ASC, timevalue ASC)

    AND bloom_filter_fp_chance = 0.01

    AND caching = {'keys': 'ALL', 'rows_per_partition': 'NONE'}

    AND comment = ''

    AND compaction = {'class': 
'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy', 
'max_threshold': '32', 'min_threshold': '4'}

    AND compression = {'chunk_length_in_kb': '64', 'class': 
'org.apache.cassandra.io.compress.LZ4Compressor'}

    AND crc_check_chance = 1.0

    AND dclocal_read_repair_chance = 0.1

    AND default_time_to_live = 0

    AND gc_grace_seconds = 864000

    AND max_index_interval = 2048

    AND memtable_flush_period_in_ms = 0

    AND min_index_interval = 128

    AND read_repair_chance = 0.0

    AND speculative_retry = '99PERCENTILE';

Query and Error:
UPDATE x.y SET value = value + 1 where foreignid = ? AND timebucket = ? AND key 
= ? AND timevalue = ?, err = {s:\"gocql: no response 
received from cassandra within timeout period
I verified CL=local_serialWe had been working on this issue for many days; any 
help will be much appreciated.




Re: which driver to use with cassandra 3

2018-07-20 Thread DuyHai Doan
Spring data cassandra is so so ... It has less features (at last at the
time I looked at it) than the default Java driver

For driver, right now most of people are using Datastax's ones

On Fri, Jul 20, 2018 at 3:36 PM, Vitaliy Semochkin 
wrote:

> Hi,
>
> Which driver to use with cassandra 3
>
> the one that is provided by datastax, netflix or something else.
>
> Spring uses driver from datastax, though is it a reliable solution for
> a long term project, having in mind that datastax and cassandra
> parted?
>
> Regards,
> Vitaliy
>
> -
> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> For additional commands, e-mail: user-h...@cassandra.apache.org
>
>


which driver to use with cassandra 3

2018-07-20 Thread Vitaliy Semochkin
Hi,

Which driver to use with cassandra 3

the one that is provided by datastax, netflix or something else.

Spring uses driver from datastax, though is it a reliable solution for
a long term project, having in mind that datastax and cassandra
parted?

Regards,
Vitaliy

-
To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
For additional commands, e-mail: user-h...@cassandra.apache.org



Re: how to make cassandra listen not on 127.0.0.1 on 9042

2018-07-20 Thread Riccardo Ferrari
Hi,

Have a look at the rcp_address description
http://cassandra.apache.org/doc/latest/configuration/cassandra_config_file.html?highlight=rpc_address#rpc-address.
what does your hostname resolves to?

Best,

On Fri, Jul 20, 2018 at 3:09 PM, Vitaliy Semochkin 
wrote:

> Hi
>
> I'm building a cluster of cassandra RHEL 7
> using cassandra 3.11.2 rpm
>
> I want cassandra to listen on 9042 on eth0 however
> no matter what I do, it listens on 127.0.0.1
> I tried to specify listen_address  instead but it doesn't work too.
>
> What am I missing?
> How to make cassandra listen on 9042 other then 127.0.0.1?
>
> Regards,
> Vitaliy
>
> -
> To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
> For additional commands, e-mail: user-h...@cassandra.apache.org
>
>


how to make cassandra listen not on 127.0.0.1 on 9042

2018-07-20 Thread Vitaliy Semochkin
Hi

I'm building a cluster of cassandra RHEL 7
using cassandra 3.11.2 rpm

I want cassandra to listen on 9042 on eth0 however
no matter what I do, it listens on 127.0.0.1
I tried to specify listen_address  instead but it doesn't work too.

What am I missing?
How to make cassandra listen on 9042 other then 127.0.0.1?

Regards,
Vitaliy

-
To unsubscribe, e-mail: user-unsubscr...@cassandra.apache.org
For additional commands, e-mail: user-h...@cassandra.apache.org