I have a scenario, where i need check if my Database has received new orders (restaurant).
Signalr seems to be the best option.
But I can wait 2-3 minutes to update with AJAX.
Given this long range I can expect, and thinking of a large scale, would not ajax be better?
Although this looks like a duplicate of: Is SignalR a suitable substitute for jQuery Ajax (or similar), I'd say you should use SignalR, based on the chosen answer to the similar question.
SignalR is perfect for notifying users real-time. You can call client functions from the server and vice versa. This makes it very dynamic.
I think it would be more heavier to call an endpoint every 2 minutes – even if there was no order placed – then only perform an action when an order has been placed.
The capacity for concurrent connections depends on the performance of the server.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With