Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on Jul 28, 2024. It is now read-only.

MGDSoft/stackdriver-bundle

Open more actions menu

Repository files navigation

GoogleCloud Stackdriver Bundle Build Status

Log all records in Stackdriver using this bundle. Some features

  • Error reporting send notifications (by exception or log level error)
  • Create correct metadata from $_ENV vars
  • Auto create logname ${gcloud_service}-symfony.log
  • track logs from same request with label requestId
  • Track current user

Installation

This bundle use auto recipes from https://github.com/symfony/recipes-contrib, to enable execute

composer config extra.symfony.allow-contrib true

Install the bundle...

composer req mgdsoft/stackdriver-bundle

The bundle will be configured only for prod environment see packages/prod/mgdsoft_stackdriver.yaml for more info.

Inside appengine credentials are configured auto, but to test in local you must set mgdsoft_stackdriver.credentials_json_file

Finally configure like simple monolog service handler and enjoy it.

# /config/packages/prod/monolog.yaml
monolog:
    handlers:
        stack_driver:
            type: service
            id: MGDSoft\Stackdriver\Logger\Handler

By default all errors are reported, if you want to disable update bundle config

#./bin/console config:dump-reference MGDSoftStackdriverBundle

mgdsoft_stackdriver:
    credentials_json_file:  null
    log_name:               null
    level:                  info
    error_reporting:
        enabled:              true
        ignore_400:           true

All pull request are welcome ;-)

About

GoogleCloud Stackdriver Bundle

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.