Return-Path: X-Original-To: apmail-cassandra-user-archive@www.apache.org Delivered-To: apmail-cassandra-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 69C8210A3C for ; Tue, 24 Dec 2013 20:32:20 +0000 (UTC) Received: (qmail 72154 invoked by uid 500); 24 Dec 2013 20:32:17 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 72043 invoked by uid 500); 24 Dec 2013 20:32:16 -0000 Mailing-List: contact user-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@cassandra.apache.org Delivered-To: mailing list user@cassandra.apache.org Received: (qmail 72035 invoked by uid 99); 24 Dec 2013 20:32:16 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 24 Dec 2013 20:32:16 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of edlinuxguru@gmail.com designates 74.125.82.43 as permitted sender) Received: from [74.125.82.43] (HELO mail-wg0-f43.google.com) (74.125.82.43) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 24 Dec 2013 20:32:10 +0000 Received: by mail-wg0-f43.google.com with SMTP id k14so6271298wgh.10 for ; Tue, 24 Dec 2013 12:31:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=f/1T/DONWKc8nHF2Uvkyx9EmjRPnMwGlQcbl3YUbnWQ=; b=EfU2KomKBgJP914wQn5rhYThJq+3IhcPf85F6gRxDY45vIpslmOJSzPzuTYUgEUhDf VX4rLpgPaat8ub8JrR+aCLN6X+mCB6JtfWRUt6xwcYObmysapGr3iJwcjJTwLpfmw4nm B+fV+Abriui5L6P432o+r1bP/co0NpAavaDcgM+irRu8oCFxnNQXjxTXPjNBKS8Yayt4 doUxN1cb+fYW/06NVF2mj7hrjJJNoT2+b6DEZczCG7nMEhgZmYBliwsmFVMiX+AHXopT DcDuh7jXIX+YPWh3PpBABfBY852F3QIN1tUAWcmME8f35XKbjRkysRu/QhDzunnW4BYy BlJg== MIME-Version: 1.0 X-Received: by 10.194.243.170 with SMTP id wz10mr78467wjc.74.1387917109787; Tue, 24 Dec 2013 12:31:49 -0800 (PST) Received: by 10.194.220.105 with HTTP; Tue, 24 Dec 2013 12:31:49 -0800 (PST) Date: Tue, 24 Dec 2013 15:31:49 -0500 Message-ID: Subject: Cassandra unit testing becoming nearly impossible: suggesting alternative. From: Edward Capriolo To: "user@cassandra.apache.org" Content-Type: multipart/alternative; boundary=089e0149411a4e814e04ee4da2bf X-Virus-Checked: Checked by ClamAV on apache.org --089e0149411a4e814e04ee4da2bf Content-Type: text/plain; charset=ISO-8859-1 I am not sure there how many people have been around developing Cassandra for as long as I have, but the state of all the client libraries and the cassandra server is WORD_I_DONT_WANT_TO_SAY. Here is an example of something I am seeing: ERROR 14:59:45,845 Exception in thread Thread[Thrift:5,5,main] java.lang.AbstractMethodError: org.apache.thrift.ProcessFunction.isOneway()Z at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:51) at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39) at org.apache.cassandra.thrift.CustomTThreadPoolServer$WorkerProcess.run(CustomTThreadPoolServer.java:194) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:722) DEBUG 14:59:51,654 retryPolicy for schema_triggers is 0.99 In short: If you are new to cassandra and only using the newest client I am sure everything is peachy for you. For people that have been using Cassandra for a while it is harder to "jump ship" when something better comes along. You need sometimes to support both hector and astyanax, it happens. For a while I have been using hector. Even not to use hector as an API, but the one nice thing I got from hector was a simple EmbeddedServer that would clean up after itself. Hector seems badly broken at the moment. I have no idea how the current versions track with anything out there in the cassandra world. For a while I played with https://github.com/Netflix/astyanax, which has it's own version and schemes and dependent libraries. (astyanax has some packaging error that forces me into maven3) Enter cassandra 2.0 which forces you into java 0.7. Besides that it has it's own kit of things it seems to want. I am guessing since hectors embedded server does not work, and I should go to https://github.com/jsevellec/cassandra-unit not sure...really...how anyone does this anymore. I am sure I could dive into the source code and figure this out, but I would just rather have a stable piece of code that brings up the embedded server that "just works" and "continues working". I can not seem to get this working right either. (since it includes hector I see from the pom) Between thrift, cassandra,client x, it is almost impossible to build a sane classpath, and that is not even counting the fact that people have their own classpath issues (with guava mismatches etc). I think the only sane thing to do is start shipping cassandra-embedded like this: https://github.com/kstyrc/embedded-redis In other words package embedded-cassandra as a binary. Don't force the client/application developer to bring cassandra on the classpath and fight with mismatches in thrift/guava etc. That or provide a completely shaded cassandra server for embedded testing. As it stands now trying to support a setup that uses more than one client or works with multiple versions of cassandra is major pita. (aka library x compiled against 1.2.0 library y compiled against 2.0.3) Does anyone have any thoughts on this, or tried something similar? Edward --089e0149411a4e814e04ee4da2bf Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
I am not sure there how many people have been around = developing Cassandra for as long as I have, but the state of all the client= libraries and the cassandra server is WORD_I_DONT_WANT_TO_SAY.

