##// END OF EJS Templates
Updated request 'pull' to show how we filter the sender hosts
Updated request 'pull' to show how we filter the sender hosts

File last commit:

r782:393424ee decentral
r783:a07f0217 decentral
Show More
sync.markdown
34 lines | 1.1 KiB | text/x-markdown | MarkdownLexer

INTRO

This document discribes the server sync protocol.

DRAFT PROTOCOL DESCRIPTION

The node requests other node's changes list since some time (since epoch if
this is the start). The other node sends a list of post ids or posts in the
XML or JSON format.

Protocol version is the version of the sync api. Model version is the version
of data models. If at least one of them is different, the sync cannot be
performed.

The node signs the data with its key. The receiving node saves the key at the
first sync and checks it every time. If the key has changed, the info won't be
saved from the node (or the node id must be changed).

Each node holds a list of networks it wants to get info from.

Each post has an ID in the unique format: node-id/post-id

All requests pass a request type, protocol and model versions and a list of
optional arguments used for filtering.

REQUESTS

Request types:

  • pull - pull the desired model ids
  • get - get models by ids

RESPONSES

  • not supported - request is not supported
  • success - request was successfull
  • error - unexpected error