Download the PHP package castiron/typo3-plugin-rollbar without Composer
On this page you can find all versions of the php package castiron/typo3-plugin-rollbar. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download castiron/typo3-plugin-rollbar
More information about castiron/typo3-plugin-rollbar
Files in castiron/typo3-plugin-rollbar
Package typo3-plugin-rollbar
Short Description A Rollbar integration for TYPO3 (https://rollbar.com)
License GPL-2.0+
Homepage https://github.com/castiron/typo3-plugin-rollbar
Informations about the package typo3-plugin-rollbar
Rollbar integration for TYPO3
This is more or less the Rollbar library with autoload and config conventions.
A note on composer mode
To make this plugin compatible with TYPO3 installations in both
"Composer mode" and legacy non-Composer mode, we cannot
"require" Rollbar automatically in composer.json
(sorry!). That's because, even in non-composer mode, TYPO3 (v6, for
example) will throw an error that rollbar/rollbar
is not present in the system, because (apparently) TYPO3 reads the
composer.json
file and tries to understand dependencies based on it, regardless of which mode you're using.
So: If you include this plugin via Composer (using Composer mode), you will need to manually include the dependency
rollbar/rollbar
along with it -- it will be suggested but not auto-installed as a dependency.
A note on autoloading (non-Composer mode)
We don't include the Rollbar library with this extension. If you're including this plugin the old-school way (through the extension manager, or via a Git submodule), you won't have the Rollbar library or its internal dependencies on hand. You must autoload them with Composer. One way to do this is like so:
- Add composer.json to your project root, adding
rollbar/rollbar
as a dependency composer install
- Include the composer
vendor/autoload.php
in the project byrequire_once
ing it from the top of the filetypo3conf/AdditionalConfiguration.php
. - If you're using a deployment system (like Capistrano) or other automated deployment approach, you'll need to be sure
and add a
composer install
step to your deployments :wink:
Quick start
The config can be specified like
Put that in your typo3conf/AdditionalConfiguration.php
. In general, stuff you put in there is passed directly to
Rollbar::init()
, so you can use
any of the options supported by Rollbar::init()
NB: The "root" config value (for path mapping with your SCM repo) will be automatically assigned to PATH_site
for you,
unless you override it by specifying a value yourself.
If you're using the default set_exception_handler=false
and set_error_handler=false
:
- You'll still get any fatal errors automatically
- You can manually catch/report exceptions like so:
TYPO3 Content Object Renderer exceptions
Sometimes the TYPO3 core ContentObjectRenderer
throws exceptions, which, in production, is amazing because your user,
on the frontend, will see something like,
Oops, an error occurred! Code: 201705082151141a71f8db
And no other exception will be thrown, nor logged. :sweat:
To remedy this you've got to add a little typoscript to your site. Under the "Includes" tab on your main typoscript
template, add the Rollbar Content Exception Handling
typoscript.
Best of luck to you in all your endeavors.