Filter out unnecessary PTF logs when calling the ptfadapter plugin#1828
Merged
wangxin merged 1 commit intosonic-net:masterfrom Jul 1, 2020
wangxin:filter-ptf-logs
Merged
Filter out unnecessary PTF logs when calling the ptfadapter plugin#1828wangxin merged 1 commit intosonic-net:masterfrom wangxin:filter-ptf-logs
wangxin merged 1 commit intosonic-net:masterfrom
wangxin:filter-ptf-logs
Conversation
If use ptfadapter in test script, a debug level log message is generated for each sent packet. This is unnecessary and could significantly inflate the log file size. This change grabs the 'dataplane' logger and set its level to warning in `tests/conftest.py`. Signed-off-by: Xin Wang <xiwang5@microsoft.com>
bingwang-ms
approved these changes
Jun 29, 2020
kazinator-arista
pushed a commit
to kazinator-arista/sonic-mgmt
that referenced
this pull request
Mar 4, 2026
a631f04 Add check_db_integrity script to setup.py (sonic-net#1828) ddf6793 Implement script null_route_helper (sonic-net#1737)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of PR
Summary:
Fixes # (issue)
If use ptfadapter in test script, a debug level log message is generated
for each sent packet. This is unnecessary and could significantly inflate the log
file size. This change grabs the 'dataplane' logger and set its level to warning
in
tests/conftest.py.Type of change
Approach
What is the motivation for this PR?
To much unnecessary log messages are generated when calling the ptfadapter plugin in test scripts. This PR is to filter out the unnecessary logs.
How did you do it?
Get logger
dataplaneand set its logging level to warning intests/conftest.py.How did you verify/test it?
Test run the
acl/test_acl.pyscript which uses the ptfadapter.Any platform specific information?
Supported testbed topology if it's a new test case?
Documentation