Return-Path: X-Original-To: apmail-camel-users-archive@www.apache.org Delivered-To: apmail-camel-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 70A6F9042 for ; Wed, 16 May 2012 14:40:25 +0000 (UTC) Received: (qmail 95677 invoked by uid 500); 16 May 2012 14:40:25 -0000 Delivered-To: apmail-camel-users-archive@camel.apache.org Received: (qmail 95647 invoked by uid 500); 16 May 2012 14:40:25 -0000 Mailing-List: contact users-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@camel.apache.org Delivered-To: mailing list users@camel.apache.org Received: (qmail 95638 invoked by uid 99); 16 May 2012 14:40:24 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 May 2012 14:40:24 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,SPF_NEUTRAL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: 216.139.236.26 is neither permitted nor denied by domain of darpan27484@gmail.com) Received: from [216.139.236.26] (HELO sam.nabble.com) (216.139.236.26) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 May 2012 14:40:18 +0000 Received: from [192.168.236.26] (helo=sam.nabble.com) by sam.nabble.com with esmtp (Exim 4.72) (envelope-from ) id 1SUfOP-0005Hm-FA for users@camel.apache.org; Wed, 16 May 2012 07:39:57 -0700 Date: Wed, 16 May 2012 07:39:57 -0700 (PDT) From: dmhatre To: users@camel.apache.org Message-ID: <1337179197460-5710917.post@n5.nabble.com> In-Reply-To: References: <1337098657991-5710187.post@n5.nabble.com> Subject: Re: Help with error while implementing camel jpa MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Hello Christian, Thank you for the reply. I got this working. I am not getting this error no more. But still I am pasting my code snippet so that you can have a look and let me know if this is the right way to do the things OR if its right, some other users who come across this problem can use this. MY ROUTE: ================= BEANS: ================= persistence.xml =============================== org.apache.camel.example.spring.DarpanTest ENTITY: ========================= import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.Id; import javax.persistence.Table; @Entity(name="darpantest") @Table(name="darpantest") public class DarpanTest { @Id @Column(name="testid") private long testid; @Column(name="testname") private String testname; public DarpanTest() { } public long getTestid() { return testid; } public void setTestid(long testid) { this.testid = testid; } public String getTestname() { return testname; } public void setTestname(String testname) { this.testname = testname; } } BEAN: ====================== public class JPATest { public void readContent(Exchange test) { Object obj = test.getIn().getBody(); DarpanTest d = (DarpanTest)obj; System.out.println("########"+d.getTestid()+"#######"); System.out.println("########"+d.getTestname()+"#########"); } } -- View this message in context: http://camel.465427.n5.nabble.com/Help-with-error-while-implementing-camel-jpa-tp5710187p5710917.html Sent from the Camel - Users mailing list archive at Nabble.com.