Return-Path: X-Original-To: apmail-incubator-directmemory-dev-archive@minotaur.apache.org Delivered-To: apmail-incubator-directmemory-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2925175E2 for ; Thu, 29 Dec 2011 19:09:15 +0000 (UTC) Received: (qmail 97386 invoked by uid 500); 29 Dec 2011 19:09:15 -0000 Delivered-To: apmail-incubator-directmemory-dev-archive@incubator.apache.org Received: (qmail 97344 invoked by uid 500); 29 Dec 2011 19:09:15 -0000 Mailing-List: contact directmemory-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: directmemory-dev@incubator.apache.org Delivered-To: mailing list directmemory-dev@incubator.apache.org Received: (qmail 97336 invoked by uid 99); 29 Dec 2011 19:09:15 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 29 Dec 2011 19:09:15 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,T_FRT_POSSIBLE X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of raffaele.p.guidi@gmail.com designates 74.125.82.43 as permitted sender) Received: from [74.125.82.43] (HELO mail-ww0-f43.google.com) (74.125.82.43) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 29 Dec 2011 19:09:10 +0000 Received: by wgbds11 with SMTP id ds11so45765115wgb.0 for ; Thu, 29 Dec 2011 11:08:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=7o/j0HCqLQXUEjJUZ6g1Q0qeiTNTNLWDlEWAqKH/6Bo=; b=rXiL85bVvZ1av1D2q370lSkS2YKPL+A73C3P14KhP4j9Q74/monfxAw+EpZv1QUBJR 1VgRduEAHDpYwK9SOt7xl+Rb2Q245so6AEyrUQLBpeYUWAi3PRqqUwwqSIpzpkeCNQZn g1r4wxU0T6CNberekjrg1KNRm2f8RS7NQaE0A= MIME-Version: 1.0 Received: by 10.227.208.133 with SMTP id gc5mr36027873wbb.25.1325185728924; Thu, 29 Dec 2011 11:08:48 -0800 (PST) Received: by 10.216.154.207 with HTTP; Thu, 29 Dec 2011 11:08:48 -0800 (PST) Received: by 10.216.154.207 with HTTP; Thu, 29 Dec 2011 11:08:48 -0800 (PST) In-Reply-To: References: Date: Thu, 29 Dec 2011 20:08:48 +0100 Message-ID: Subject: Re: Cache keys From: "Raffaele P. Guidi" To: directmemory-dev@incubator.apache.org Content-Type: multipart/alternative; boundary=0015174755caa24ded04b53fd8a7 --0015174755caa24ded04b53fd8a7 Content-Type: text/plain; charset=ISO-8859-1 Great! Right, keys are managed by the guava map that don't require Serializable Il giorno 29/dic/2011 20:01, "Maurizio Cucchiara" ha scritto: > AFAICU there is no reason to implement the Serializable IF, since keys > are not serialized (I could be wrong though) > The switch from string to object looks apparently simple, I haven't > experienced any issues until now (every test run smoothly) . > I'm going to attach a patch on DIRECTMEMORY-43 [1], please let me know > WDYT. > > [1] https://issues.apache.org/jira/browse/DIRECTMEMORY-43 > > > Twitter :http://www.twitter.com/m_cucchiara > G+ :https://plus.google.com/107903711540963855921 > Linkedin :http://www.linkedin.com/in/mauriziocucchiara > > Maurizio Cucchiara > > > > On 15 December 2011 15:28, Raffaele P. Guidi > wrote: > > Sure it would be a good thing, of course keeping the most frequent use > case > > as simple as possibile. Also remember that one of the things that allows > > DirectMemory to perform well is protostuff - that is an efficient and > > unobtrusive way to work around serialization. > > > > Ciao, > > R > > Il giorno 15/dic/2011 13:56, "Tommaso Teofili" < > tommaso.teofili@gmail.com> > > ha scritto: > > > >> Hi all, > >> > >> while working on one of the examples I found myself wondering why keys > in > >> Cache have to be Strings. > >> Generally a cache should also be able to use objects of whatever nature > as > >> keys, so we could use the same serialization mechanism used for values > or, > >> at least, define keys to be implementing the java.io.Serializable > >> interface. > >> What do you think? > >> > >> Tommaso > >> > --0015174755caa24ded04b53fd8a7--