It seems you are missing ip:port like:

cluster = HFactory.getOrCreateCluster("TestCluster", "localhost:9160");

 

If this doesn’t work please provide complete stack trace.

 

Regards

Harsh

 

From: Prakrati Agrawal [mailto:Prakrati.Agrawal@mu-sigma.com]
Sent: Tuesday, June 05, 2012 3:00 PM
To: user@cassandra.apache.org
Subject: RE: How to configure the Cassandra connection using Hector

 

cluster = HFactory.getCluster("Test Cluster");

keySpace = HFactory.createKeyspace("mstream", cluster);

 

These are the lines that I am executing and getting an error

 

Prakrati Agrawal | Developer - Big Data(I&D)| 9731648376 | www.mu-sigma.com

 

From: Harshvardhan Ojha [mailto:Harshvardhan.Ojha@makemytrip.com]
Sent: Tuesday, June 05, 2012 2:59 PM
To: user@cassandra.apache.org
Subject: RE: How to configure the Cassandra connection using Hector

 

Check if you have rightly provided your cluster name.

 

Regards

Harsh

 

From: Prakrati Agrawal [mailto:Prakrati.Agrawal@mu-sigma.com]
Sent: Tuesday, June 05, 2012 2:55 PM
To: user@cassandra.apache.org
Subject: How to configure the Cassandra connection using Hector

 

Dear all,

 

I am writing a java code using Hector but when I am configuring the already created key space using HFactory.createKeySpace its giving me the error Null Point Exception. What am I doing wrong. Please help me.

 

Thanks and Regards

Prakrati Agrawal | Developer - Big Data(I&D)| 9731648376 | www.mu-sigma.com

 

 


This email message may contain proprietary, private and confidential information. The information transmitted is intended only for the person(s) or entities to which it is addressed. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited and may be illegal. If you received this in error, please contact the sender and delete the message from your system.

Mu Sigma takes all reasonable steps to ensure that its electronic communications are free from viruses. However, given Internet accessibility, the Company cannot accept liability for any virus introduced by this e-mail or any attachment and you are advised to use up-to-date virus checking software.

 


This email message may contain proprietary, private and confidential information. The information transmitted is intended only for the person(s) or entities to which it is addressed. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited and may be illegal. If you received this in error, please contact the sender and delete the message from your system.

Mu Sigma takes all reasonable steps to ensure that its electronic communications are free from viruses. However, given Internet accessibility, the Company cannot accept liability for any virus introduced by this e-mail or any attachment and you are advised to use up-to-date virus checking software.