mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
38 lines
2.7 KiB
Plaintext
38 lines
2.7 KiB
Plaintext
// Module included in the following assemblies:
|
|
//
|
|
// * networking/ptp/ptp-cloud-events-consumer-dev-reference.adoc
|
|
|
|
:_mod-docs-content-type: CONCEPT
|
|
[id="cnf-about-ptp-events-consumer-sidecar-and-http-transport_{context}"]
|
|
= Retrieving PTP events with the PTP events REST API v1
|
|
|
|
Applications run the `cloud-event-proxy` container in a sidecar pattern to subscribe to PTP events.
|
|
The `cloud-event-proxy` sidecar container can access the same resources as the primary application container without using any of the resources of the primary application and with no significant latency.
|
|
|
|
.Overview of PTP fast events with consumer sidecar and HTTP message transport
|
|
image::319_OpenShift_PTP_bare-metal_OCP_nodes_0323_4.13.png[Overview of PTP fast events with consumer sidecar and HTTP message transport]
|
|
|
|
image:darkcircle-1.png[20,20] Event is generated on the cluster host::
|
|
`linuxptp-daemon` in the PTP Operator-managed pod runs as a Kubernetes `DaemonSet` and manages the various `linuxptp` processes (`ptp4l`, `phc2sys`, and optionally for grandmaster clocks, `ts2phc`).
|
|
The `linuxptp-daemon` passes the event to the UNIX domain socket.
|
|
|
|
image:darkcircle-2.png[20,20] Event is passed to the cloud-event-proxy sidecar::
|
|
The PTP plugin reads the event from the UNIX domain socket and passes it to the `cloud-event-proxy` sidecar in the PTP Operator-managed pod.
|
|
`cloud-event-proxy` delivers the event from the Kubernetes infrastructure to Cloud-Native Network Functions (CNFs) with low latency.
|
|
|
|
image:darkcircle-3.png[20,20] Event is persisted::
|
|
The `cloud-event-proxy` sidecar in the PTP Operator-managed pod processes the event and publishes the cloud-native event by using a REST API.
|
|
|
|
image:darkcircle-4.png[20,20] Message is transported::
|
|
The message transporter transports the event to the `cloud-event-proxy` sidecar in the application pod over HTTP.
|
|
|
|
image:darkcircle-5.png[20,20] Event is available from the REST API::
|
|
The `cloud-event-proxy` sidecar in the Application pod processes the event and makes it available by using the REST API.
|
|
|
|
image:darkcircle-6.png[20,20] Consumer application requests a subscription and receives the subscribed event::
|
|
The consumer application sends an API request to the `cloud-event-proxy` sidecar in the application pod to create a PTP events subscription.
|
|
The `cloud-event-proxy` sidecar creates an HTTP messaging listener protocol for the resource specified in the subscription.
|
|
|
|
The `cloud-event-proxy` sidecar in the application pod receives the event from the PTP Operator-managed pod, unwraps the cloud events object to retrieve the data, and posts the event to the consumer application.
|
|
The consumer application listens to the address specified in the resource qualifier and receives and processes the PTP event.
|