PriviMetrics 1.0.6 Released! What’s New?

In today's update, we have introduced Extension Support and launched the PriviMetrics Marketplace. From now on, you can expand the capabilities of PriviMetrics with new features and enhancements tailored to your needs.


How the Extension System Works

The new version of PriviMetrics introduces a new infrastructure for managing and running third-party plugins. Here is a breakdown of the core components:

1. The Management Interface (Extensions Manager)

The administration panel now includes a dedicated extensions.php interface. This module handles the entire lifecycle of every extension:

  • Installation: You can upload extensions as .zip files. The system automatically validates the package, checks the manifest.json for metadata (name, version, author).

  • Version Control: The manager automatically detects if you are uploading a newer version of an existing extension and handles the update process by replacing old files.

  • Status Control: You can quickly toggle extensions "Active" or "Inactive" or delete them entirely via the UI.

2. The Extension Loader (The Engine)

Behind the scenes, the Extension Loader acts as the brain of the system.

  • Automatic Bootstrapping: Every time PriviMetrics runs, the loader reads an extensions.xml file to see which plugins are enabled and includes their main.php files.

  • The Kill Switch: For troubleshooting, there is an emergency "global off" feature. By creating a specific text file (extensions_off.txt), all extensions are immediately bypassed to restore system stability.

3. Hook System & Integration

Extensions interact with the core of PriviMetrics through Hooks. This allows developers to "inject" code at specific execution points, such as:

  • Before or after the Dashboard initializes.

  • Before or after analytics data is saved.

  • Adding custom widgets to the UI or new tabs to the settings menu.