Skip to content

docs: clarify MeterConfig units - #635

Open
blackdragoon26 wants to merge 1 commit into
p4lang:mainfrom
blackdragoon26:docs/meter-config-units
Open

blackdragoon26 wants to merge 1 commit into
p4lang:mainfrom
blackdragoon26:docs/meter-config-units

Conversation

@blackdragoon26

Copy link
Copy Markdown
Contributor

Summary

This PR is aiming to clarify that MeterSpec.Unit determines the units used by the rate and burst-size fields in MeterConfig.

For BYTES, rates are expressed in bytes per second and burst sizes in bytes.
For PACKETS, rates are expressed in packets per second and burst sizes in packets.

Also add a cross-reference to the Meter and DirectMeter section where MeterSpec.Unit is defined.

Fixes #301.

Testing

  • ./tools/asciidoclint.py docs/v1/P4Runtime-Spec.adoc
  • python3 tools/test_asciidoclint.py -v
  • Built the complete HTML and PDF specifications using the repository's official Docker build process
  • Verified that the rendered cross-reference resolves correctly

Document how MeterSpec.Unit determines the rate and burst-size units used by MeterConfig, and link back to the P4Info definition for easier discovery.

Fixes p4lang#301.

Signed-off-by: blackdragoon26 <sankalp.jha9643@gmail.com>
@blackdragoon26

Copy link
Copy Markdown
Contributor Author

Hihi @jafingerhut,
I have tried creating a simple straight PR for the fix, kindly review it.
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Make it a little easier to find units of meter configuration parameters

1 participant