OED icon indicating copy to clipboard operation
OED copied to clipboard

dealing with log files

Open huss opened this issue 3 years ago • 4 comments

Is your feature request related to a problem? Please describe.

OED wants non-IT people to be able to manage a site. While we can send daily email to the admin with all issues in the log file, it would be nice to allow admin to look at the log file on a web page.

Describe the solution you'd like

We need to decide how to specify date ranges for the admin to look at. This may mean thinking about how we do logging and if we should adopt a standard package. We also should think through the fact that log files can get very large over time.

Describe alternatives you've considered

None.

Additional context

None.

huss avatar Feb 09 '22 00:02 huss

After researching packages involving logs, it's shown that there are no packages (or widely adopted packages) that fulfill this role. Instead, it would be a good idea to parse the log files generated with the built-in 'readline' package, https://nodejs.org/api/readline.html along with the 'fs' package for passing in files. Then, in combination with using Regex, you could store & sort logs by day/month/year/etc. into the database, and display it into the webpage (rather than parse everytime an admin would want to read logs). Using the most recently stored date, new logs would be added properly into the database, where we would also routinely delete logs depending on the admin's preference.

jina2k avatar May 01 '22 19:05 jina2k

Another option raised is to store the msgs in a DB table and use queries to get the desired items. That may be faster and eaiser? than parsing the file with packages.

huss avatar Jul 10 '24 21:07 huss

I would like to work on this.

ianLewis8 avatar Jul 19 '24 18:07 ianLewis8

Hi, I would like to work on this issue.

nmqng avatar Sep 05 '24 21:09 nmqng