damejidlo / newrelic
This package is abandoned and no longer maintained.
No replacement package was suggested.
Newrelic integration into Nette Framework
3.0.1
2019-09-09 16:28 UTC
Requires
- php: >=7.2
- nette/application: ^2.4
- nette/di: ^2.4.10
- nette/http: ^2.4.7
- nette/utils: ^2.4.5
Requires (Dev)
- damejidlo/coding-standard: ^1.1.0
- jakub-onderka/php-parallel-lint: ^1.0
- nette/bootstrap: ^2.4
- nette/component-model: ^2.3.1
- nette/tester: ^2.2.0
- phpstan/phpstan-nette: ^0.11.1
- phpstan/phpstan-shim: ^0.11.12
- phpstan/phpstan-strict-rules: ^0.11.1
README
Install
composer require damejidlo/newrelic
Configure
Register NewRelicExtension
in your config:
extensions: newrelic: Damejidlo\NewRelic\DI\NewRelicExtension(%consoleMode%) newrelic: applicationName: fooBar applicationModules: web: '/api/': Api '/admin/': Admin '': Front console: 'bin/foo.php ': Foo '': Console autorum: FALSE customTracers: - 'Doctrine\ORM\EntityManager::flush'
Put $_ENV
settings (something like this) into index.php
:
<?php $_ENV['REQUEST_TIME_FLOAT'] = microtime(TRUE); $container = require __DIR__ . '/../app/bootstrap.php'; $_ENV['COMPILATION_TIME_FLOAT'] = microtime(TRUE); $container->getByType(\Nette\Application\Application::class)->run();