-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Initial version of PINS P4RT App HLD #826
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Venkatesan
Hi @qiluo-msft, Did you have a chance to take a look at this? Based on the PINS upstream tracker (#841) your username is associated with this HLD. Thanks, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As comments
|
||
## P4RT Application High-Level Design | ||
|
||
The P4RT application is responsible for implementing the [P4Runtime Specification](https://p4lang.github.io/p4runtime/spec/v1.3.0/P4Runtime-Spec.html) as a gRPC service. The application will run in its own Docker container. A controller (or multiple controllers) can connect as clients to the gRPC service, and write P4 table entries that correspond to SAI tables (specified by a P4 program). These entries are intended for the ASIC database, but following the SONiC architecture, the P4RT application will translate/format the gRPC request and write its output into the APPL_DB. From there, the P4Orch (TODO: reference OA HLD) handles the request. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How heavy is the communication through APPL_DB? I mean entry size, the frequency of writing. Do you need the channel keep strict time order? #Closed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
P4RT app will program whatever the controller tells it. The requests are pretty much 1-to-1. So the communication through APPL_DB will depend on how many routes and/or ACLs are needed.
We don't need to keep any strict time order. However, for each request the P4Orch should send a response back when it's done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this flow in diagram "each request the P4Orch should send a response back when it's done" ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since P4RT App only interacts with the P4Orch through the RedisDBs it was left out, but it's a good point that the response path wasn't very clear. Added the P4Orch to the diagram per your suggestion.
doc/pins/p4rt_app_hld.md
Outdated
|
||
## APPL DB Schema High-Level Design | ||
|
||
P4RT application introduces new tables that are written to APPL_DB for the tables it intends to program via the P4Orch. The schema of the P4RT tables and other details are captured in the P4RT DB Schema HLD. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you provide the link to "P4RT DB Schema HLD"? Reminder that we also need Yang model defined for new schema. #Pending
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added a TODO since the other PINS HLDs are still under review, and I can't point to any permanent location. Here's a link: #840
Not sure if there is a better way to handle this?
Thanks @qiluo-msft, I addressed the comments do you mind having a second look and letting me know if more clarification is needed? |
Thanks again @qiluo-msft, any more concerns? |
* High level design document for the PINS P4RT application.
@zhangyanzhao not sure I understand the ask about #806 ... Are you looking for the HLD doc itself to point to the PRs? For example: sonic-net/sonic-buildimage#9083 and sonic-net/sonic-pins#1? |
High level design document for the PINS P4RT application.