How to Investigate Course Import and Export Performance

A course import / export performance problem on production has been reported. What do you check on production to investigate?

Step-by-step guide

Use our awesome monitoring tools!

  1. Use NewRelic to check on the import_handler / export_handler transactions. (Be sure you're checking the correct environment, i.e. prod vs. edge!)
    1. prod-edx-edxapp-cms export_handler transactions:
    2. prod-edx-edxapp-cms import_handler transactions:
    3. If there are transaction traces for long transactions in the "Transaction traces" section, click on one.
      1. The trace will show details about time spent accessing MongoDB/MySQL and various parts of the code.
      2. Look for:
        1. long amounts of time spent in something that should be short
        2. high call counts that should be low
  2. Use Splunk to see if the durations have increased over time.
    1. For imports:
      1. Start a new Splunk search and use this query:
      2. index="prod-edx" sourcetype=nginx ("POST /import/course-v1" OR "POST /import/i4x")  | rex "/import/(?<course>\S*) HTTP/1.1. (?<return_code>\S*) (?<size>\S*) (?<duration>\S*)" |  timechart max(duration) by course
  3. Use DataDog and its captured course import durations to look at trends:
    1. The following timer was added to track course import durations: courselike_import.time
    2. You can view data from this timer in the Metrics Explorer: