continuing from Connecting food cooperatives (since product sync is becoming too specific for the general connecting foodsoft interoperability thread.
The OFN rest API provides means to post and retrieve product data. In order to repliacate data between OFN instances and/or offline apps some kind of data synchronization protocoll/handshake is necessary.
How to efficiently determine that there are no new product changes to download? (instead of simply deleting and re-downloading all products again) There is a last_modified column in the database tables but it does not seem to be exposed via the api?
How to detect/handle the case when both parties changed the same
product (field) between a sync? There are two versions in this case that
would need some automatic or manuall merge/resolve strategy…?
Maybe some sync like
git pull && local merge && git push
What do you think?