i have a very big json that has a very small changes each second.
im using asp.net core 3.1 and signalr core. and clients are using browsers running pure js and jquery.
right now for every change im re sending all the json again. i know that its not a good way.
what i want to do is just sending the Changes to client and then patch the changes to the main JSON in javascript.
by google search i understood that its a JSON diff/patch or diff/Merge operation, but i did not found anything on how to implement this.
so, how can i achieve a diff/pach opration in signalr ?
J_m and j_m_lit maybe 100 keys.
the data struncture
[
{
"id":0,
"stdid":3808003,
"lid":10533,
.
.
(40 root keys)
.
.
"J_ps":null,
"J_ms":null,
"J_m":{
"SA_H2 0":{
"c":"SA_H2",
"a":"0",
"b":0,
"r":"0",
"w":0,
"en":"2nd",
"o":{
"2:0":{
"c":"2:0",
"v":1.3,
"pv":0.0,
"b":0
},
"Tie":{
"c":"Tie",
"v":3.2,
"pv":0.0,
"b":0
}
}
},....
},
"J_m_Lit":{
"OE 0":{
"c":"OE",
"a":"0",
"b":0,
"r":"0",
"w":0,
"en":"Total ",
"o":{
"xxx":{
"c":"Odd",
"v":1.833,
"pv":0.0,
"b":0
},
"zzz":{
"c":"Even",
"v":1.833,
"pv":0.0,
"b":0
}
}
}, ....
},
"J_fre":{
"tq":[
0,
1
],
"m1":[
23,
17
]
},
}
]