Download the PHP package 2a/symfony-performance-analyzer without Composer

On this page you can find all versions of the php package 2a/symfony-performance-analyzer. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package symfony-performance-analyzer

Symfony Performance Analyzer Bundle

PHP Version Symfony Version Build Status Coverage

A powerful toolkit for monitoring and optimizing Symfony applications, offering real-time performance metrics, N+1 query detection, cognitive complexity analysis, automated reporting, a secure web dashboard, and seamless CI/CD integration.

Features

Installation

Install the bundle via Composer:

Enable the bundle in config/bundles.php:

Generate and apply database migrations (for database storage):

Install assets for the web dashboard:

Configuration

Create a configuration file at config/packages/symfony_performance_analyzer.yaml:

For file-based storage, ensure the storage directory is writable:

Usage

CLI Commands

Analyze performance and generate reports:

Example JSON report output:

Web Dashboard

Access the performance dashboard at /_performance. Secure it by enabling the firewall and restricting IP access:

Customize the dashboard route in config/routes.yaml:

Debug Toolbar

The bundle integrates with Symfony’s debug toolbar, displaying request time, query count, memory usage, and performance issues. Enable it in the configuration:

Performance Metrics

The bundle collects and analyzes the following metrics:

Metric Description Expected Range Source
Request Time HTTP request execution time 0–500 ms PerformanceTracker, Timer
Database Queries Query count, duration, and N+1 issues 0–50 queries DatabaseQueryCollector, QueryAnalyzer
Memory Usage Peak memory consumption 0–256 MB MemoryAnalyzer
Cognitive Complexity Code complexity score 0–10 CognitiveComplexityAnalyzer
CLI Performance Command execution time 0–5000 ms PerformanceTracker
Issues Performance violations detected 0–10 issues AnalysisResult

Custom Analyzers

Create a custom analyzer by implementing AnalyzerInterface:

Register the analyzer in config/services.yaml:

Custom Collectors

Create a custom collector by implementing CollectorInterface:

Register the collector:

Performance Considerations

Testing

Run the test suite:

Perform static analysis and linting:

The bundle includes:

Uninstallation

Remove the bundle:

Drop database tables (if using database storage):

Remove configuration files and assets:

Contributing

  1. Fork the repository.
  2. Create a feature branch: git checkout -b feature/my-feature
  3. Commit changes: git commit -am 'Add my feature'
  4. Push to the branch: git push origin feature/my-feature
  5. Open a Pull Request.

Ensure all tests pass and adhere to coding standards (ECS, Rector, PHPStan).

License

This bundle is licensed under the MIT License. See the LICENSE file for details.


All versions of symfony-performance-analyzer with dependencies

PHP Build Version
Package Version
Requires php Version >=8.3
symfony/framework-bundle Version ^7.0
nikic/php-parser Version ^5.0
doctrine/orm Version ^3.0
symfony/asset Version ^6.0|^7.0
symfony/console Version ^7.0
symfony/dependency-injection Version ^6.0|^7.0
symfony/http-kernel Version ^6.0|^7.0
symfony/twig-bundle Version ^7.0
guzzlehttp/guzzle Version ^7.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package 2a/symfony-performance-analyzer contains the following files

Loading the files please wait ....