Google Crashpad Crashpad logo for BugSplat


Google Crashpad is the latest open-source crash reporting tool built by Google. It is the successor to the popular Breakpad crash reporter. Crashpad allows you to submit minidumps to a configured URL after a crash occurs in your product. The official Google documentation is available at the Google Crashpad page.

It's easy to send Crashpad reports to BugSplat, allowing you to take advantage of BugSplat's crash reporting services. BugSplat functions as a Crashpad server, requiring only configuration changes to send crash reports to our site.

Crashpad Tutorial

To begin Download and unzip the BugSplat Crashpad software development kit. The download contains a sample Crashpad application and a compiled version of Crashpad for Windows. It's also possible to download and build Crashpad yourself. This step is required if you are targeting an OS other than Windows.

To get a feel for the BugSplat service before enabling your application, experiment with the myCrashpadCrasher sample application. You can find the Visual Studio project file located in your download folder at ...\BugSplatCrashpad\BugSplat\samples\myCrashpadCrasher\myCrashpadCrasher.vcxproj.

Run the sample application without the debugger attached to post a crash report to our public "Fred" database. To view the report, login to the Fred database using the account "Fred" with password "Flintstone".

Generating Crashpad reports with your application

Follow the myCrashpadCrasher pattern to enable Crashpad in your application...

  1. Include the following header files:
    #include "client/crashpad_client.h"
    #include "client/crash_report_database.h"
    #include "client/settings.h
  2. Copy the initializeCrashpad method from the BugSplat sample.
  3. Call initializeCrashpad using your own parameters for the BugSplat database, appName, and appVersion.
  4. The statements below (found in the initializeCrashpad function) are unique to the BugSplat/Crashpad configuration. The Crashpad url and parameters format, prod and ver are required to successfully post crash reports to BugSplat. You can optionally specify values for the parameters email, comments, and key which will be tracked with each crash report.
      std::string url;
      url = "https://";
      url += dbName; // BugSplat database name
      url += "";
      std::map<std::string, std::string> annotations;
      annotations["format"] = "minidump";		// Crashpad setting to save crash as a minidump
      annotations["prod"].assign(appName);	        // BugSplat appName
      annotations["ver"].assign(appVersion);	// BugSplat appVersion
      annotations["key"] = "Sample key";            // Optional BugSplat key field
      annotations["email"] = "";	// Optional BugSplat user email
      annotations["comments"] = "Sample comment";	// Optional BugSplat crash description
  5. Link your application with the appropriate version of the Crashpad libraries crashpad_client.lib, base.lib, and crashpad_util.lib. BugSplat supplies builds for Debug/Release (x86) and Debug_x64/Release_x64 versions of the Crashpad libraries.
  6. Upload symbols for your application to generate symbolic call stacks. Our sample project uses the BugSplat SendPdbs utility to upload .exe/.pdb files. This is the preferred approach for Windows products. Additional information can be found at our SendPdbs page.
  7. BugSplat also supports symbol files using the Google .sym file format. This format is required for platforms other than Windows. To upload your application's .sym files using the manual symbol upload page, select one of your symbol stores on the Symbols page, then click the "Upload new symbol files" link. Alternatively, you can use the Google symupload utility to automate the symbol upload process. Run the following symupload command replacing {database}, {appName} and {appVersion} with values specific to your BugSplat database and symbol store:
    symupload file.sym "https://{database}{appName}&appVer={appVersion}"
  8. Trigger a crash in your application. The crash report should be available immediately at the BugSplat website.

Additional Considerations

The BugSplat database for your crash reports is created on the Databases page. Typically you will create a new database for each major release of your product.

BugSplat attempts to process Crashpad crashes reported from Windows operating systems with our Windows backend, rather than the Crashpad/Breakpad backend. The advantage to this approach is that the Windows backend automatically resolves Windows OS symbols. The presence of .pdb files in the Symbol Store is what triggers the use of the Windows backend. As a result, we recommend that mixed-platform applications use different BugSplat appNames/appVersions to keep their symbol stores separate.

If you are sending symbols from symupload on OS X there is no command line option to increase the upload timeout. We have created a fork of symupload with the timeout increased to 100 seconds (from 10 seconds). You need to use a modified version of symupload to upload files larger than 100 MB. You can download the modified archive here.