Documentation

AJAX

Logtail uses the prototype-library from http://prototype.conio.net/. It uses a MIT-style license. This allows logtail to run on many browsers without juggling with browser incompatibilities.

How does the tailing work?

To read only the changed lines even of really big logfiles logtail uses the Java library class java.io.RandomAccessFile. This class allows to seek in files without actually reading them completely.

What the code does is the following:

  1. Determine the number of lines to read (1000 by default).
  2. Seek to <EOF>-<number of lines>.
  3. Read all lines into a collection until <EOF> is reached.
  4. On every AJAX-request from the application try to read new lines.