You are here

README.txt in DBLog Filter 8.2

Same filename and directory in other branches
  1. 8 README.txt
CONTENTS OF THIS FILE
---------------------
 * Introduction
 * Installation
 * Configuration
 * Maintainers

INTRODUCTION
-----------
 * DB LOG FILTER module is used to restrict log messages by type and level.
 * Useful to restrict unwanted message types and reduce watchdog size for
    better performance.
 * Majorly useful in production sites when we want to log only
    limited messages.
 * Logging can be restricted either by the Levels. To Log only Error Level logs
   for a site, you can check "Errors" under "Select Severity Levels." in the
   configuration page.
 * Custom logging can also be done ignoring all the core logs too, by setting
   the values under "Enter DB Log type and Severity Levels."

INSTALLATION
------------
 * Install as you would normally install a contributed drupal module. See:
   https://drupal.org/documentation/install/modules-themes/modules-8
   for further information.

CONFIGURATION
-------------
 * Click on Configure link in modules page.
 * Or Go to http://YOURSITE/admin/reports/dblog-filter , configure type and
    level.
 * To restrict by Severity Level, Select from the allowed severity levels.
 * To restrict by Custom Logging, set it up under "Enter DB Log type
   and Severity Levels."
   Give one per line as (TYPE|LEVEL)
    - php|notice,error,alert
    - mymodule|notice,warning
   This only allows to log watchdogs of type "php" and "mymodule", with their
   respective severity levels.
   For example, Following are the Logs Recorded(as per the above settings):
   1. \Drupal::logger('mymodule')->notice('@build:',
        array('@build' => print_r($build, true)));
   2. \Drupal::logger('php')->alert('@build:',
        array('@build' => print_r($build, true)));
   Logs not recorded:
   1. \Drupal::logger('php')->warning('@build:',
       array('@build' => print_r($build, true)));

File

README.txt
View source
  1. CONTENTS OF THIS FILE
  2. ---------------------
  3. * Introduction
  4. * Installation
  5. * Configuration
  6. * Maintainers
  7. INTRODUCTION
  8. -----------
  9. * DB LOG FILTER module is used to restrict log messages by type and level.
  10. * Useful to restrict unwanted message types and reduce watchdog size for
  11. better performance.
  12. * Majorly useful in production sites when we want to log only
  13. limited messages.
  14. * Logging can be restricted either by the Levels. To Log only Error Level logs
  15. for a site, you can check "Errors" under "Select Severity Levels." in the
  16. configuration page.
  17. * Custom logging can also be done ignoring all the core logs too, by setting
  18. the values under "Enter DB Log type and Severity Levels."
  19. INSTALLATION
  20. ------------
  21. * Install as you would normally install a contributed drupal module. See:
  22. https://drupal.org/documentation/install/modules-themes/modules-8
  23. for further information.
  24. CONFIGURATION
  25. -------------
  26. * Click on Configure link in modules page.
  27. * Or Go to http://YOURSITE/admin/reports/dblog-filter , configure type and
  28. level.
  29. * To restrict by Severity Level, Select from the allowed severity levels.
  30. * To restrict by Custom Logging, set it up under "Enter DB Log type
  31. and Severity Levels."
  32. Give one per line as (TYPE|LEVEL)
  33. - php|notice,error,alert
  34. - mymodule|notice,warning
  35. This only allows to log watchdogs of type "php" and "mymodule", with their
  36. respective severity levels.
  37. For example, Following are the Logs Recorded(as per the above settings):
  38. 1. \Drupal::logger('mymodule')->notice('@build:',
  39. array('@build' => print_r($build, true)));
  40. 2. \Drupal::logger('php')->alert('@build:',
  41. array('@build' => print_r($build, true)));
  42. Logs not recorded:
  43. 1. \Drupal::logger('php')->warning('@build:',
  44. array('@build' => print_r($build, true)));