Skip to content

Proposal: silverstripe-logviewer #5

@robbieaverill

Description

@robbieaverill

silverleague/silverstripe-logviewer

Specification: https://silverleague.github.io/complete/silverstripe-logviewer

Introduction

As a developer you may not be as aware of SilverStripe logging as you may want to be.

This module intends to add a Monolog logger which will log to a database table that can be rendered to an area of the CMS admin for easy viewing.

Why?

Because logs often go unnoticed, and since the 4.x framework has Monolog bundled with it, we can easily add a new LoggerInterface to push logs to the database. From here, they can easily be displayed in the admin as a GridField or similar.

Details

A new CMS section which displays a GridFields listing all log entries stored.

Columns could be: log content, date/time, log level.

Provide the filter to certain log levels, and allow the GridField to be filterable so I could search for "Deprecated" for example, or to filter by a date range. Handled by GridField.

We would implement a BuildTask and/or a CronTask which would clear the logs that are older than x days (7? 14? 30?). A button in the CMS admin interface would also allow you to clear old logs.

Export to CSV functionality would be useful as well. Handled by GridField.

Functionality

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions