By Bright Zheng (IT进行时)
1. About Apache Cassandra
Apache Cassandra is one of the
powerful NoSQL platforms.
Link: http://cassandra.apache.org/
Following are some useful
comparisons on some classic NoSQL platforms which we need to make a decision if
we want to get involved in such a domain.
1. Cassandra vs MongoDB vs
CouchDB vs Redis vs Riak vs HBase vs Membase vs Neo4j comparison: http://kkovacs.eu/cassandra-vs-mongodb-vs-couchdb-vs-redis
2. HBase vs Cassandra: http://blog.adku.com/2011/02/hbase-vs-cassandra.html
2. Development environment Setup
2.1. Software
required
SN
|
Name
|
Description
|
1
|
Apache
Cansandra
|
Mandatory.
Current stable version is 1.0.7
@http://cassandra.apache.org/download/
|
2
|
Cassandra
Tutorial
|
Mandatory.
Source code for following writeups.
@http://github.com/zznate/cassandra-tutorial.git
|
3
|
GIT
|
Optional.
Tools for latest source code download & sync
|
4
|
Maven
|
Optional.
I’m using 3.x, or 3.0.3 exactly.
|
5
|
Hactor
|
Optional.
Recommended Java client implementation for deeper learning experience since
it encapsulates all Cassandra’s Concepts/APIs as a higer layer Concepts/APIs.
|
2.2. Software
install & configuration
2.2.1. Apache Cassandra (as single node first)
Download & unzip, that’s
almost done.
Better to configure two files for
some runtime info (data/log/etc.).
1.
$APACHE_CASSANDRA$/conf/cassandra.yaml
cluster_name: 'Test Cluster'
#
directories where Cassandra should store data on disk.
data_file_directories:
- ../runtime/data
# commit
log
commitlog_directory:
../runtime/commitlog
# saved caches
saved_caches_directory:
../runtime/saved_caches
|
2.
$APACHE_CASSANDRA$/conf/log4j-server.properties
log4j.appender.R.File=../runtime/system.log
|
Double click $APACHE_CASSANDRA$/bin/cassandra.bat
to start Cassandra.
If you want to enable JMX for
runtime monitoring, please download MX4J from here and extract mx4j.jar and mx4j-tools.jar
to $APACHE_CASSANDRA$/lib and then
restart Cassandra.
One more thing you should
understand is that the JMX port will be defaulted to 8081 (Ref to the source
code here).
If you got port conflict issue, you have two ways to change the port.
1. Add a parameter to the start up bat (or $APACHE_CASSANDRA$/bin/cassandra.bat)
as -Dmx4jport=8082, or
2. Change the bat directly at following lines:
@REM original
@REM "%JAVA_HOME%\bin\java" %JAVA_OPTS% %CASSANDRA_PARAMS% -cp
%CASSANDRA_CLASSPATH% "%CASSANDRA_MAIN%"
@REM change to follwing
set mx4jport=7599
"%JAVA_HOME%\bin\java" %JAVA_OPTS% %CASSANDRA_PARAMS% -Dmx4jport=%mx4jport%
-cp %CASSANDRA_CLASSPATH% "%CASSANDRA_MAIN%"
2.2.2. Git & Maven
Omitted…
2.2.3. Cassandra Tutorial
1. Open Git Bash:
By double clicking the Git Bash
under Git install folder.
2. Download the source:
git clone
http://github.com/zznate/cassandra-tutorial.git
|
Note:
If your network is via proxy, run
follwing command first:
export
http_proxy={YOUR PROXY HOST/IP}:{PORT}
|
3. Import to Eclipse:
This is a maven project so we can
import it to Eclipse as existing Maven project.
2.2.4. Hactor
1. Open Git Bash:
By double clicking the Git Bash
under Git install folder.
2. Download the source:
git clone
http://github.com/rantav/hector.git
|
3. Import to Eclipse:
Hactor is a mavan project(s). So
we can import it to Eclipse as existing maven project.
It has 3 sub projects: core, orm
& test.
Take note that the orm sub
project is lack of javax.persistence dependency.
I added it as org.hibernate.javax.persistence:
hibernate-jpa-2.0-api.jar
TODO Items:
3. Samples Step by Step: By combining Concept Intro, CLI Usage & Sample Java Code
4. Clustering & Tuning: To evaluate Cassandra so-called Linear Scalability and proven Fault-tolerance
分享到:
相关推荐
通过学习《Learning Apache Cassandra 2015》这本书,我们不仅能够了解到Cassandra的基本概念和特性,还能深入了解如何使用Cassandra解决实际问题,包括如何设计表结构、组织数据以及执行高效查询等。此外,书中还...
在本文档中,标题“Learning_Apache_Cassandra”透露了内容的主题,即学习Apache Cassandra。Cassandra是一个开源的NoSQL分布式数据库管理系统,它以高可用性和分布式架构著称。该书详细介绍了Cassandra的基本概念、...
Learning Apache Cassandra - Second Edition by Sandeep Yarabarla English | 25 Apr. 2017 | ASIN: B01N52R0B5 | 360 Pages | AZW3 | 10.68 MB Key Features Install Cassandra and set up multi-node clusters ...
Spring Data for Apache Cassandra API。 Spring Data for Apache Cassandra 开发文档
### Apache Cassandra 掌控指南 #### 一、引言 在大数据时代,高效的数据存储与管理变得至关重要。《Mastering Apache Cassandra》这本书旨在帮助读者掌握 Apache Cassandra 的核心技术和最佳实践,使其能够在处理...
Title: Mastering Apache Cassandra, 2nd Edition Author: Nishant Neeraj Length: 322 pages Edition: 2 Language: English Publisher: Packt Publishing Publication Date: 2015-02-27 ISBN-10: 1784392618 ISBN-...
Apache Cassandra can be used by developers in Java, PHP, Python, and JavaScript—the primary and most commonly used languages. In Beginning Apache Cassandra Development, author and Cassandra expert ...
Apache Cassandra是一个分布式的NoSQL数据库管理系统,它被设计用来处理大量的数据跨越多个数据中心。Cassandra对高性能、高可用性、可扩展性有着出色的支持,因此它特别适合于那些需要不断增长和变化的数据集的应用...
Apache Cassandra is the most commonly used NoSQL database written in Java and is renowned in the industry as the only NoSQL solution that can accommodate the complex requirements of today’s modern ...
Cassandra(apache-cassandra-3.11.11-bin.tar.gz)是一套开源分布式NoSQL数据库系统。它最初由Facebook开发,用于储存收件箱等简单格式数据,集GoogleBigTable的数据模型与Amazon Dynamo的完全分布式的架构于一身...
Apache Cassandra是一个开源的分布式NoSQL数据库管理系统,它最初由Facebook开发,并在2008年被捐献给了Apache软件基金会。Cassandra旨在解决大规模数据存储的问题,特别适用于那些需要高性能、可伸缩性以及高可用性...
1. **分布式架构**:Cassandra 的核心特性是其分布式架构,它可以在多台服务器上分布数据,提供无单点故障的设计。这种架构使得Cassandra能够支持水平扩展,只需添加更多的节点就能增加存储容量和处理能力。 2. **...
CIS-Apache-Cassandra-3.11-Benchmark-v1.0.0.pdf IT 安全评估指南 CIS(Center for Internet Security)针对 Apache Cassandra 3.11 版本发布的安全评估 Benchmark 文档,旨在帮助用户和管理员对 Apache Cassandra...
Apache Cassandra is the perfect choice for building fault tolerant and scalable databases. Implementing Cassandra will enable you to take advantage of its features which include replication of data ...
适用于 Apache Cassandra 的 DataStax Python 驱动程序 Apache Cassandra 的 DataStax 驱动程序一个现代的、功能丰富且高度可调的 Python 客户端库,适用于 Apache Cassandra(2.1+)和 DataStax Enterprise(4.7+)...