Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(123)

Issue 2341853002: ServiceManager: Simplify Instance lifetime management (Closed)

Created:
4 years, 3 months ago by Ken Rockot(use gerrit already)
Modified:
4 years, 3 months ago
CC:
chromium-reviews
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

ServiceManager: Simplify Instance lifetime management Makes Instance ownership and lifetime management easier to follow. Root instances are now explicitly owned by the ServiceManager and non-root instances are explicitly owned by their parent Instance. OnInstanceError always destroys the Instance, either by removing it from the root instance set or delegating to the parent Instance. This avoids the need for children to re-enter their parent on destruction. Notification logic has been extracted from OnInstanceError and moved to a new OnInstanceStopped, which is always called by each Instance's destructor. This allows parents to delete their own children without calling through to OnInstanceError, while still allowing the ServiceManager to know about the destruction and dispatch notifications accordingly. InstanceErrorType is removed: if an Instance becomes unreachable it's simply removed from the identity map via a new OnInstanceUnreachable call. BUG=640488 Committed: https://crrev.com/262a9e00334328804c7515ba4e2f840aee8ec681 Cr-Commit-Position: refs/heads/master@{#418643}

Patch Set 1 #

Patch Set 2 : . #

Unified diffs Side-by-side diffs Delta from patch set Stats (+70 lines, -67 lines) Patch
M services/shell/service_manager.h View 3 chunks +16 lines, -16 lines 0 comments Download
M services/shell/service_manager.cc View 1 10 chunks +54 lines, -51 lines 0 comments Download

Messages

Total messages: 17 (12 generated)
Ken Rockot(use gerrit already)
4 years, 3 months ago (2016-09-14 18:26:39 UTC) #4
Ben Goodger (Google)
lgtm
4 years, 3 months ago (2016-09-14 19:31:21 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2341853002/20001
4 years, 3 months ago (2016-09-14 19:33:33 UTC) #14
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 3 months ago (2016-09-14 19:39:57 UTC) #15
commit-bot: I haz the power
4 years, 3 months ago (2016-09-14 19:42:08 UTC) #17
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/262a9e00334328804c7515ba4e2f840aee8ec681
Cr-Commit-Position: refs/heads/master@{#418643}

Powered by Google App Engine
This is Rietveld 408576698