Skip to content

KowalczykBartek/native-cassandra-streaming

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

wtf

This is ugly attemp to stream data from Apache Cassandra without external Java Driver (only Netty used - because Netty is cool !)

For now, it will perform just

SELECT * FROM SOMETABLE WHERE PARTITION=N;

and using page_state will try to stream entire data set from Cassandra (without driver of course).

Main purpose of this project is learning Netty(because Netty is cool !) and learn how to deal with memorry inside JVM, actually I am able to achive ~0.005sec pauses for minor gc and because netty produce almost no garbage, there is no problem with old gen collection.

2018-01-16T22:26:50.736-0100: [GC (Allocation Failure) [PSYoungGen: 655360K->320K(720896K)] 809663K->154631K(1007616K), 0.0051639 secs] [Times: user=0.02 sys=0.00, real=0.01 secs] 

2018-01-16T22:27:34.790-0100: [GC (Allocation Failure) [PSYoungGen: 655680K->352K(720896K)] 809991K->154671K(1007616K), 0.0049471 secs] [Times: user=0.02 sys=0.00, real=0.00 secs] 

how to run ?

Run Cassandra (expected localhost with port 9042 - so, default).
You can use Setup.java to create keyspace and table - this class will also put into Cassandra some record, next just run Server :

./gradlew -PmainClass=com.directstreaming.poc.Server execute

and connect via plain TCP, you can use telnet or included StreamingClient

./gradlew -PmainClass=com.utils.client.StreamingClient execute

links

https://github.com/apache/cassandra/blob/trunk/doc/native_protocol_v4.spec

Powered by

Releases

No releases published

Packages

No packages published

Languages