From user-return-15188-apmail-couchdb-user-archive=couchdb.apache.org@couchdb.apache.org Fri Mar 04 02:34:20 2011 Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 27997 invoked from network); 4 Mar 2011 02:34:20 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 4 Mar 2011 02:34:20 -0000 Received: (qmail 84588 invoked by uid 500); 4 Mar 2011 02:34:19 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 84390 invoked by uid 500); 4 Mar 2011 02:34:18 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 84375 invoked by uid 99); 4 Mar 2011 02:34:18 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 04 Mar 2011 02:34:18 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of fairwinds.dp@gmail.com designates 209.85.216.52 as permitted sender) Received: from [209.85.216.52] (HELO mail-qw0-f52.google.com) (209.85.216.52) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 04 Mar 2011 02:34:13 +0000 Received: by qwf6 with SMTP id 6so1627431qwf.11 for ; Thu, 03 Mar 2011 18:33:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=KOe+ez3ZhVuoVXVli98XEP1IVq3furCbOcHSjxXP3h0=; b=HU4xvHpqKaQ+wnEJ/0SGte6xu2xyO/PY3gw+kuFq/Vys6YE5j6pMnEUv9/EbRAAqBd Z0MvOJkHl1ocRHolPzkGqocU15jabQjp8+YJV+ioQByAz/pyy8JkcWVKDRPXLlzU7MGh uUBU62bnVtM1S09XQ0DBJYp88+L58c4DJ0tXM= 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; b=du/NpKjoZqSwhFx1fcalMG6378J4+HRusJ3Jycb1KIXYAp7SqlDdIB/RyeT+gCfTd6 ygYkn41oJWuXzPSQNG+ps1pqby5zJxz2Mva0aNWia17yATPh6qNJOqDW053WmVPaA+iH i98WQocyAdi/6v28f+LFL6PXFw4eQTNFTv5gc= MIME-Version: 1.0 Received: by 10.229.123.201 with SMTP id q9mr40083qcr.125.1299206031937; Thu, 03 Mar 2011 18:33:51 -0800 (PST) Received: by 10.229.235.200 with HTTP; Thu, 3 Mar 2011 18:33:51 -0800 (PST) In-Reply-To: References: Date: Thu, 3 Mar 2011 22:33:51 -0400 Message-ID: Subject: Re: memcouchd... From: David Pratt To: user@couchdb.apache.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org Hi Tim. I am in the same situation and this would be pretty cool. Can you advise what was required to get it running in appcelerator. I communicated with mikeal not so long ago on irc and couchdb for iphone had already been submitted to apple for review. I am not sure what they will do with it. Hoping apple will allow it. This development is definitely interesting. On Tue, Feb 1, 2011 at 5:15 PM, Tim King wrote: > Hi kowsik, > > Thanks for sharing your code it looks pretty interesting. > > I can think of a cool use for it outside of nodejs. I'm currently writing > some applications using Titanium Appcelerator http://www.appcelerator.com/. > I don't know if you know about it or not. It allows you to write > applications for iPhone/iPad/Android using Javascript which gets converted > into Objective-C or Java respectively and compiled into native applications. > > One thing I'd really like to have is couchdb or a compatible API running on > these mobile devices which can be used for offline storage and syncing with > couchdb servers. I'm aware that it is possible to compile couch for Android > but after investigating running it on iOS I think this will be hard and it > would probably not be allowed by Apple anyway due to the Erlang VM. > > Anyway I was thinking that using your memcouchd it would be possible to > create an embedded couch compatible db for use in Appclerator based apps. > Appcelerator has partial support for commonjs and I've got your code running > with a few small alterations. I haven't been able to get the test suite > running due to issues with some of the modules from nodejs but it should be > doable with a bit of hacking. > > The only things missing that would make this really useful are the ability > to persist the documents on the device and replication. I think that the > documents could potentially be stored using the Properties API which stores > key value pairs. Unfortunately the support for manipulating binary files is > lacking in Appcelerator so I think implementing the couch file format would > be impossible without implementing it in Objective-c and Java as native > extensions which is possible but I'd rather avoid writing platform specific > code if possible. > > What are you thoughts about using your code for this purpose? Have you got > any thoughts about serialising the store? > > Thanks again for sharing the code! > > Tim > > On 30 January 2011 12:33, kowsik wrote: > >> Just something I that threw together in the last couple of days. YMMV >> and I have no idea what you would use this for! :-) >> >> https://github.com/pcapr/memcouchd >> >> K. >> --- >> http://twitter.com/pcapr >> http://labs.mudynamics.com >> >