Updating Ajax data. Extjs

I need to constantly update certain data (in the grid) and was going to do a poll on the server every 15 seocnds or so in order to get the data and update the grid, however it feels a bit dirty (the grid will have a download icon every 15 seconds ..) does not look great ... Another option is to check if there is new data and compare new data with current data and update the grid if there are any changes (I would have to do this client side, because the state of each registered user So it seems redundant)

I am sure that there are better solutions and I would like to hear about them

I heard about COMET, but the tit seems to have gone a little too far
BTW im using asp.net MVC on the server side

I'd like to hear what people have to say for or against continuous polling with js Greetings

+3
source share
5 answers

It seems that COMET really is the solution you are looking for. In this case, you do not need to conduct a survey or perform comparisons, since you can only push the “relevant” modified data into your grid.

Check out WebSync , this is a good comet server for .NET that will let you do exactly what you described.

ExtJS ASP.NET, . , , .

+2

, , , - .

. , - , . 15 . ; , 15 + 5 . ; , 15 +5 +5 . . ; - , reset 15 .

Ajax.PeriodicalUpdater, , , , .

, .


; , ( "" PHP - ). , , . .

+1

, , " ". 15 ; ? , , .

+1

, , .

  • , , (: lastPollTime).
  • , / (), .
  • , , , , , .

, ( ) , .

, , . , , .

+1

, - .

(HTML) . , .

Say that you have 12 rows of the table and you check 14 rows of the database: Get the last (14 - 12) = 2 rows.

0
source

Source: https://habr.com/ru/post/1723005/


All Articles