Google is committed to advancing racial equity for Black communities. See how.

fuchsia.sys.internal

PROTOCOLS

ComponentEventListener

Defined in fuchsia.sys.internal/component_event_provider.fidl

Listener for events about the lifecycle of components.

When the listener is created it will receive OnStart calls for all components that were already in the Realm tree. If some sub-realm has a listener attached, events for components under that realm's subtree won't be synthesized.

OnDiagnosticsDirReady

Notifies the client that the out/diagnostics directory of a component is ready and provides a handle to it.

Request

NameType
component SourceIdentity
directory fuchsia.io/Directory

OnStart

Notifies the client that a component has started in the realm.

Request

NameType
component SourceIdentity

OnStop

Notifies the client that a component has stopped.

Request

NameType
component SourceIdentity

ComponentEventProvider

Defined in fuchsia.sys.internal/component_event_provider.fidl

Service exposed by appmgr that enables a component (such as archivist) to listen for lifecycle events of components in the realm tree.

SetListener

Requests a hook to get lifecycle events for the realm from where this service was connected to.

Request

NameType
listener ComponentEventListener

CrashIntrospect

Defined in fuchsia.sys.internal/crash_introspect.fidl

FindComponentByThreadKoid

Request

NameType
thread_koid zx/koid

Response

NameType
result CrashIntrospect_FindComponentByThreadKoid_Result

LogConnectionListener

Defined in fuchsia.sys.internal/log_connector.fidl

LogConnectorListener receives attributed log connections from a consumer such as the Archivist. This protocol is meant to be used with a LogConnector.

OnNewConnection

Adds a new connection.

Request

NameType
connection LogConnection

LogConnector

Defined in fuchsia.sys.internal/log_connector.fidl

LogConnector is implemented once per-realm by appmgr. Clients of this protocol call TakeLogConnectionListener to receive logs within the client's realm.

When a component starts with this protocol in its sandbox, appmgr creates a matching LogConnectionListener for that component's realm, and will forward any LogConnections in the realm to the LogConnectionListener.

As a result, if a LogConnectionListener wishes to consume logs for another component in its realm, the consumer must be started before other components in the realm. The consumer does not need to begin executing, just have its namespace constructed.

TakeLogConnectionListener

Removes the LogConnectionListener from this realm, returning the request-side if it had not already been taken. Clients should bind an implementation to the LogConnectionListener protocol in order to receive LogSinks.

This method returns a request<LogConnectionListener> instead of accepting a LogConnectionListener directly in order to allow appmgr to construct and buffer LogConnectionListener with LogConnections.

Request

NameType

Response

NameType
consumer request<LogConnectionListener>?

STRUCTS

CrashIntrospect_FindComponentByThreadKoid_Response

Defined in fuchsia.sys.internal/crash_introspect.fidl

NameTypeDescriptionDefault
component_info SourceIdentity No default

LogConnection

Defined in fuchsia.sys.internal/log_connector.fidl

An incoming connection for logging from a component, attributed by appmgr.

NameTypeDescriptionDefault
log_request request<fuchsia.logger/LogSink>

The incoming request for the LogSink.

No default
source_identity SourceIdentity

What we know about the identity of the requester.

No default

TABLES

SourceIdentity

Defined in fuchsia.sys.internal/source_identity.fidl

Identifies a component uniquely within the observing realm. Example: hub/r/sys/4566/c/http.cmx/19226 realm_path: [root, sys] component_url: "fuchsia-pkg://fuchsia.com/http#meta/http.cmx" component_name: "http.cmx" instance_id: 19226

OrdinalNameTypeDescription
1 realm_path realm_segments

The path to the component from the observing realm.

2 component_url component_url

The URL from which the component was loaded.

3 component_name string[255]

The name of the component.

4 instance_id string[32]

The ID of the component.

UNIONS

CrashIntrospect_FindComponentByThreadKoid_Result

Defined in fuchsia.sys.internal/crash_introspect.fidl

NameTypeDescription
response CrashIntrospect_FindComponentByThreadKoid_Response
err zx/status

CONSTANTS

NameValueTypeDescription
COMPONENT_NAME_MAX_LENGTH 255 uint16
LABEL_MAX_LENGTH 32 uint32

Maximum length for an environment label.

MAXIMUM_REALM_PATH_SEGMENTS 50 uint16

TYPE ALIASES

NameValueDescription
component_url string
realm_segments vector[MAXIMUM_REALM_PATH_SEGMENTS]