| // Copyright 2022 The Fuchsia Authors. All rights reserved. | |
| // Use of this source code is governed by a BSD-style license that can be | |
| // found in the LICENSE file. | |
| { | |
| include: [ | |
| "inspect/client.shard.cml", | |
| "syslog/client.shard.cml", | |
| ], | |
| program: { | |
| runner: "elf", | |
| binary: "bin/launcher", | |
| args: [ "sampler" ], | |
| environ: [ | |
| // TODO(https://fxbug.dev/382623426): revisit this. | |
| "SCUDO_OPTIONS=release_to_os_interval_ms=0", | |
| ], | |
| }, | |
| use: [ | |
| { | |
| config: "fuchsia.diagnostics.sampler.MinimumSampleRateSec", | |
| key: "minimum_sample_rate_sec", | |
| availability: "optional", | |
| type: "int64", | |
| default: 300, | |
| }, | |
| // Sampler project configurations in JSON. See: | |
| // [`ProjectConfig`](https://cs.opensource.google/fuchsia/fuchsia/+/main:src/diagnostics/lib/sampler-config/src/runtime/mod.rs) | |
| // for the schema. | |
| // LINT.IfChange | |
| { | |
| config: "fuchsia.diagnostics.sampler.ProjectConfigs", | |
| key: "project_configs", | |
| availability: "optional", | |
| type: "vector", | |
| max_count: 1024, | |
| element: { | |
| type: "string", | |
| max_size: 100000, | |
| }, | |
| default: [], | |
| }, | |
| // LINT.ThenChange(//src/lib/assembly/platform_configuration/src/subsystems/diagnostics.rs) | |
| { | |
| protocol: [ | |
| "fuchsia.diagnostics.Sample", | |
| "fuchsia.hardware.power.statecontrol.ShutdownWatcherRegister", | |
| "fuchsia.metrics.MetricEventLoggerFactory", | |
| ], | |
| }, | |
| ], | |
| expose: [ | |
| { | |
| protocol: "fuchsia.component.Binder", | |
| from: "framework", | |
| }, | |
| ], | |
| } |