Here is an example of something I am seeing:
ERROR= 14:59:45,845 Exception in thread Thread[Thrift:5,5,main]
java.lang.Abst= ractMethodError: org.apache.thrift.ProcessFunction.isOneway()Z
at org.a= pache.thrift.ProcessFunction.process(ProcessFunction.java:51)
at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
at= org.apache.cassandra.thrift.CustomTThreadPoolServer$WorkerProcess.run(Cust= omTThreadPoolServer.java:194)
at java.util.concurrent.ThreadPoolExecuto= r.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.j= ava:603)
at java.lang.Thread.run(Thread.java:722)
DEBUG 14:59:51,654= retryPolicy for schema_triggers is 0.99

In short:= If you are new to cassandra and only using the newest client I am sure eve= rything is peachy for you.

For people that have been using Cassandra for a while i= t is harder to "jump ship" when something better comes along. You= need sometimes to support both hector and astyanax, it happens.=A0

For a while I have been using hector. Even not to use h= ector as an API, but the one nice thing I got from hector was a simple Embe= ddedServer that would clean up after itself. Hector seems badly broken at t= he moment. I have no idea how the current versions track with anything out = there in the cassandra world.=A0

For a while I played with https://github.com/Netflix/astyanax, which has it= 9;s own version and schemes and dependent libraries. (astyanax has some pac= kaging error that forces me into maven3)

Enter cassandra 2.0 which forces you into java 0.7. Bes= ides that it has it's own kit of things it seems to want.=A0
=
I am guessing since hectors embedded server does not work, a= nd I should go to h= ttps://github.com/jsevellec/cassandra-unit not sure...really...how anyo= ne does this anymore. I am sure I could dive into the source code and figur= e this out, but I would just rather have a stable piece of code that brings= up the embedded server that "just works" and "continues wor= king".

I can not seem to get this working right either. (since= it includes hector I see from the pom)

Between th= rift, cassandra,client x, it is almost impossible to build a sane classpath= , and that is not even counting the fact that people have their own classpa= th issues (with guava mismatches etc).

I think the only sane thing to do is start shipping cas= sandra-embedded like this:

In other words package embedded-cassandra as a binary. Don&#= 39;t force the client/application developer to bring cassandra on the class= path and fight with mismatches in thrift/guava etc. That or provide a compl= etely shaded cassandra server for embedded testing. As it stands now trying= to support a setup that uses more than one client or works with multiple v= ersions of cassandra is major pita. =A0(aka library x compiled against 1.2.= 0 library y compiled against 2.0.3)

Does anyone have any thoughts on this, or tried somethi= ng similar? =A0

Edward

--089e0149411a4e814e04ee4da2bf--