Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

PrivacyManager settings + Custom logo should be stored using Option:: rather than in config file #4563

Closed
mattab opened this Issue · 5 comments

2 participants

Matthieu Aubry Thomas Steur
Matthieu Aubry
Owner

For consistency, it would be nice if the PrivacyManager plugin + Custom logo ([Branding] section) stored its data in the DB rather than in the config file.

The ultimate goal is to make Piwik not need to write to the config file during normal operations.

  1. Create global config entries for the following settings:
  2. delete_logs_max_rows_per_query
  3. delete_reports_enable
  4. delete_reports_older_than
  5. delete_reports_keep_basic_metrics
  6. delete_reports_keep_day_reports
  7. delete_reports_keep_week_reports
  8. delete_reports_keep_month_reports
  9. delete_reports_keep_year_reports
  10. delete_reports_keep_range_reports
  11. delete_reports_keep_segment_reports

  12. Read the following settings from config instead of option if delete old data admin UI is disabled

  13. delete_logs_enable
  14. delete_logs_schedule_lowest_interval
  15. delete_logs_older_than
  16. delete_logs_max_rows_per_query
  17. delete_reports_enable
  18. delete_reports_older_than
  19. delete_reports_keep_basic_metrics
  20. delete_reports_keep_day_reports
  21. delete_reports_keep_week_reports
  22. delete_reports_keep_month_reports
  23. delete_reports_keep_year_reports
  24. delete_reports_keep_range_reports
  25. delete_reports_keep_segment_reports

The values from the option table should overwrite the values from the config in case the delete old data admin UI is enabled. It should not be possible to set a value in the option table while the delete old data admin UI is disabled.

  1. Migrate entries from config to option database table:
  2. Following config settings to be stored in the DB using Option::set and Option::get
  3. Upgrade: convert config file values to the new format in db. Then explicitely remove the settings from config file.
  4. Values are cached in the file tmp/cache/tracker/ file for fast access during tracker mode using the existing hook to add to cache/tracker/x.php in case they are used during the tracker process

Here are the config settings that, should be removed in favor of Option::

  • use_anonymized_ip_for_visit_enrichment
  • ip_address_mask_length
  • [Branding] use_custom_logo

Note:

  • The "enabled" setting is already using Option:: mechanism.
Thomas Steur
Owner

In 883ecc8: refs #4563 moved custom logo from config to database

Thomas Steur
Owner

In 0e3592f: refs #4563 fix cached version was not used because there are more than 3 entries

Thomas Steur
Owner

In e36c596: refs #4563 PrivacyManager Settings should be in Config and Option table, also removed some completely from config as described in ticket

Thomas Steur
Owner

In 1d64882: refs #4563 make sure getting purge data settings works if UI is disabled

Matthieu Aubry
Owner

In e6af591: Refs #4563 Hiding message that config is not writable, when writing to the config file is disabled anyway.

Matthieu Aubry mattab added this to the 2.1 - Piwik 2.1 milestone
Thomas Steur tsteur was assigned by mattab
Philip Taffner sabl0r referenced this issue from a commit in sabl0r/piwik
Thomas Steur tsteur refs #4563 moved custom logo from config to database 883ecc8
Philip Taffner sabl0r referenced this issue from a commit in sabl0r/piwik
Thomas Steur tsteur refs #4563 fix cached version was not used because there are more tha…
…n 3 entries
0e3592f
Philip Taffner sabl0r referenced this issue from a commit in sabl0r/piwik
Thomas Steur tsteur refs #4563 PrivacyManager Settings should be in Config and Option tab…
…le, also removed some completely from config as described in ticket
e36c596
Philip Taffner sabl0r referenced this issue from a commit in sabl0r/piwik
Matthieu Aubry mattab Refs #4563 Hiding message that config is not writable, when writing t…
…o the config file is disabled anyway.
e6af591
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.