L
L
LiptonOlolo2020-10-30 00:00:10
API
LiptonOlolo, 2020-10-30 00:00:10

How to make synchronization?

Good day.
The bottom line is, there are clients (Windows applications) and you need to synchronize data on them.
While there is an idea such:
1) SignalR for the notification that new data is available;
2) RestAPI for CRUD;

Those. on each request to the API, the API will tell SignalR'y to notify clients of new data.

Say that you can just drive all the data through SignalR, but, for example, on the first connection, there will be a request to receive all relevant data, and there may be, for example, 10000 (let's say user data), SignalR may not take out such a load (how many does it have a limit there, 32kb?), and I don’t think that this is the right way.

How realistic and correct is this?
The main question is how to do it right.
ps - the load is not large, so I assume that SignalR and the API will be in the same server.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Victor P., 2020-11-09
@Jeer

I don't know if there is any silver bullet in data synchronization, I think that everything is quite individual depending on the project.
Your idea is quite viable, implement it.
From myself, I can add that it is not necessary to load the initial data through SignalR, it can only be used to update the data.
For example, does an application really need to know the entire list of users at once? And do you really need a whole list? In any case, when there are already users, when adding / updating one of the users, you can send not only a notification to all clients via SignalR, but also all the data on the user at once. Of course, if there is no mass update of all users, then this option will not work.
In general, everything is purely individual

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question