Download the PHP package x-laravel/pulse-requests without Composer

On this page you can find all versions of the php package x-laravel/pulse-requests. 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 pulse-requests

Pulse Requests

A Laravel Pulse card that counts incoming requests by HTTP status class, split into the route groups you define.

Every handled request is counted as one of five classes: informational (1xx), successful (2xx), redirection (3xx), client_error (4xx) and server_error (5xx). You decide which requests are counted and how they are grouped, and the card draws one chart per group with a selector in its header.

Installation

Add the card to resources/views/vendor/pulse/dashboard.blade.php:

Register the recorder in config/pulse.php:

Every key is optional. An empty array records every request under a single all series.

The card

The header carries a Group selector whose options come from your configuration. All is the default and sums every configured group; picking a single group narrows the chart to it. When no groups are configured the selector is hidden and the card shows one series.

The selector lists what the configuration defines. A label you remove from groups disappears from the card even while its rows are still in the database, and it no longer counts towards All.

Configuration

Every option below lives in the recorder's entry in config/pulse.php.

What patterns run against

Every pattern in only, ignore and groups is a regular expression, and match decides what it is applied to:

match Pattern runs against
path (default) /events
host_path api.example.com/events

Use host_path when routes are split across subdomains rather than path prefixes:

[!WARNING] The ignore patterns in the installation example are written for path and start with ^/. Under host_path they match nothing, so rewrite them for the host, for example '#^monitor\.#'.

Which requests are counted

A request is recorded when it matches only and does not match ignore. While only is empty every request is a candidate:

The example counts the whole API except its health endpoint.

How requests are grouped

groups maps a pattern to a label, and the first match wins, so put the narrower pattern first:

A request matching no pattern is labelled with fallback, which defaults to other. Set fallback to null to drop those requests instead. While groups is empty every request is counted under a single all series.

Labels are written to Pulse's key column, so keep them to a small fixed set. A label built from the path itself grows pulse_aggregates without bound.

Sampling

Record a fraction of the traffic and let the card scale the numbers back up:

Sampled values are shown with a ~ prefix, the convention Pulse's own cards use.

Defaults

Every option may be left out. The recorder then falls back to these values:

Option Default Effect
enabled true Pulse skips the recorder entirely when false
sample_rate 1 Fraction of requests recorded
match path path or host_path
only [] Every request is a candidate
ignore [] Nothing is dropped, including your Pulse and Horizon traffic
groups [] Everything is counted under a single all series
fallback other Label for requests matching no group

How the data is stored

The recorder writes bucketed aggregates (->count()->onlyBuckets()): one counter per period, status class and group. No per-request rows are kept, so storage stays flat however much traffic the application takes.

The counter is bound to the RequestHandled event, so it covers every request Laravel finishes. A request killed mid-flight, by a PHP fatal error or a memory limit, never reaches it.

Publishing the view

Testing

Tests run against SQLite in memory and need no external services.

License

MIT. See LICENSE.md.


All versions of pulse-requests with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
illuminate/support Version ^12.0|^13.0
laravel/pulse Version ^1.0
livewire/livewire Version ^3.6.4|^4.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 x-laravel/pulse-requests contains the following files

Loading the files please wait ...