perftools / perftools/xhgui

Sort operation used more than the maximum 33554432 bytes of RAM. Add an index, or specify a smaller limit.

Open
#258 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
1.7k
Forks
341
PR merge metrics
No merged PRs in 30d

Description

Hi, and thanks for the amazing tool!

But unfortunately I have the issue with large requests.

Executor error during find command :: caused by :: errmsg: "Sort operation used more than the maximum 33554432 bytes of RAM. Add an index, or specify a smaller limit."

The stack trace:

#0 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/alcaeus/mongo-php-adapter/lib/Mongo/MongoCursor.php(170): Alcaeus\MongoDbAdapter\ExceptionConverter::toLegacy(Object(MongoDB\Driver\Exception\RuntimeException))
#1 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/alcaeus/mongo-php-adapter/lib/Mongo/MongoCursor.php(467): MongoCursor->doQuery()
#2 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/alcaeus/mongo-php-adapter/lib/Alcaeus/MongoDbAdapter/AbstractCursor.php(297): MongoCursor->ensureCursor()
#3 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/alcaeus/mongo-php-adapter/lib/Alcaeus/MongoDbAdapter/AbstractCursor.php(190): Alcaeus\MongoDbAdapter\AbstractCursor->ensureIterator()
#4 /home/linuxbrew/.linuxbrew/opt/xhgui/src/Xhgui/Profiles.php(310): Alcaeus\MongoDbAdapter\AbstractCursor->rewind()
#5 /home/linuxbrew/.linuxbrew/opt/xhgui/src/Xhgui/Profiles.php(105): Xhgui_Profiles->_wrap(Object(MongoCursor))
#6 /home/linuxbrew/.linuxbrew/opt/xhgui/src/Xhgui/Profiles.php(256): Xhgui_Profiles->paginate(Array)
#7 /home/linuxbrew/.linuxbrew/opt/xhgui/src/Xhgui/Controller/Run.php(38): Xhgui_Profiles->getAll(Array)
#8 /home/linuxbrew/.linuxbrew/opt/xhgui/src/routes.php(25): Xhgui_Controller_Run->index()
#9 [internal function]: {closure}()
#10 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/slim/slim/Slim/Route.php(468): call_user_func_array(Object(Closure), Array)
#11 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/slim/slim/Slim/Slim.php(1355): Slim\Route->dispatch()
#12 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/slim/slim/Slim/Middleware/Flash.php(85): Slim\Slim->call()
#13 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/slim/slim/Slim/Middleware/MethodOverride.php(92): Slim\Middleware\Flash->call()
#14 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/slim/slim/Slim/Middleware/SessionCookie.php(110): Slim\Middleware\MethodOverride->call()
#15 /home/linuxbrew/.linuxbrew/opt/xhgui/src/Xhgui/Middleware/Render.php(11): Slim\Middleware\SessionCookie->call()
#16 /home/linuxbrew/.linuxbrew/opt/xhgui/vendor/slim/slim/Slim/Slim.php(1300): Xhgui_Middleware_Render->call()
#17 /home/linuxbrew/.linuxbrew/opt/xhgui/webroot/index.php(10): Slim\Slim->run()
#18 {main}

Does exists any way to pass through it?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing pagination and sorting in src/Xhgui/Profiles.php, especially the paths around lines 105, 256, and 310, then follow the request from src/Xhgui/Controller/Run.php. Reproduce the large request against MongoDB and determine the intended handling for the reported sort-memory failure; done should include a tested resolution or clearly documented limitation.

Written by the indexing model from the issue text.

Assessment

Tech stack
mongodb, php
Domain
backend, databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.