tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

0003-concept-base-component.md (2634B)



layout: page title: Adding a concept-base component permalink: /rfc/0003-concept-base-component


Summary

Adding a concept-base component for basic interfaces needed by multiple components.

Motivation

We already have a support-base component that contains basic building blocks, like a logger, that other components may need. Some of those building blocks are interfaces, like CrashReporting that are implemented by other components (e.g. lib-crash). This works well in most cases, but becomes problematic once a concept component requires such an interface. Having a concept component depend on actual code with support-base is breaking our contract of concepts only depending on other concepts.

Reference-level explanation

We introduce a concept-base component that contains those "basic" interfaces. Other components and concepts can depend on this component. This component will be the home for the Profiler interface (#7689) and leak detection interface (#7775).

In addition to that we can move interface-only pieces from support-base to concept-base: CrashReporting, MemoryConsumer.

Drawbacks

Rationale and alternatives