modera / activity-logger-bundle
Installs: 4 680
Dependents: 1
Suggesters: 0
Security: 0
Stars: 4
Watchers: 9
Forks: 0
Open Issues: 0
Type:symfony-bundle
Requires
- php: >=5.6
- doctrine/doctrine-bundle: ^1.6|^2.0
- doctrine/orm: ^2.5
- sergeil/extjsintegration-bundle: ^2.0
- symfony/framework-bundle: ^3.4|^4.0
Requires (Dev)
- modera/foundation-bundle: ~3.1
- phpunit/phpunit: ^5.5
- dev-master / 4.x-dev
- 3.x-dev
- v3.1.0
- v3.0.0
- 2.x-dev
- v2.57.0
- v2.56.0
- v2.55.0
- v2.54.0
- v2.53.0
- v2.52.2
- v2.52.1
- v2.52.0
- v2.51.1
- v2.51.0
- v2.0.50
- dev-sf3
- dev-MPFE-1005
- dev-MPFE-1007
- dev-MPFE-1014
- dev-MPFE-1014-2
- dev-MPFE-1017
- dev-MPFE-1029
- dev-MPFE-963
- dev-MPFE-975
- dev-MPFE-977
- dev-crub_pagination_fetch_fix
- dev-direct-bundle-csrf
This package is auto-updated.
Last update: 2024-11-29 04:19:46 UTC
README
Bundle provides facilities that let you to log different domain events that occur during your application logic execution, later you are able to query those logged events ( they are called Activities in scope of this bundle ). The point here is that later those activities can be reviewed by ordinary users to see what has been happening in the system.
Unless you need to query activities in your application logic please rely on a generic Psr's LoggerInterface interface to log your activities.
Installation
Step 1: Download the Bundle
composer require modera/activity-logger-bundle:4.x-dev
This command requires you to have Composer installed globally, as explained in the installation chapter of the Composer documentation.
Step 2: Enable the Bundle
This bundle should be automatically enabled by Flex.
In case you don't use Flex, you'll need to manually enable the bundle by
adding the following line in the config/bundles.php
file of your project:
<?php // config/bundles.php return [ // ... Modera\ActivityLoggerBundle\ModeraActivityLoggerBundle::class => ['all' => true], ];
Documentation
To log your activities you will be using an implementation of standard Psr\Log\LoggerInterface
interface which
means that your application won't directly depend on this bundle but rather will rely on a generic interface that later
you can switch ( say that you decided to use some default Monolog log handler ) if needed.
Bundle declares two additional interfaces - Modera\ActivityLoggerBundle\Manager\ActivityManagerInterface
and
Modera\ActivityLoggerBundle\Model\ActivityInterface
. The former extends Psr's LoggerInterface and adds one method -
"query", this method can be used to query activities. Activities returned by this method are implementations of
ActivityInterface. By default the bundle provides one implementation of ActivityManagerInterface which stores activities
using Doctrine ORM's EntityManager - Modera\ActivityLoggerBundle\Manager\DoctrineOrmActivityManager
.
Licensing
This bundle is under the MIT license. See the complete license in the bundle: Resources/meta/LICENSE