Lecture


passed parameters (fields)
1.data- line in json format
Description:
1. data in the data field is transmitted in a string in json format
In them we transfer data which needs to be synchronized.
It uses:
a) the unique local creation time (change) "ut" (each entry)
b) and a unique local id (for each entity) (id must be unique, have a - sign).
c) transmission without a minus sign for the id, if id global.
data =
[
{
"cmd": 1,
"ut": 134256789088,
"tb": "product",
"dt": [-6341,134,13,12,12312,12]
},
{"cmd": 2,
"ut": 4578678789876,
"tb": "product",
"dt": [1,12,162,124,142,12,12, -341, 126,12,122,122]
},
{"cmd": 3,
"ut": 45678908765,
"tb": "product",
"dt": [1]
}
]
Where
cmd - command (1,2,3) for details see below.
ut - unictstaym (in seconds) of each record on the device
(the time of the last local work with this object)
dt- data array without field names
tb - table name for synchronization
see values below
2. transfer no more than N records in one request, if there are more than N records, then transfer first the read records to the record, then everything else in portions (page by page)
Comments
To leave a comment
Databases, knowledge and data warehousing. Big data, DBMS and SQL and noSQL
Terms: Databases, knowledge and data warehousing. Big data, DBMS and SQL and noSQL