GSoC_2013_AJAX_error_reporting

Michal Čihař edited this page Apr 18, 2016 · 3 revisions
Clone this wiki locally

AJAX error reporting

Please note that the below is only meant to be a rough guide and not as a set of rules to which to adhere.

Introduction

Since version 4.0, page loading in phpMyAdmin is ajax-driven, therefore JavaScript errors will sometimes cause pages to hang. In order to provide a better user experience we must be more aware of these errors and correct them quickly.

The system proposed below would allow users to send automatically-generated error reports to phpMyAdmin developers.

System components

The system will be comprised of 2 parts.

A component written in JavaScript that will run in the end-user's browser. This part of the system will create crash reports and send them to phpmyadmin.net server for processing. All values sent in reports must be sanitized to prevent leaking sensitive information.

A component written in PHP that will run on the phpmyadmin.net server. This part of the system will receive crash reports and save them to a database. This components will also allow developers to access a web interface to the database that will allow them to see individual crash reports, statistics about similar crash reports and search for particular types of crash reports and, perhaps, even automatically submit bug reports to our tracker.

The server will have the following specifications:

  • linux
  • lighttpd 1.4
  • php 5.4
  • mysql 5.5

Basic work flow

  • phpMyAdmin experiences a js error
  • phpMyAdmin collects information about the crash
  • phpMyAdmin informs the user of the problem, giving him the option to submit an automatic report (with an option to see the contents of the report)
  • The user approves the submission
  • phpMyAdmin sends an ajax request to phpmyadmin.net
  • The phpmyadmin.net server stores the report in a MySQL database

Crash reports

Crash reports may contain, among other relevant information, the following:

Configuration

  • There must be a configuration setting to enable/disable this functionality (default: enabled).
  • There must be a configuration setting to specify the default action for submitting crash reports: 'Always Ask', 'Submit Reports Without Asking', 'Never Submit Reports' (default: 'Always Ask').
  • Other settings?