DiscoveryHandler
service defined in discovery.proto
. In order to be utilized, a Discovery Handler must register with the Agent, which hosts the Registration
service defined in discovery.proto
.Configuration.capacity
.brokerProperties
as environment variables in all Pods that request this device's resource. This information is also set in the brokerProperties
section of the Instance the Agent creates to represent the discovered leaf device. In the Instance, the Agent also lists itself as a node that can access the device under nodes
. Note how Instance has 3 available deviceUsage
slots, since capacity was set to 3 and no brokers have been scheduled to the leaf device yet.allocate
on the device plugin running in the Agent for the requested leaf device. When calling allocate
, the kubelet requests a specific deviceUsage
slot. Let's say the kubelet requested akri-<protocolA>-<hash>-1
. The leaf device's device plugin checks to see that the requested deviceUsage
slot has not been taken by another node. If it is available, it reserves that deviceUsage
slot for this node (as shown below) and returns true. In the allocate
response, the Agent also tells kubelet to mount the Instance.brokerProperties
as environment variables in the broker Pod.false
if kubelet requests a deviceUsage
slot that is already taken. See the resource sharing document for a better understanding on how this is resolved. Otherwise, upon a true
result, the kubelet will run the pod. The broker is now running and has the information necessary to communicate with the specific device.