[watremark] Add watermark HLD#245
Conversation
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
the regular user should also be able to reset the watermark.
There was a problem hiding this comment.
What is the use case for resetting the watermark?
There was a problem hiding this comment.
clear the watermark, for example, if user wants to know how buffer is utilized under current traffic, he will want to clear the existing watermark and check the new one.
There was a problem hiding this comment.
clear the watermark, for example, if user wants to know how buffer is utilized under current traffic, he will want to clear the existing watermark and check the new one.
There was a problem hiding this comment.
if we have clear the watermark, to be able to check the new one, we should also have a get watermark?
There was a problem hiding this comment.
User will have CLI to show current watermark, f.e. "show queue watermark unicast" for current watermark, and "show queue persistent-watermark unicast" for persistent one.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
streaming telemetry is periodically resetting the watermark.
There was a problem hiding this comment.
I agree. This sentence is copy-pasted from requirements :)
|
I cannot see those figures, have you uploaded them? |
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
do we have the total pool watermark here? I think we need that as well.
There was a problem hiding this comment.
Pool watermark was not in the requirements. Also as far as I know pool objects are not created in SONiC, so more complexity.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
show priority-group watermark headroom
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
show priority-group watermark shared
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
show queue watermark unicast
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
show queue watermark multicast
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
clear priority-group watermark headroom
clear priority-group watermark shared
clear queue watermark unicast
clear qeueu watermark mutlicast
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
show priority-group persistent-watermark headroom
show priority-group persistent-watermark shared
show queue persistent-watermark unicast
show queue persistent-watermark multicast
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
also add following
show pool watermark ingress
show pool watermark egress
show pool watermark headroom
|
I can see the figure now, but the there is no marker on the figure and there is no explanation on the figure. couldn't understand, can you explain the figure that has the timeline and events. |
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
why not use flex counter to do the query? It is better to consolidate all counter query into one place. We already have a flex counter thread to do the query, in my opinion, all counter query should be there.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
rename to WATERMARKS - containing periodically cleared watermarks.
There was a problem hiding this comment.
add CACHED_WATERMARK to temporarily store the water mark before last user clear.
There was a problem hiding this comment.
need HIGHEST_WATERMARK table to store last highest watermark, this is not persistent watermark table. when user clear the water mark, it needs also clear the highest_watermark.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
Periocially, the flex counter put the current watermark into WATERMARK table, and then clear it on hardware.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
the watermarks need to be integrated in telemetry virtual path, but this can be phase II.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
there should be a CACHED_WATERMARK table that is used to save the watermark before user clear. whenever user clears the watermark, it needs to put the last read watermark into the CACHED_WATERMARK. telemetry should read the CACHED_WATERMARK and WATERMARK and return the maximum value if there is CACHED_WATERMARK. After that, CAHCED_WATERMARK should be deleted.
There was a problem hiding this comment.
btw, I would suggest to use the lua plugin to the comparision and merge.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
at point 2, the CACHED_WATERMARK is generated, in next periodically clear point, the CACHED_WATERMARK is compared with WATERMARK and send to telemetry. after that, the CACHED_WATERMARK is deleted.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
we need to walk through the timeline and connect these events to the detail design to see how everything works. currently, the description of events is not associated with your design.
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
no need to have --period in the cli.
There was a problem hiding this comment.
no --period, issue query immediately
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
can you add the schema you want to introduce for read-on-clear for a group of counters?
doc/watermarks_HLD.md
Outdated
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
sonic-clear priority-group [watermark|persistent-watermark] headroom
doc/watermarks_HLD.md
Outdated
There was a problem hiding this comment.
depending the performance, we may need to increase the polling interval for the watermark and introduce on-demand asic counter clear on the watermarks.
|
Then I dont understand the req
When the user issue this cli it specified a period. What that period means. Backwards or forward? If backwards then it means lots of storage which has no mean.
Best regards,
Liat Grozovik I sr. Director I SW systems
Sorry for all typo. I am sure there are few...
Sent from my Samsung Galaxy smartphone.
-------- Original message --------
From: Wenda Ni <notifications@github.com>
Date: 9/19/18 20:21 (GMT+02:00)
To: Azure/SONiC <SONiC@noreply.github.com>
Cc: Subscribed <subscribed@noreply.github.com>
Subject: Re: [Azure/SONiC] [watremark] Add watermark HLD (#245)
@wendani commented on this pull request.
________________________________
In doc/watermarks_HLD.md<#245 (comment)>:
+An unified API which represent the switch state as a set of objects. In SONiC represented in two implementations - SAI DB frontend and ASIC SDK wrapper.
+# 2 Requirements
+The following watermarks should be supported:
+## 2.1 Watermark counters requirements
+| | SAI attribute mapping |
+|------------------------------------------|------------------------|
+| Ingress headroom per PG | SAI_INGRESS_PRIORITY_GROUP_STAT_XOFF_ROOM_WATERMARK_BYTES |
+| Ingress shared pool occupancy per PG | SAI_INGRESS_PRIORITY_GROUP_STAT_SHARED_WATERMARK_BYTES |
+| Egress shared pool occupancy per queue (including both unicast queues and multicast queues) | SAI_QUEUE_STAT_SHARED_WATERMARK_BYTES |
+
+System behavior:
+We consider a maximum of one regular user and a maximum of one special user that comes from streaming telemetry (grpc)
+
+Streaming telemetry is only interested in periodic watermark, i.e., it queries the watermark at regular intervals. The interval is configurable. Streaming telemetry does not care about persistent watermark.
+
+Regular user is able to query the watermark over a period specified in the cli. When the cli is issued, the cli blocks over the specified period, which counts the issuing of the cli as its starting point, and then returns the watermark over the specified period.
no --period, issue query immediately
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub<#245 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/ARmmi8ykMlTAvZ71HjturT_4AtdT9g7Kks5ucn0LgaJpZM4We3su>.
|
Signed-off-by: Mykola Faryma <mykolaf@mellanox.com>
Signed-off-by: Mykola Faryma <mykolaf@mellanox.com>
* [watremark] Add watermark HLD Signed-off-by: Mykola Faryma <mykolaf@mellanox.com>
Watermark High Level Design Document for SONiC