From: Thomas W. <tho...@gm...> - 2009-11-26 12:42:35
|
I think I need to refine the meaning of page in this case. Dealing with large data sets always require some sort of displaying the data in chunks/parts/pages and navigating between them. How we are going to call it is not relevant. The practice has showed us many times a simple truth - sending large data down the wire is never a good idea. A log chunk could be selected by range of line number (page-size and page-number is effectively the same) or by range of timestamps. The page is a set of lines taken from the file and displayed in the browser at the moment of accessing the file. We can display say 500 lines at a time and walk up and down another 500 lines. We can event start displaying the last 500 lines if we want. That fact that this file grows it real time does not change the need of delivering the data in chunks - we just need a simple mechanism of periodically querying for data with timestamp older then the last update. Delivering the data in chunks does not necessarily mean it will be displayed as pages - the new data can be just appended on the screen. jQuery can do miracles with very little code. I agree if we have a servlet that can access the logs and deliver part of the log this will be the best. The servlet can accept the following parameters: log-file-name and one of the following: a) first-line-number, last-line-number b) page-size, page-number, c) timestamp-beginning, timestamp-end d) all-after-timestamp e) all ( bad idea! ) another method: logs-list: returns the name of the logs files, their sizes and last updated timestamp. I hope this clarification will help. Regards, Thomas ------ Thomas White Mobile:+44 7711 922 966 Skype: thomaswhite gTalk: thomas.0007 Linked-In:http://www.linkedin.com/in/thomaswhite0007 facebook: http://www.facebook.com/thomas.0007 2009/11/26 Dmitriy Shabanov <sha...@gm...> > On Thu, 2009-11-26 at 11:34 +0000, Thomas White wrote: > > Dannes, > > > > This URL is to display the log in a browser in reasanable chunks. I do > > think it will be practical to just dump 60,000 lines the browser. > > We need a log stream, not a page. When log's page open it should receive > all log staff, till it be close (page). aka "tail -f eXist.log", but web > > -- > Cheers, > > Dmitriy Shabanov > > |