Permanent server request through Javascript is a good idea?

I have a small website with 5-10 administrators. I set it up to control what each administrator does (add items, delete items, etc.). I had a list in our admin panel that shows the previous 10 jobs performed by collective administration. Today I decided to do this myself update every 30 seconds.

My question is simple: are there any problems? I call a small text with each request, and most likely the request is executed only on 3 or 4 computers (which reflects the number of managing administrators registered at the same time).

  $(document).ready(function(){
    setInterval("activity()", 30000);
  });

  function activity() {
    $("#recent_activity").load("../home/login #recent_activity .data");
  }

Produces the following (or similar - with only 10 lines) with each request.

<table>
  <tbody>
    <tr>
      <td><p>jsampson</p></td>
      <td><p>logged out</p></td>
      <td><p>28 minutes 27 seconds ago</p></td>
    </tr>
    <tr>
      <td><p>jdoe</p></td>
      <td><p>logged in</p></td>
      <td><p>29 minutes 45 seconds ago</p></td>
    </tr>
  </tbody>
</table>
+5
13

3-4 30 . 300 .

:

, , , , , , .

+4

30 .

+4

, . 1 , . , - .

( , ), , , 30 ... , , 10-20 , ... ​​ 5-10 .: -)

+1

, . , (, Betfair), xhr . , , .

, , , - sinlge.

+1

, .

0

, , .

, ?

0

altCognito - - .

, , - , . . , , . , ( ).

0

. 30 , , , " ".

, AJAX.

0

Google Wave ...? , , . ( , - -.)

0

, .

, 2 :

  • JSON , HTML.
  • , .

    {"user":"jsampson","action":"logged out","date":"20090622T170822"}

0

, .

, , , , , , .

, . RoR, , , , , 100 , - .

0

HTTP. : Comet.

, iframe chunked transfer (, PHP flush()) HTTP-. , . , TCP-.

0

, .

, , , setTimeout(), / .

, , , .

30 - "" , .

, - . . "", , .

0

All Articles