From 625716e5a605bc2c605ec416e4e81dee31a34563 Mon Sep 17 00:00:00 2001 From: janwebdev Date: Thu, 11 Jun 2020 15:58:02 +0300 Subject: [PATCH 01/10] Update composer.json --- composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index 04a6e1e..99efa84 100644 --- a/composer.json +++ b/composer.json @@ -21,7 +21,7 @@ "require": { "php": ">=5.4", "doctrine/orm": "^2.2", - "doctrine/doctrine-bundle": "^1.2", + "doctrine/doctrine-bundle": "^2.1", "symfony/framework-bundle": "^2.1|^3.0|^4.0", "symfony/twig-bundle": "^2.0|^3.0|^4.0", "twig/twig": "^1.12|^2.0" @@ -31,4 +31,4 @@ "Debesha\\DoctrineProfileExtraBundle\\": "." } } -} \ No newline at end of file +} From af296625045e08a9faf30f18cb7ca2817d61fe14 Mon Sep 17 00:00:00 2001 From: janwebdev Date: Thu, 11 Jun 2020 16:05:11 +0300 Subject: [PATCH 02/10] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 99efa84..70e8202 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,5 @@ { - "name": "debesha/doctrine-hydration-profiler-bundle", + "name": "janwebdev/doctrine-hydration-profiler-bundle", "type": "symfony-bundle", "description": "Information about hydration of doctrine entities at the profiler", "keywords": [ From ca5f69e962ea3f9f1234bd0e2d7926ad9e919317 Mon Sep 17 00:00:00 2001 From: janwebdev Date: Thu, 11 Jun 2020 16:07:26 +0300 Subject: [PATCH 03/10] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 70e8202..fab4899 100644 --- a/composer.json +++ b/composer.json @@ -20,7 +20,7 @@ ], "require": { "php": ">=5.4", - "doctrine/orm": "^2.2", + "doctrine/orm": "^2.7", "doctrine/doctrine-bundle": "^2.1", "symfony/framework-bundle": "^2.1|^3.0|^4.0", "symfony/twig-bundle": "^2.0|^3.0|^4.0", From 9793aff2c1e4d7c72c6ef424eb0c159fca1caf79 Mon Sep 17 00:00:00 2001 From: janwebdev Date: Thu, 11 Jun 2020 16:12:58 +0300 Subject: [PATCH 04/10] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index fab4899..bafa77b 100644 --- a/composer.json +++ b/composer.json @@ -24,7 +24,7 @@ "doctrine/doctrine-bundle": "^2.1", "symfony/framework-bundle": "^2.1|^3.0|^4.0", "symfony/twig-bundle": "^2.0|^3.0|^4.0", - "twig/twig": "^1.12|^2.0" + "twig/twig": "^1.12|^2.0|^3.0" }, "autoload": { "psr-4": { From 4cb5114da33702c8591ad4d20f74e5e4e5bd2f3b Mon Sep 17 00:00:00 2001 From: Jan Rogozonsky Date: Tue, 30 Nov 2021 14:53:39 +0200 Subject: [PATCH 05/10] updating dependencies --- .gitignore | 1 + composer.json | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 3d0b430..e112a79 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ .php_cs.cache +.idea \ No newline at end of file diff --git a/composer.json b/composer.json index bafa77b..9d5e8bd 100644 --- a/composer.json +++ b/composer.json @@ -22,8 +22,8 @@ "php": ">=5.4", "doctrine/orm": "^2.7", "doctrine/doctrine-bundle": "^2.1", - "symfony/framework-bundle": "^2.1|^3.0|^4.0", - "symfony/twig-bundle": "^2.0|^3.0|^4.0", + "symfony/framework-bundle": "^2.1|^3.0|^4.0|^5.0", + "symfony/twig-bundle": "^2.0|^3.0|^4.0|^5.0", "twig/twig": "^1.12|^2.0|^3.0" }, "autoload": { From 210fdd4103f9a00c141dc76f821cc3bd1bc2dd2a Mon Sep 17 00:00:00 2001 From: Jan Rogozonsky Date: Tue, 30 Nov 2021 14:56:08 +0200 Subject: [PATCH 06/10] updating configuration --- DependencyInjection/Configuration.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DependencyInjection/Configuration.php b/DependencyInjection/Configuration.php index 9e8b95a..765d553 100644 --- a/DependencyInjection/Configuration.php +++ b/DependencyInjection/Configuration.php @@ -17,12 +17,12 @@ class Configuration implements ConfigurationInterface */ public function getConfigTreeBuilder() { - $treeBuilder = new TreeBuilder(); - $rootNode = $treeBuilder->root('debesha_doctrine_profile_extra'); + $treeBuilder = new TreeBuilder('debesha_doctrine_profile_extra'); // Here you should define the parameters that are allowed to // configure your bundle. See the documentation linked above for // more information on that topic. +// $rootNode = $treeBuilder->getRootNode(); return $treeBuilder; } From e0366a70c0998239add762f5213e30593c0a18e7 Mon Sep 17 00:00:00 2001 From: Jan Rogozonsky Date: Tue, 30 Nov 2021 15:00:47 +0200 Subject: [PATCH 07/10] updating HydrationDataCollector.php --- .gitignore | 3 +- DataCollector/HydrationDataCollector.php | 93 ++++++++++++------------ 2 files changed, 49 insertions(+), 47 deletions(-) diff --git a/.gitignore b/.gitignore index e112a79..98157e5 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .php_cs.cache -.idea \ No newline at end of file +/.idea +/vendor \ No newline at end of file diff --git a/DataCollector/HydrationDataCollector.php b/DataCollector/HydrationDataCollector.php index fa5ddd2..010d146 100644 --- a/DataCollector/HydrationDataCollector.php +++ b/DataCollector/HydrationDataCollector.php @@ -21,57 +21,58 @@ class HydrationDataCollector extends DataCollector { - /** - * @var HydrationLogger - */ - private $hydrationLogger = []; + /** + * @var HydrationLogger + */ + private $hydrationLogger = []; - public function __construct(EntityManagerInterface $manager) - { - $this->hydrationLogger = $manager->getConfiguration()->getHydrationLogger(); - } + public function __construct(EntityManagerInterface $manager) + { + $this->hydrationLogger = $manager->getConfiguration()->getHydrationLogger(); + } - public function collect(Request $request, Response $response, \Exception $exception = null) - { - $this->data['hydrations'] = $this->hydrationLogger->hydrations; - } + public function collect(Request $request, Response $response, \Exception $exception = null) + { + $this->data['hydrations'] = $this->hydrationLogger->hydrations; + } - public function getHydrations() - { - return $this->data['hydrations']; - } + public function getHydrations() + { + return $this->data['hydrations']; + } - public function getHydrationsCount() - { - return count($this->data['hydrations']); - } + public function getHydrationsCount() + { + return count($this->data['hydrations']); + } - public function getTime() - { - $time = 0; - foreach ($this->data['hydrations'] as $hydration) { - if (isset($hydration['executionMS'])) { - $time += $hydration['executionMS']; - } - } + public function getTime() + { + $time = 0; + foreach ($this->data['hydrations'] as $hydration) { + if (isset($hydration['executionMS'])) { + $time += $hydration['executionMS']; + } + } - return $time; - } + return $time; + } - /** - * {@inheritdoc} - */ - public function getName() - { - return 'hydrations'; - } + /** + * {@inheritdoc} + */ + public function getName() + { + return 'hydrations'; + } - /** - * {@inheritdoc} - */ - public function reset() - { - $this->data = []; - $this->hydrationLogger->hydrations = 0; - } -} + /** + * {@inheritdoc} + */ + public function reset() + { + $this->data = []; + $this->hydrationLogger->hydrations = []; + $this->hydrationLogger->currentHydration = 0; + } +} \ No newline at end of file From cfa15b466837cdc6d37c785531338ee663b76b44 Mon Sep 17 00:00:00 2001 From: Jan Rogozonsky Date: Tue, 30 Nov 2021 15:05:28 +0200 Subject: [PATCH 08/10] updating HydrationDataCollector.php --- DataCollector/HydrationDataCollector.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DataCollector/HydrationDataCollector.php b/DataCollector/HydrationDataCollector.php index 010d146..633cd73 100644 --- a/DataCollector/HydrationDataCollector.php +++ b/DataCollector/HydrationDataCollector.php @@ -31,7 +31,7 @@ public function __construct(EntityManagerInterface $manager) $this->hydrationLogger = $manager->getConfiguration()->getHydrationLogger(); } - public function collect(Request $request, Response $response, \Exception $exception = null) + public function collect(Request $request, Response $response, \Throwable $exception = null) { $this->data['hydrations'] = $this->hydrationLogger->hydrations; } From 9524bc7f3918735680d324bc22419a86dfe6e722 Mon Sep 17 00:00:00 2001 From: Jan Rogozinsky Date: Sat, 19 Mar 2022 18:49:24 +0200 Subject: [PATCH 09/10] Update composer.json --- composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index 9d5e8bd..7bc6d44 100644 --- a/composer.json +++ b/composer.json @@ -19,9 +19,9 @@ } ], "require": { - "php": ">=5.4", + "php": ">=7.2.5", "doctrine/orm": "^2.7", - "doctrine/doctrine-bundle": "^2.1", + "doctrine/doctrine-bundle": "^2.5", "symfony/framework-bundle": "^2.1|^3.0|^4.0|^5.0", "symfony/twig-bundle": "^2.0|^3.0|^4.0|^5.0", "twig/twig": "^1.12|^2.0|^3.0" From 1d7cfcc3981c39fbdf86da70147abd1d564f23d3 Mon Sep 17 00:00:00 2001 From: Jan Rogozinsky Date: Sat, 19 Mar 2022 18:54:36 +0200 Subject: [PATCH 10/10] Update composer.json --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 7bc6d44..2d0aa96 100644 --- a/composer.json +++ b/composer.json @@ -20,7 +20,7 @@ ], "require": { "php": ">=7.2.5", - "doctrine/orm": "^2.7", + "doctrine/orm": "^2.11", "doctrine/doctrine-bundle": "^2.5", "symfony/framework-bundle": "^2.1|^3.0|^4.0|^5.0", "symfony/twig-bundle": "^2.0|^3.0|^4.0|^5.0",