1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
fuchsia_web / webinstance_host / web_instance_host.shard.cml [blame]
// Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
{
include: [
// Enable logging from the Component that is a web_instance_host.
"syslog/use.shard.cml",
],
collections: [
// The collection in which child instances are dynamically created.
{
name: "web_instances",
durability: "transient",
allowed_offers: "static_and_dynamic",
persistent_storage: false,
},
],
capabilities: [
// The root of a directory tree through which directory capabilities are
// dynamically routed to child instances.
{
directory: "web_instances",
rights: [ "rw*" ],
path: "/web_instances",
},
],
use: [
{
protocol: "fuchsia.component.Realm",
from: "framework",
},
{
protocol: [
"fuchsia.feedback.ComponentDataRegister",
"fuchsia.feedback.CrashReportingProductRegister",
],
},
],
offer: [
{
directory: "config-data-for-web-instance",
from: "parent",
as: "config-data",
to: "#web_instances",
availability: "optional",
},
{
directory: "tzdata-icu",
from: "parent",
to: "#web_instances",
},
{
// Statically offered to all web_instances regardless of whether they were
// created with `ContextFeatureFlags.NETWORK`.
directory: "root-ssl-certificates",
from: "parent",
to: "#web_instances",
// Required if the WebInstanceHost may create Contexts with
// `ContextFeatureFlags.NETWORK`.
availability: "optional",
},
{
protocol: [
"fuchsia.buildinfo.Provider",
"fuchsia.device.NameProvider",
"fuchsia.fonts.Provider",
"fuchsia.hwinfo.Product",
"fuchsia.intl.PropertyProvider",
"fuchsia.logger.LogSink", // Targeted copy of syslog/offer.shard.cml.
"fuchsia.memorypressure.Provider",
"fuchsia.process.Launcher",
"fuchsia.sysmem.Allocator",
"fuchsia.sysmem2.Allocator",
],
from: "parent",
to: "#web_instances",
},
{
protocol: [
// Required for video capture.
// TODO(crbug.com/42050280): Move to AppendDynamicServices() to provide
// it conditionally when a ContextFeatureFlags is defined.
"fuchsia.camera3.DeviceWatcher",
// Required to schedule display-critical and realtime audio threads.
// TODO(crbug.com/42050308): Migrate to `fuchsia.scheduler`.
"fuchsia.media.ProfileProvider",
"fuchsia.scheduler.RoleManager",
// Required by Frame.SetPreferredTheme(DEFAULT).
"fuchsia.settings.Display",
// Optionally used by the tracing service.
// crbug.com/1364196 tracks providing it conditionally when enabled.
"fuchsia.tracing.perfetto.ProducerConnector",
],
from: "parent",
to: "#web_instances",
availability: "optional",
},
],
}