Skip to content

Add MongoDB profiler #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 14 commits into from
Dec 9, 2023
Merged

Add MongoDB profiler #4

merged 14 commits into from
Dec 9, 2023

Conversation

GromNaN
Copy link
Collaborator

@GromNaN GromNaN commented Nov 10, 2023

It looks like I don't have waited for @alcaeus to give me time to work on the profiler. It's based largely on the Doctrine profiler.

Logo comes from https://www.mongodb.com/brand-resources and was reworks to adjust the colors and the size.

Toolbar

image

Profiler panel

image

Performance panel

image

  • Tests
  • Logo color
  • Performance panel
  • Backtrace with link to the call to the MongoDB library
  • Add server info in panel
  • DataCollector reset
  • "Copy as mongosh"
  • Explain
  • JSON pretty colors

@GromNaN GromNaN added the enhancement New feature or request label Nov 10, 2023
@@ -70,7 +72,7 @@ private function createClients(string $defaultClient, array $clients, ContainerB
$clientDefinition->setArgument('$uri', $configuration['uri']);
$clientDefinition->setArgument('$uriOptions', $configuration['uriOptions'] ?? []);
$clientDefinition->setArgument('$driverOptions', $configuration['driverOptions'] ?? []);

$clientDefinition->addTag('mongodb.client', ['name' => $client]);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This name is used by DataCollectorPass and displayed in the profiler panel.
The tag didn't need to be in the service prototype.

@GromNaN
Copy link
Collaborator Author

GromNaN commented Nov 13, 2023

Command backtrace

image

Client/Server info

image

@GromNaN GromNaN force-pushed the profiler branch 2 times, most recently from 0fbd19c to b9b5124 Compare December 8, 2023 21:47
@alcaeus alcaeus added this to the 0.2 milestone Dec 9, 2023
@alcaeus alcaeus merged commit af537c2 into mongodb-labs:0.2 Dec 9, 2023
@OskarStark
Copy link
Contributor

Great work @GromNaN 👌🏻

@GromNaN GromNaN deleted the profiler branch December 9, 2023 16:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants