84% mysql-query-cache-stats

Code Review | MyQSL query cache stats

WordPress plugin MyQSL query cache stats scored84%from 54 tests.

About plugin

  • Plugin page: mysql-query-cache...
  • Plugin version: 1.0.4
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-6.3
  • WordPress version: 6.3.1
  • First release: Sep 23, 2020
  • Latest release: Oct 21, 2023
  • Number of updates: 39
  • Update frequency: every 28.8 days
  • Top authors: morisdov (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /843 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼13.58ms] Passed 4 tests

Analyzing server-side resources used by MyQSL query cache stats
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0236.83 ▼0.20
Dashboard /wp-admin3.39 ▲0.0446.09 ▼12.69
Posts /wp-admin/edit.php3.38 ▲0.0243.26 ▼11.22
Add New Post /wp-admin/post-new.php5.91 ▲0.0280.22 ▼30.19
Media Library /wp-admin/upload.php3.26 ▲0.0237.28 ▲6.34

Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] Passed 3 tests

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for MyQSL query cache stats
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,858 ▲9714.35 ▼0.011.71 ▲0.1639.51 ▼1.44
Dashboard /wp-admin2,267 ▲935.67 ▲0.1087.15 ▼0.7644.97 ▲5.38
Posts /wp-admin/edit.php2,100 ▼31.98 ▼0.0637.59 ▼3.8533.08 ▼3.17
Add New Post /wp-admin/post-new.php1,526 ▼922.98 ▲5.16680.88 ▲81.8151.79 ▼13.48
Media Library /wp-admin/upload.php1,400 ▼04.23 ▼0.0194.39 ▼0.5141.34 ▼0.22

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/mysql-query-cache-stats/mysql-query-cache-stats.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
5 plugin tags: mariadb, performance, tuning, mysql, wp_options

mysql-query-cache-stats/mysql-query-cache-stats.php Passed 13 tests

The main file in "MyQSL query cache stats" v. 1.0.4 serves as a complement to information provided in readme.txt and as the entry point to the plugin
49 characters long description:
Dashboard widget for MySQL query cache statistics

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin154 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP21826131
CSS12023

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions375.00%
▷ Anonymous functions125.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There are no PNG files in this plugin