Return-Path: Delivered-To: apmail-camel-users-archive@www.apache.org Received: (qmail 68558 invoked from network); 8 Oct 2010 13:52:18 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 8 Oct 2010 13:52:18 -0000 Received: (qmail 4816 invoked by uid 500); 8 Oct 2010 13:52:17 -0000 Delivered-To: apmail-camel-users-archive@camel.apache.org Received: (qmail 4771 invoked by uid 500); 8 Oct 2010 13:52:17 -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 4759 invoked by uid 99); 8 Oct 2010 13:52:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 08 Oct 2010 13:52:17 +0000 X-ASF-Spam-Status: No, hits=1.3 required=10.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of hzbarcea@gmail.com designates 209.85.213.173 as permitted sender) Received: from [209.85.213.173] (HELO mail-yx0-f173.google.com) (209.85.213.173) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 08 Oct 2010 13:52:11 +0000 Received: by yxf34 with SMTP id 34so324430yxf.32 for ; Fri, 08 Oct 2010 06:51:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:content-type:mime-version :subject:from:in-reply-to:date:content-transfer-encoding:message-id :references:to:x-mailer; bh=QOIF3NcUP0MQs7iX3YuLWF/fHEAKlSjZPDL0kLBbHhU=; b=e6Je0JHOMjBy65SVIJNToXqvzpXMb3DK2K9VBxJVG6fsC4S80NxMFdIeNN5v1AIqPe 66p4xM+kLTZ/FUBWsmwR8XzoHlLyUpXk5TxmmG9xMMTaivumEnrVY6DkZ9Ybxo73S1w5 DSTkRLkx1dcYWXzy8IL62w4JmGp1YOm0YlKZ4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=content-type:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to:x-mailer; b=iF79xKT/G34cLd1FhwKeg6R2nq/emGSXXvYOfdPXcmLDm28EuYvRb/HIPdnCjTq/Qh bHXBY75pW8WNhyAG5NAPisg/GV1oRSQcRcjeCjwcHmCOaUFLgyva27I1fgb+pTLv73T3 3d/8tdsWykwn67t7V4dIK6UKkgL/ISdscHJYU= Received: by 10.100.243.24 with SMTP id q24mr609719anh.54.1286545908856; Fri, 08 Oct 2010 06:51:48 -0700 (PDT) Received: from [10.40.58.200] (cpe-075-182-108-220.nc.res.rr.com [75.182.108.220]) by mx.google.com with ESMTPS id w3sm3144563anw.25.2010.10.08.06.51.47 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 08 Oct 2010 06:51:48 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Apple Message framework v1081) Subject: Re: Should we (could we?) make Exchanges serializable? From: Hadrian Zbarcea In-Reply-To: Date: Fri, 8 Oct 2010 09:51:45 -0400 Content-Transfer-Encoding: quoted-printable Message-Id: <952D0425-B7CF-45E4-901B-F7C4C22D7A03@gmail.com> References: <1286533270197-3204367.post@n5.nabble.com> To: users@camel.apache.org X-Mailer: Apple Mail (2.1081) X-Virus-Checked: Checked by ClamAV on apache.org +1 fwiw, Hadrian On Oct 8, 2010, at 7:05 AM, Claus Ibsen wrote: > On Fri, Oct 8, 2010 at 12:21 PM, Ade = wrote: >>=20 >> I've never been a fan of Java serialization; however, I've been = working with >> a Camel user who wants to be able to serialize an exchange and place = the >> whole thing on a JMS queue. The motivation is that they want to set = the >> exchange up to be subsequently persisted in a database for audit = purposes, >> but they want to separate the writing to a queue (relatively fast and >> asynchronous) from the act of persisting to a database. >>=20 >> In order to achieve this, they've had to create their own = serializable >> versions of Exchange, Header, Property, Message and Attachments. This = works, >> but it's painful to have to write and maintain that extra code. >>=20 >> So. Just curious: would it be possible to modify the Camel core API = and make >> Exchanges etc. serializable? Interested to hear people's thoughts on = this. >=20 > I dont think we should do this. We can not assume the data it contains > can be serialized. >=20 > There is a DefaultExchangeHolder class which you can use to serialize > and Exchange. It has the features to only transfer the objects which > can be serialized. > Its used by other components which supports the transferExchange > options such as camel-jms, camel-mina, camel-netty, camel-hawtdb etc. >=20 >=20 >=20 >=20 >> -- >> View this message in context: = http://camel.465427.n5.nabble.com/Should-we-could-we-make-Exchanges-serial= izable-tp3204367p3204367.html >> Sent from the Camel - Users mailing list archive at Nabble.com. >>=20 >=20 >=20 >=20 > --=20 > Claus Ibsen > Apache Camel Committer >=20 > Author of Camel in Action: http://www.manning.com/ibsen/ > Open Source Integration: http://fusesource.com > Blog: http://davsclaus.blogspot.com/ > Twitter: http://twitter.com/davsclaus