public static function load()
    {
        if (!extension_loaded('opencensus')) {
            trigger_error('opencensus extension required to load Symfony integrations.', E_USER_WARNING);
            return;
        }

        Doctrine::load();

        // public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true)
        opencensus_trace_method(HttpKernel::class, 'handle', function ($kernel, $request) {
            return [
                'name' => 'kernel/handle'
            ];
        });

        // public function dispatch($eventName, Event $event = null)
        opencensus_trace_method(EventDispatcher::class, 'dispatch', function ($dispatcher, $eventName) {
            return [
                'name' => $eventName,
                'attributes' => ['eventName' => $eventName]
            ];
        });
    }