Return-Path: Delivered-To: apmail-incubator-cassandra-user-archive@minotaur.apache.org Received: (qmail 12016 invoked from network); 9 Apr 2009 21:25:14 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 9 Apr 2009 21:25:14 -0000 Received: (qmail 61917 invoked by uid 500); 9 Apr 2009 21:25:14 -0000 Delivered-To: apmail-incubator-cassandra-user-archive@incubator.apache.org Received: (qmail 61881 invoked by uid 500); 9 Apr 2009 21:25:14 -0000 Mailing-List: contact cassandra-user-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: cassandra-user@incubator.apache.org Delivered-To: mailing list cassandra-user@incubator.apache.org Received: (qmail 61872 invoked by uid 99); 9 Apr 2009 21:25:14 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 09 Apr 2009 21:25:14 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of jbellis@gmail.com designates 209.85.221.108 as permitted sender) Received: from [209.85.221.108] (HELO mail-qy0-f108.google.com) (209.85.221.108) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 09 Apr 2009 21:25:06 +0000 Received: by qyk6 with SMTP id 6so1420907qyk.32 for ; Thu, 09 Apr 2009 14:24:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=opEXZ4j1prY2R4Z9aQYqPD3ABFkujXL7xJwDWpK8YGI=; b=jiX89mrPkuZLnAkBUCJS79jcbtbvVbCgznMB8qoaRqp3BDG6bwmH7l2W7cD2pd3d4R xBHM7Gsi+VRSVPPr5JAf/1qhvwHsUDXW0t109y/U8FEWxmEFlxR75YAXf3nVN++mos3i 6jDiA3Mvxpt0eNWCY2fWBoI7vlrFnfFU/dm4s= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=Zrd4Ktc+Lqa8g1FjFlBUVXrpSA1ldHOce3g7k9IdFpCf9PyKZUMRDi1ddnQAoIMrrk oYB3dx/2QSArDh5soXpytYeFBnsdmlUUg+bXdoUeXrHejXPdwYO+htDsUsh2sfTrcaff Vg7YqvNXJcFup/NznZmvth7j3hTYSl2pu17wI= MIME-Version: 1.0 Received: by 10.229.74.71 with SMTP id t7mr1051061qcj.47.1239312285230; Thu, 09 Apr 2009 14:24:45 -0700 (PDT) In-Reply-To: <3317711b0904091419r37f83ad7y9f62f171ea3a5a9e@mail.gmail.com> References: <3317711b0904091402l6c5e998wf310cd3934982074@mail.gmail.com> <3317711b0904091419r37f83ad7y9f62f171ea3a5a9e@mail.gmail.com> Date: Thu, 9 Apr 2009 16:24:45 -0500 Message-ID: Subject: Re: Sample Client Code From: Jonathan Ellis To: cassandra-user@incubator.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org is content a supercolumn? otherwise specifying a subcolumn isn't going to = work. did you check your log file for exceptions? On Thu, Apr 9, 2009 at 4:19 PM, Sam D wrote: > Thanks for the quick response, > > I have only one node. So the web client also should see the data, right ?= . > Below is the code which I am using to read. > > =A0=A0 =A0=A0=A0 socket =3D new TSocket(machine,port); > =A0=A0=A0 =A0=A0=A0 TProtocol tp =3D new TBinaryProtocol(socket); > =A0=A0=A0 =A0=A0=A0 cl =3D new Cassandra.Client(tp); > =A0=A0=A0 =A0=A0=A0 socket.open(); > =A0=A0=A0=A0 =A0=A0 column_t u1 =3D cl.get_column("xmls","x1","content:xm= l"); > =A0=A0=A0 =A0=A0=A0 System.out.println("xml : " + u1.value); > > Sam. > > On Thu, Apr 9, 2009 at 2:07 PM, Jonathan Ellis wrote: >> >> That looks reasonable. =A0How are you reading the data back out? =A0The >> web interface only hits the local machine so it is not very useful in >> a clustered situation. >> >> -Jonathan >> >> On Thu, Apr 9, 2009 at 4:02 PM, Sam D wrote: >> > Hi, >> > >> > I am new to Cassandra, just installed the latest version on my machine= . >> > I >> > am able to insert rows using the web (@7002), but I am not able to get= a >> > java client to insert rows into a table. Below the piece of code I am >> > using, >> > the insert call goes through fine without any exceptions, but I am not >> > able >> > to see the row in the table, so I assume its not being inserted >> > properly. >> > >> > =A0=A0=A0 =A0=A0=A0 socket =3D new TSocket(machine,port); >> > =A0=A0=A0 =A0=A0=A0 TProtocol tp =3D new TBinaryProtocol(socket); >> > =A0=A0=A0 =A0=A0=A0 cl =3D new Cassandra.Client(tp); >> > =A0=A0=A0 =A0=A0=A0 socket.open(); >> > =A0=A0=A0 =A0=A0=A0 cl.insert("xmls", "x1", "content:xml", "xyz", 0); >> > >> > Can you please point me to any sample code available which I can refer >> > to ?. >> > >> > Thanks >> > Sam. >> > > >