Skip to content

Commit

Permalink
add example of formatter configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
ftdebugger committed Dec 5, 2013
1 parent e58ce04 commit 3f61583
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,13 @@ By default it write logs to `data/logs/application.log`. If you want change this
'path' => 'data/log/application.log',
'level' => \Monolog\Logger::DEBUG,
'bubble' => true
)
),
'formatter' => array(
'name' => 'Monolog\Formatter\LogstashFormatter',
'args' => array(
'application' => 'My Application',
),
),
),

// by service locator
Expand Down
2 changes: 1 addition & 1 deletion src/EnliteMonolog/Service/MonologServiceFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public function createHandler(ServiceLocatorInterface $serviceLocator, $handler)

/**
* @param ServiceLocatorInterface $serviceLocator
* @param string|array $handler
* @param string|array $formatter
* @return FormatterInterface
*
* @throws RuntimeException
Expand Down

0 comments on commit 3f61583

Please sign in to comment.