Background tracing: Simplify public interface and isolate trigger logic
commitf4ce0b06f671d8c6b4b9d7227c2af813d6581893
authoroysteine <oysteine@chromium.org>
Wed, 26 Aug 2015 01:33:06 +0000 (25 18:33 -0700)
committerCommit bot <commit-bot@chromium.org>
Wed, 26 Aug 2015 01:33:38 +0000 (26 01:33 +0000)
treec5afb89357b48936efdcb8a51f925aee1ceb3de0
parentd3b9bca27c47a65dd1b8a3a8fd6087eaa56b0336
Background tracing: Simplify public interface and isolate trigger logic

Mostly mechanical preparatory patch to simplify adding new triggers to the system in the future.

* Since setting up scenarios by code is mainly used by tests, the public interface now only accepts dicts and all rule type information is moved to the implementation.
* Specific logic regarding specific rules has moved to background_tracing_rule_impl.cc
* BackgroundTracingPreemptiveConfig and BackgroundTracingReactiveConfig have been merged together and there's far fewer separate codepaths between the two modes in general.

Review URL: https://codereview.chromium.org/1297813002

Cr-Commit-Position: refs/heads/master@{#345523}
23 files changed:
chrome/browser/tracing/chrome_tracing_delegate.cc
chrome/browser/tracing/chrome_tracing_delegate_browsertest.cc
chrome/browser/tracing/navigation_tracing.cc
content/browser/tracing/background_tracing_config_dict.cc [deleted file]
content/browser/tracing/background_tracing_config_impl.cc [new file with mode: 0644]
content/browser/tracing/background_tracing_config_impl.h [new file with mode: 0644]
content/browser/tracing/background_tracing_config_unittest.cc
content/browser/tracing/background_tracing_manager_browsertest.cc
content/browser/tracing/background_tracing_manager_impl.cc
content/browser/tracing/background_tracing_manager_impl.h
content/browser/tracing/background_tracing_rule.cc [new file with mode: 0644]
content/browser/tracing/background_tracing_rule.h [new file with mode: 0644]
content/browser/tracing/tracing_controller_impl.cc
content/browser/tracing/tracing_controller_impl.h
content/content_browser.gypi
content/public/browser/background_tracing_config.cc
content/public/browser/background_tracing_config.h
content/public/browser/background_tracing_manager.h
content/public/browser/background_tracing_preemptive_config.cc [deleted file]
content/public/browser/background_tracing_preemptive_config.h [deleted file]
content/public/browser/background_tracing_reactive_config.cc [deleted file]
content/public/browser/background_tracing_reactive_config.h [deleted file]
content/public/browser/tracing_delegate.h