Strategies for Synchronizing Data Between a Rails App and iPhone App -


I have written several iPhone applications that have pulled data from web services and I worked on syncing data between an iPhone app And a web application, but I have always felt that there is probably a better way of handling sync.

I want to know what strategy you have used to synchronize data between your iPhone (Read: Mobile) Applications and your tracks (Read: Web) application.

  • Are there any strategies that are particularly well-scaled?
  • How do you present a large amount of data? (Do you use pageized responses?)
  • How do you ensure that the data is not overwritten?
  • Is there any reason to avoid Ruby on Rail?
    • If so, can you recommend any options? What is better about alternative?
    • What strategies have you failed?
      • Why do you believe that those strategies fail?

    I would like to be able to keep all the data modifications on the server, but the specific application that I'm starting to work on is disconnected from the network. The ability to work will be required.

    User will be able to update data on mobile device and update data through web application.

    When a user's mobile device connects to the server, any local changes will be pushed to the server.

Your answer is not the whole question, but what I started doing helps with the mobile scenario That is putting a layer between the arguments that the server is sending to the sync data and the web server.

I have created a data unit which is just a normal sync object that I am storing a unique ID, payload and the last delivery date. I have another argument that is grabbing and sending sink objects with the main data. If a good response is received (i.e., a reaction actually came back and the reaction text I used to expect), then the sync object has been removed. This helps to ensure that your sync data is taking the destination properly and is not just lost in the sea, it is also a good model for offline operation. You can store your sync object while you are offline and once you come back online you can start sending them in order.

From the web perspective, the rail metal looks like it may be suitable for such a situation I have never used it myself, but on the basis of some reading it looks like metal is Is targeted for situations where high traffic can be possible and quick answers can be important. It basically cuts the upper part of the router router and is thus hopeful that helps.


Comments