On Tue, Apr 27, 2010 at 1:14 PM, David Boxenhorn <da...@lookin2.com> wrote:

> Thanks, Ran. Very nice to meet you!
>
:)

>
> Responses inline. Summary: I downloaded and unzipped Thrift and Hector. I
> included them in my project. What do I do now?
> On Tue, Apr 27, 2010 at 1:01 PM, Ran Tavory <ran...@gmail.com> wrote:
>
>> Hi David, I have a few questions (and answers), see inline
>>
>>  On Tue, Apr 27, 2010 at 12:49 PM, David Boxenhorn <da...@lookin2.com>wrote:
>>
>>>  Hi all,
>>>
>>> I'm trying to install a Cassandra development environment for Java. It is
>>> much harder than I thought it would be!!!!
>>>
>>> I got Cassandra up and running with the CLI. So now I'm trying to get the
>>> Java interface up.
>>>
>>> Thrift is installed, supposedly.
>>>
>> Installed? What did you install?
>> To use cassandra from the client side you only need some jars (cassandra
>> jar, and thrift jar iirc). No need to install something.
>>
>>
>
> I downloaded the Thrift and Hector jars and unzipped them. Do I have to do
> anything else? There's like a gazillion classes there, which are the top
> level classes that I care about?
>
If you work with an IDE you'll need to add the jars to your project's
classpath. With hector you'll need to unzip and add those:
apache-cassandra-0.6.0.jar   commons-codec-1.4.jar
 hector-0.6.0-11-sources.jar  libthrift-r917130.jar
 slf4j-api-1.5.8.jar
cassandra-javautils.jar      commons-pool-1.5.3.jar
hector-0.6.0-11.jar          log4j-1.2.14.jar
slf4j-log4j12-1.5.8.jar
clhm-production.jar          google-collections-1.0.jar   high-scale-lib.jar
          perf4j-0.9.12.jar
(half of them are only use for unit-tests, so they won't actually be loaded.
I have to clean up this mess a little bit...)

The fact that you're speaking in "classes" worries me. you should be
speaking in jars ;)

>
>
>>
>>> Basic questions (thanks in advance):
>>>
>>> 1. Is it easier to get Thrift or Hector up? I just want to get SOMETHING
>>> to work right now, even if it's not the best.
>>>
>> If you just need to get something really simple up then use thrift. Hector
>> isn't hard as well, just just requires you to download one more zip file and
>> add the jars to your classpath.
>> See http://wiki.apache.org/cassandra/ThriftExamples#Java
>>
>>
>
> I don't mind downloading another jar. In fact, my first try is with Hector
> - I was hoping that it would be an easier API.
>
If you need something fast and dirty then just copy-paste the code from the
apache wiki.
If you want to develop an application that live more than one day and has
some nice management and scaling features I'd suggest hector.

>
>
>>    2. Do I need Thrift for Hector?
>>>
>> You need to have thrift.jar in your classpath as well as cassandra.jar. If
>> you choose to use hector, there are a few more jars to add to the classpath,
>> see the ones from the lib folder here
>> http://github.com/downloads/rantav/hector/hector-0.6.0-11.zip
>>
>
>
> Done.
>
Sorry, in hector there's no lib folder, all jars are at the top-level

>
>
>>
>>
>>>  3. Is there any good documentation for working with Thrift and/or
>>> Hector???
>>>
>> here it is ;)
>>
>>>  4. I tried to use Hector and I'm getting the following, does anyone
>>> know what it means?
>>>
>> What program spits out this output?
>> Is this maven? If so, hector, although it uses maven, isn't published on a
>> public repo.
>>
>
> Yes, it's Maven (I think). So what do I do?
>
It boils down to the question of are you using an IDE to test and run? If
yes, you can forget about maven, this is the easiest usually. If you do want
to use maven to compile and run then that's also possible (that's what I do)
but you'll have to do some maven magic for that by adding the jars to the
system scope.

>
>

>
>>  To use hector you don't have to compile, just download the zip from here
>> http://github.com/downloads/rantav/hector/hector-0.6.0-11.zip
>>
>
> Done.
>
>
>>  If you do with to compile, both ant and mvn work.
>>
>>>
>>>
>>> 4/27/10 10:56:52 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (not open)
>>>
>>> me.prettyprint.cassandra.dao (not open)
>>>
>>> me.prettyprint.cassandra.jndi (not open)
>>>
>>> me (not open)
>>>
>>> me.prettyprint.cassandra.testutils (not open)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (not open)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (not open)
>>>
>>> 4/27/10 10:56:57 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 10:58:16 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 10:58:20 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 11:51:13 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 11:51:24 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 11:52:12 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 11:52:16 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 11:52:24 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 11:52:28 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 11:53:03 AM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>> 4/27/10 12:17:19 PM IDT: Can't find artifact for
>>> C:\Cassandra\hector-0.6.0-11\hector-0.6.0-11.jar
>>>
>>> <default> (...)
>>>
>>> me.prettyprint.cassandra.dao (...)
>>>
>>> me.prettyprint.cassandra.jndi (...)
>>>
>>> me (...)
>>>
>>> me.prettyprint.cassandra.testutils (...)
>>>
>>> me.prettyprint.cassandra.utils (...)
>>>
>>> me.prettyprint.cassandra (...)
>>>
>>> me.prettyprint.cassandra.service (...)
>>>
>>> me.prettyprint (...)
>>>
>>>
>>>
>>>
>>>
>>
>>
>

Reply via email to