Skip to content

Commit

Permalink
Document how to use "--profile" flag.
Browse files Browse the repository at this point in the history
  • Loading branch information
Kami committed Sep 15, 2015
1 parent 2fc04e0 commit 9911ccb
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/source/troubleshooting/common_troubleshooting.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ platform and how you can troubleshoot and debug them.

rules
ssh
database
18 changes: 18 additions & 0 deletions docs/source/troubleshooting/database.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
Troubleshooting Database Issues
===============================

This section contains information on how to troubleshoot database (MongoDB) related issues.

Troubleshooting performance and missing index related issues
------------------------------------------------------------

If some of the API requests are slow you receive back "too much data" error, this could be caused
by an inefficient database query or a missing index.

To troubleshoot this issue, you should start the offending service (e.g. ``st2api``) with the
``--debug`` / ``--profile`` flag.

When this flag is used the service runs in the profiling mode meaning all the executed MongoDB
queries and related profiling information (which indexes were used, how many records / rows were
scanned, how long the query took, etc.) will be logged in the service log under the DEBUG log
level.

0 comments on commit 9911ccb

Please sign in to comment.