Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▼0.47MB] [CPU: ▼31.70ms] Passed 4 tests
A check of server-side resources used by Fantastic ElasticSearch
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.88 ▲0.42 | 46.93 ▲2.67 |
Dashboard /wp-admin | 3.47 ▲0.17 | 38.40 ▼17.84 |
Posts /wp-admin/edit.php | 3.47 ▲0.12 | 27.16 ▼23.04 |
Add New Post /wp-admin/post-new.php | 3.47 ▼2.42 | 29.34 ▼82.78 |
Media Library /wp-admin/upload.php | 3.47 ▲0.24 | 31.80 ▼3.15 |
Field Mapping /wp-admin/admin.php?page=elastic_search&tab=field | 3.47 | 32.67 |
Content Indexing /wp-admin/admin.php?page=elastic_search&tab=content | 3.47 | 31.01 |
Manage Index /wp-admin/admin.php?page=elastic_search&tab=index | 3.47 | 30.73 |
Wordpress Integration /wp-admin/admin.php?page=elastic_search&tab=integration | 3.47 | 30.10 |
Result Scoring /wp-admin/admin.php?page=elastic_search&tab=scoring | 3.47 | 29.25 |
Server Settings /wp-admin/admin.php?page=elastic_search&tab=server | 3.47 | 32.28 |
/wp-admin/admin.php?page=elastic_search | 3.47 | 26.83 |
Server storage [IO: ▲4.73MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 1,007 new files
Database: no new tables, 10 new options
New WordPress options |
---|
theysaidso_admin_options |
can_compress_scripts |
recovery_mode_email_last_sent |
widget_recent-posts |
elasticsearch |
widget_recent-comments |
db_upgraded |
widget_facetingoptionswidget |
widget_theysaidso_widget |
widget_factingselectedwidget |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Fantastic ElasticSearch
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,836 ▲75 | 14.22 ▼0.40 | 1.71 ▲0.06 | 45.28 ▲1.79 |
Dashboard /wp-admin | 2,242 ▲62 | 5.64 ▼0.03 | 85.88 ▼4.88 | 70.67 ▲23.56 |
Posts /wp-admin/edit.php | 2,150 ▲47 | 1.97 ▼0.04 | 36.32 ▼1.44 | 35.08 ▼2.60 |
Add New Post /wp-admin/post-new.php | 45 ▼1,481 | 0.42 ▼23.14 | 0.11 ▼714.64 | 9.41 ▼46.61 |
Media Library /wp-admin/upload.php | 1,444 ▲44 | 4.19 ▼0.03 | 109.88 ▲7.11 | 77.73 ▲34.71 |
Field Mapping /wp-admin/admin.php?page=elastic_search&tab=field | 1,323 | 2.33 | 30.98 | 40.55 |
Content Indexing /wp-admin/admin.php?page=elastic_search&tab=content | 1,341 | 2.45 | 33.05 | 39.58 |
Manage Index /wp-admin/admin.php?page=elastic_search&tab=index | 1,323 | 2.30 | 35.51 | 35.51 |
Wordpress Integration /wp-admin/admin.php?page=elastic_search&tab=integration | 1,323 | 2.33 | 32.27 | 39.75 |
Result Scoring /wp-admin/admin.php?page=elastic_search&tab=scoring | 1,323 | 2.45 | 31.53 | 42.29 |
Server Settings /wp-admin/admin.php?page=elastic_search&tab=server | 1,319 | 2.32 | 32.80 | 36.04 |
/wp-admin/admin.php?page=elastic_search | 1,305 | 2.11 | 25.84 | 29.12 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
- The plugin did not uninstall gracefully
- > Deprecated in wp-content/plugins/fantastic-elasticsearch/wp/lib/nhp/options/options.php+226
Function create_function() is deprecated
- Zombie WordPress options detected upon uninstall: 10 options
- widget_recent-posts
- db_upgraded
- theysaidso_admin_options
- widget_recent-comments
- widget_facetingoptionswidget
- widget_theysaidso_widget
- elasticsearch
- can_compress_scripts
- widget_factingselectedwidget
- recovery_mode_email_last_sent
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
- 1176 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=elastic_search
- > Deprecated in wp-content/plugins/fantastic-elasticsearch/wp/lib/nhp/options/options.php+237
Function create_function() is deprecated
- 28 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=elastic_search
- > Warning in wp-content/plugins/fantastic-elasticsearch/wp/lib/nhp/options/fields/multi_checkbox/field_multi_checkbox.php+40
Illegal string offset 'post_content'
- 28 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=elastic_search
- > Warning in wp-content/plugins/fantastic-elasticsearch/wp/lib/nhp/options/fields/multi_checkbox/field_multi_checkbox.php+37
Cannot assign an empty string to a string offset
- 28 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=elastic_search
- > Notice in wp-content/plugins/fantastic-elasticsearch/wp/lib/nhp/options/fields/multi_checkbox/field_multi_checkbox.php+40
Uninitialized string offset: 0
- 28 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=elastic_search
- > Warning in wp-content/plugins/fantastic-elasticsearch/wp/lib/nhp/options/fields/multi_checkbox/field_multi_checkbox.php+40
Illegal string offset 'post_title'
SRP 0% 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 fix the following
- 2× PHP files output text when accessed directly:
- > /wp-content/plugins/fantastic-elasticsearch/vendor/jeremykendall/php-domain-parser/tests/bootstrap.php
- > /wp-content/plugins/fantastic-elasticsearch/vendor/electrolinux/phpquery/demo.php
- 424× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Elastica\\Param' not found in wp-content/plugins/fantastic-elasticsearch/vendor/ruflin/elastica/lib/Elastica/AbstractUpdateAction.php:13
- > PHP Fatal error
Uncaught Error: Class 'Elastica\\Query\\AbstractQuery' not found in wp-content/plugins/fantastic-elasticsearch/vendor/ruflin/elastica/lib/Elastica/Query/SimpleQueryString.php:10
- > PHP Fatal error
Uncaught Error: Call to undefined function elasticsearch\\add_action() in wp-content/plugins/fantastic-elasticsearch/wp/admin/sections/manage-index.php:4
- > PHP Fatal error
Uncaught Error: Class 'Elastica\\Filter\\AbstractFilter' not found in wp-content/plugins/fantastic-elasticsearch/vendor/ruflin/elastica/lib/Elastica/Filter/BoolFilter.php:17
- > PHP Fatal error
Uncaught Error: Class 'Purl\\AbstractPart' not found in wp-content/plugins/fantastic-elasticsearch/vendor/jwage/purl/src/Purl/Url.php:23
- > PHP Fatal error
Uncaught Error: Class 'Elastica\\Test\\Base' not found in wp-content/plugins/fantastic-elasticsearch/vendor/ruflin/elastica/test/lib/Elastica/Test/Query/ConstantScoreTest.php:14
- > PHP Fatal error
Uncaught Error: Class 'Elastica\\Test\\Base' not found in wp-content/plugins/fantastic-elasticsearch/vendor/ruflin/elastica/test/lib/Elastica/Test/ClusterTest.php:9
- > PHP Fatal error
Uncaught Error: Interface 'Elastica\\Exception\\ExceptionInterface' not found in wp-content/plugins/fantastic-elasticsearch/vendor/ruflin/elastica/lib/Elastica/Exception/ClientException.php:10
- > PHP Fatal error
Uncaught Error: Class 'PHPUnit_Framework_TestCase' not found in wp-content/plugins/fantastic-elasticsearch/vendor/jeremykendall/php-domain-parser/tests/library/Pdp/PublicSuffixListTest.php:5
- > PHP Fatal error
Uncaught Error: Class 'Elastica\\Test\\Base' not found in wp-content/plugins/fantastic-elasticsearch/vendor/ruflin/elastica/test/lib/Elastica/Test/Cluster/Health/ShardTest.php:8
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
8 plugin tags: search, elasticsearch, facet, faceting, performance...
fantastic-elasticsearch/elasticsearch.php 92% from 13 tests
Analyzing the main PHP file in "Fantastic ElasticSearch" version 4.1.0
The following require your attention:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("fantastic-elasticsearch.php" instead of "elasticsearch.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin124,104 lines of code in 606 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 506 | 38,849 | 31,829 | 103,354 |
HTML | 23 | 1,299 | 0 | 14,142 |
JavaScript | 13 | 715 | 516 | 2,479 |
Markdown | 12 | 496 | 0 | 1,380 |
CSS | 4 | 133 | 170 | 1,067 |
XML | 17 | 14 | 0 | 582 |
JSON | 8 | 0 | 0 | 312 |
Bourne Shell | 7 | 111 | 16 | 266 |
Ant | 2 | 29 | 6 | 232 |
make | 1 | 36 | 22 | 125 |
YAML | 8 | 32 | 24 | 121 |
Dockerfile | 4 | 20 | 18 | 43 |
Groovy | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
Analyzing 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 code | 0.19 |
Average class complexity | 6.58 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 558.00 |
Average method complexity | 1.93 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 59.00 |
Code structure | ||
---|---|---|
Namespaces | 52 | |
Interfaces | 11 | |
Traits | 2 | |
Classes | 477 | |
▷ Abstract classes | 31 | 6.50% |
▷ Concrete classes | 446 | 93.50% |
▷ Final classes | 0 | 0.00% |
Methods | 2,938 | |
▷ Static methods | 190 | 6.47% |
▷ Public methods | 2,778 | 94.55% |
▷ Protected methods | 141 | 4.80% |
▷ Private methods | 19 | 0.65% |
Functions | 101 | |
▷ Named functions | 63 | 62.38% |
▷ Anonymous functions | 38 | 37.62% |
Constants | 190 | |
▷ Global constants | 10 | 5.26% |
▷ Class constants | 180 | 94.74% |
▷ Public constants | 180 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
364 compressed PNG files occupy 0.11MB
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
wp/lib/nhp/options/img/glyphicons/glyphicons_196_circle_exclamation_mark.png | 0.26KB | 0.29KB | 0.00% |
wp/lib/nhp/options/img/glyphicons/glyphicons_252_oxygen_bottle.png | 0.18KB | 0.21KB | 0.00% |
wp/lib/nhp/options/img/glyphicons/glyphicons_321_twitter_t.png | 0.18KB | 0.21KB | 0.00% |
wp/lib/nhp/options/img/glyphicons/glyphicons_265_electrical_plug.png | 0.21KB | 0.24KB | 0.00% |
wp/lib/nhp/options/img/glyphicons/glyphicons_013_beach_umbrella.png | 0.41KB | 0.47KB | 0.00% |