Download the PHP package farikd/mongodb-profiler-bundle without Composer

On this page you can find all versions of the php package farikd/mongodb-profiler-bundle. 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 mongodb-profiler-bundle

mongodb-profiler-bundle

A dev-only MongoDB query profiler for Symfony, for apps using the raw mongodb/mongodb driver (no Doctrine ODM). It hooks the driver's own command-monitoring API, so it sees every command issued in the process — direct collection()->find() calls, health-check pings, anything — regardless of which repository or service issued it.

It gives you:

It is dev/test tooling only. With enabled: false (or outside kernel.debug, its default), the bundle registers no services at all — a production container is identical to one without the package installed.

Requirements

Symfony 7.3 is not supported: it is end-of-life and every 7.3.x release carries unpatched security advisories, so Composer's default policy refuses to install it anyway.

symfony/web-profiler-bundle is optional — without it everything still works except the panel (the CLI summary, in particular, does not need it).

Installation

Configuration reference

All keys are optional; every default is shown below.

Routes

The bundle never registers routes itself — a bundle registering routes into an app regardless of environment is exactly the kind of surprise a dev-only tool must not cause. Import them yourself, scoped to dev/test:

This is what makes the panel's Explain button work; without it the panel still renders, just without that button.

Security

The explain endpoint lives under /_mongodb-profiler/. If your firewall guards everything by default, carve out an exception the same way the standard _profiler/_wdt paths already get one:

CLI usage

Set mongodb_profiler.cli: true to also profile console commands and messenger:consume workers — off by default, so ordinary crons and consumers pay nothing. With it on, every command prints a summary to stdout when it terminates (console.terminate):

Failed commands, duplicate/N+1 groups, and a capped-query warning are appended the same way they appear in the web panel. No config check gates the print itself: the subscriber only records anything in CLI when cli is true, so a non-empty count already means profiling was on, and a plain run records (and prints) nothing.

What it captures / what it ignores

Capture attaches at the MongoDB PHP driver's command-monitoring layer — the only hook that sees every command a process issues, direct collection()->countDocuments() calls and health-check pings included, with the driver's own measured duration for free.

A handful of connection-handshake / topology commands are ignored by default (see ignored_commands above): isMaster/ismaster, hello, saslStart/saslContinue, buildInfo, and getMore — internal chatter that is never something your code issued on purpose.

ping is deliberately not in that list. An application-issued ping (e.g. a health check that calls getDatabase()->command(['ping' => 1]) straight past its repository layer) is exactly the driver-level capture this profiler exists to prove works — and the PHP driver issues no background heartbeat pings of its own, so there is no noise to filter out by excluding it.


All versions of mongodb-profiler-bundle with dependencies

PHP Build Version
Package Version
Requires php Version >=8.4
ext-mongodb Version *
mongodb/mongodb Version ^2.0
symfony/config Version ^7.4 || ^8.0
symfony/console Version ^7.4 || ^8.0
symfony/dependency-injection Version ^7.4 || ^8.0
symfony/event-dispatcher Version ^7.4 || ^8.0
symfony/framework-bundle Version ^7.4 || ^8.0
symfony/http-foundation Version ^7.4 || ^8.0
symfony/http-kernel Version ^7.4 || ^8.0
symfony/routing Version ^7.4 || ^8.0
symfony/twig-bundle Version ^7.4 || ^8.0
twig/twig Version ^3.10
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 farikd/mongodb-profiler-bundle contains the following files

Loading the files please wait ...