github getsentry/sentry-php 4.4.0

latest releases: 4.10.0, 4.9.0, 4.8.1...
9 months ago

The Sentry SDK team is happy to announce the immediate availability of Sentry PHP SDK v4.4.0.

Features

  • Add metrics()->timing() (#1670)

    This allows you to emit a distribution metric based on the duration of the provided callback.

    use function Sentry\metrics;
    
    metrics()->timing(
        key: 'my-metric',
        callback: fn() => doSomething(),
    );
  • Add withMonitor() (#1679)

    This wraps a callback into monitor check-ins.

    use function Sentry\withMonitor;
    
    withMonitor(
        slug: 'my-monitor',
        callback: fn () => doSomething(),
        monitorConfig: new MonitorConfig(...),
    );
  • Add new failure_issue_threshold and recovery_threshold configuration to MonitorConfig (#1685)

  • Add TransactionContext::make() and SpanContext::make() (#1684)

    use Sentry\Tracing\SpanContext;
    
    $spanCpntext = SpanContext::make()
        ->setOp('http.client')
        ->setDescription('GET https://example.com')
  • Add support for fluent use of Transaction::setName() (#1687)

  • Add support for the W3C traceparent header (#1680)

Bug Fixes

  • Do not send an empty event if no metrics are in the bucket (#1676)

  • Fix the http_ssl_verify_peer option to set the correct value to CURLOPT_SSL_VERIFYPEER (#1686)

Misc

  • Depreacted UserDataBag::getSegment() and UserDataBag::setSegment(). You may use a custom tag or context instead (#1681)

Don't miss a new sentry-php release

NewReleases is sending notifications on new releases.