Download the PHP package 0to10/observability-php without Composer
On this page you can find all versions of the php package 0to10/observability-php. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download 0to10/observability-php
More information about 0to10/observability-php
Files in 0to10/observability-php
Package observability-php
Short Description Library to simplify customising observability integrations in PHP projects.
License MIT
Informations about the package observability-php
Observability library for PHP
This package aims to make it easier to monitor your application by generalising frequently used methods to customise how you instrument your code.
Getting started
Getting started is usually easy: just follow the instructions below.
Installation
Use Composer to install this library into your project:
Basic usage
Below is the high-level documentation of how to work with this library.
Working with transactions
A Transaction is a logical unit of work in a software application. This might be handling a request and sending a response (in a Web transaction), executing a script that handles some piece of business logic, etc.
This library exposes a helper class via the transaction()
method of a
Client
instance that can be used to customise monitoring of a transaction.
The methods of the returned class are documented in TransactionInterface
.
Real-user monitoring
Real-user monitoring (RUM) may be customised by calling the browser()
method
of a Client
instance.
Automatic instrumentation (e.g. automatic injection of browser scripts in the header and footer of a page) may be disabled using the following method:
Note that this must be done before any output is sent to the browser, and that it's more stable to disable RUM as part of your PHP configuration (if available).
Legacy usage
Library versions up to 2.0.0 continue to support using the Client
class located
in the Nouve\APM
namespace. Please do not use this method for new projects.
Usage notes
It is important to understand that this library exposes generic methods to adjust observability within projects. Depending on the capabilities of the used observability tool, methods may not have the desired outcome. Always make sure that you understand the impact of customising your setup before publishing this into any production environment.