83% docket-cache

Code Review | Docket Cache - Object Cache Accelerator

WordPress plugin Docket Cache - Object Cache Accelerator scored83%from 54 tests.

About plugin

  • Plugin page: docket-cache
  • Plugin version: 23.08.02
  • PHP compatiblity: 7.2.5+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4-6.4
  • WordPress version: 6.3.1
  • First release: Jul 8, 2020
  • Latest release: Nov 13, 2023
  • Number of updates: 307
  • Update frequency: every 4.0 days
  • Top authors: nawawijamili (100%)

Code review

54 tests

User reviews

43 reviews

Install metrics

10,000+ active /114,416 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▲2.11MB] [CPU: ▲16.84ms] 75% from 4 tests

A check of server-side resources used by Docket Cache - Object Cache Accelerator
Please take the time to fix the following items
  • RAM: You should keep total memory usage under 10MB (currently 10.22MB on /wp-admin/admin.php?page=docket-cache-config)
PageMemory (MB)CPU Time (ms)
Home /5.38 ▲1.9154.91 ▲14.11
Dashboard /wp-admin5.45 ▲2.1565.44 ▲18.48
Posts /wp-admin/edit.php5.54 ▲2.1856.44 ▲13.18
Add New Post /wp-admin/post-new.php8.08 ▲2.19114.01 ▲21.58
Media Library /wp-admin/upload.php5.78 ▲2.5557.91 ▲24.20
Cronbot /wp-admin/admin.php?page=docket-cache-cronbot10.12131.42
Overview /wp-admin/admin.php?page=docket-cache10.16153.51
Configuration /wp-admin/admin.php?page=docket-cache-config10.22210.91

Server storage [IO: ▲0.80MB] [DB: ▼0.50MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
These are issues you should consider
  • There were 62 files (1,032.50KB) illegally modified outside of "wp-content/plugins/docket-cache/" and "wp-content/uploads/"
    • (new file) wp-content/cache/docket-cache/18958e30bdca-eccbc87e4b5c.php
    • (new file) wp-content/cache/docket-cache/0700cd3e2cd8-1099e974c19d.php
    • (new file) wp-content/cache/docket-cache/18958e30bdca-d3d9446802a4.php
    • (new file) wp-content/cache/docket-cache/18958e30bdca-c4ca4238a0b9.php
    • (new file) wp-content/cache/docket-cache/3e81e7e6a880-94cba8bbe64a.php
    • (new file) wp-content/cache/docket-cache/06d4cd63bde9-fd8e2a29bf96.php
    • (new file) wp-content/cache/docket-cache/26dbb02c7545-c4ca4238a0b9.php
    • (new file) wp-content/cache/docket-cache/18958e30bdca-fd8e2a29bf96.php
    • (new file) wp-content/cache/docket-cache/06d4cd63bde9-c4ca4238a0b9.php
    • (new file) wp-content/cache/docket-cache/36bbcaedce2d-c4ca4238a0b9.php
    • ...
Filesystem: 88 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Docket Cache - Object Cache Accelerator
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,859 ▲11214.36 ▼0.371.76 ▲0.0041.88 ▼4.53
Dashboard /wp-admin2,283 ▲1145.71 ▼0.02102.13 ▼17.9946.20 ▼1.88
Posts /wp-admin/edit.php2,215 ▲1152.02 ▲0.0637.39 ▲0.3034.89 ▲1.78
Add New Post /wp-admin/post-new.php1,557 ▲3123.43 ▲0.20701.09 ▲43.5757.37 ▲9.16
Media Library /wp-admin/upload.php1,521 ▲1214.32 ▲0.13120.80 ▲20.7246.24 ▲5.44
Cronbot /wp-admin/admin.php?page=docket-cache-cronbot1,3822.0531.8833.41
Overview /wp-admin/admin.php?page=docket-cache1,1272.1635.0826.54
Configuration /wp-admin/admin.php?page=docket-cache-config3,0802.0931.1253.79

Uninstaller [IO: ▲0.03MB] [DB: ▼0.18MB] 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 were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Polyfill\\Php80\\PhpToken' not found in wp-content/plugins/docket-cache/includes/vendor/symfony/polyfill-php80/Resources/stubs/PhpToken.php:13
    • > PHP Fatal error
      Uncaught Error: Interface 'Nawawi\\Symfony\\Component\\VarExporter\\Exception\\ExceptionInterface' not found in wp-content/plugins/docket-cache/includes/vendor/symfony/var-exporter/Exception/NotInstantiableTypeException.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'Nawawi\\Symfony\\Component\\VarExporter\\Exception\\ExceptionInterface' not found in wp-content/plugins/docket-cache/includes/vendor/symfony/var-exporter/Exception/ClassNotFoundException.php:14
    • > PHP Fatal error
      Uncaught Error: Interface 'Stringable' not found in wp-content/plugins/docket-cache/includes/vendor/symfony/polyfill-php80/PhpToken.php:19

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
9 plugin tags: performance, speed, object cache, opcache, database...

docket-cache/docket-cache.php Passed 13 tests

The main file in "Docket Cache - Object Cache Accelerator" v. 23.08.02 serves as a complement to information provided in readme.txt and as the entry point to the plugin
95 characters long description:
A persistent object cache stored as a plain PHP code, accelerates caching with OPcache backend.

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected16,243 lines of code in 72 files:
LanguageFilesBlank linesComment linesLines of code
PHP663,2673,13615,087
CSS217239826
JavaScript34224329
HTML1001

PHP code 50% from 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Please tend to the following items
  • Method cyclomatic complexity has to be reduced to less than 100 (currently 101)
Cyclomatic complexity
Average complexity per logical line of code0.51
Average class complexity60.04
▷ Minimum class complexity1.00
▷ Maximum class complexity374.00
Average method complexity5.41
▷ Minimum method complexity1.00
▷ Maximum method complexity101.00
Code structure
Namespaces7
Interfaces2
Traits0
Classes44
▷ Abstract classes00.00%
▷ Concrete classes44100.00%
▷ Final classes2352.27%
Methods572
▷ Static methods7412.94%
▷ Public methods43275.52%
▷ Protected methods61.05%
▷ Private methods13423.43%
Functions207
▷ Named functions5928.50%
▷ Anonymous functions14871.50%
Constants18
▷ Global constants1055.56%
▷ Class constants844.44%
▷ Public constants8100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There were not PNG files found in your plugin