questions on sync scenarios

1 view
Skip to first unread message

Daniel Myung

unread,
Dec 17, 2008, 2:00:02 PM12/17/08
to mes...@googlegroups.com

Hi Ed,

In response to your question:

"If you tell us the schema for the table you want to use as the example we can work it off of that!  Reminder we have a milestone coming up Friday, do we have until then? Does this outline I just created look appropriate for your needs?

http://code.google.com/p/mesh4x/wiki/HowToSyncADatabase"

 

I wanted to provide a bit of feedback and then tell you a bit more about the specific use case we're trying to support – in addition to providing a schema for you if you do want to use it as an example (see end of message)

This looks like a good outline of what we need to do.  Two decision points we are having which maybe you can help us address are as follows: 

Out of the box, django uses sqlite via pysqlite.  Small, local, simple config.  However it appears to not have full-blown hibernate support.  So:

  • Has anyone had experience syncing a Sqlite DB in mesh4x?  I assume that getting hibernate on top of it solves this problem, but we're not sure how hard that is.
  • If we had to use Sqlite and hibernate was not an option, what would writing an adapter for it entail?  Is one already written?
  • Assuming that switching to MySql was an option that introduced some (but not a ton of) complexity – would that be your recommended solution over trying to wrap Sqlite?
  • In summary:  We use sqlite, but have the option of mysql.  What's the best way to proceed w/ mesh4x?

There appears to be a separate layer of abstraction associated with transport mechanism. 

In particular, we have some additional questions regarding the HTTP transport.

Not surprisingly, we expect to encounter potentially very bad connections, in terms of being up and down frequently and potentially high drop/timeout rates and long periods of offline time.  We're looking at a "on demand, seldom on" GPRS modem connection for a laptop.

 * Is there out-of-the box support for a scenario like this - possibly with opportunistic calls to the http sync methods?

 * If not, what would be your recommended solution for working with mesh in an environment like this?

 * Are there issues that come up when a connection drops in the middle of a sync?

 * if there is a huge amount of data that needs to be synced...and the sync never finishes (due to continual drops and timeouts), is there a chance it'll be in sort of stuck state?

These concerns on HTTP has had us curious about the USB file key transport mechanism.  How are changes propagated via a USB stick?  Is it assuming that the entire database (or excel file) need to be present such that the sync engine can touch Left and Right to do the sync?  As such, it's just a choice of a certain adapter and storage?

This is partly why we've been looking hard at the Dropbox/WLM option.  It to us, represents a USB stick file transfer minus the cars/walking and USB stick.  When a remote update finishes, only then will a file will actually appear as a file in your shared folder.  Presumably then, it'll be ready to synchronize.  But maybe I'm overanalyzing the situation.  If HTTP can handle the poor connectivity, then this conversation is moot :)

For info on our database schema, take a look at this link: http://code.dimagi.com/ec3/wiki/SynchronizationThoughts for a high-level description of the project for some additional context.  This also includes the tables you can use as a model for the documentation if you would like. 

Tangentially, I think if the sqlite case is addressed, then googlegears + mesh4x would be a pretty freaking sweet setup for future apps :)

Dan




--
Daniel Myung
Senior Engineer, Dimagi, Inc  
529 Main St, Suite 606 | Charlestown, MA 02129
office: (617) 580-3100  |  mobile: (617) 645-3236 | fax: (617) 580-3103
http://www.dimagi.com/

Juan Marcelo Tondato

unread,
Dec 18, 2008, 8:51:52 AM12/18/08
to mes...@googlegroups.com
I think that this post can help us: http://forum.hibernate.org/viewtopic.php?t=979397&highlight=sqlite.
Other option is to write an adapter using jdbc connection over Sqlite, this adapter should create and execute sqlite sql statements.

JMT
Reply all
Reply to author
Forward
0 new messages