Skip to content
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

interface: add depth parameter to get_facts #29

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

alagoutte
Copy link

sometimes like for check if an interface exist, you need only to get depth with length 1

avoid to get all data (more speed and efficentiy )

example with Aruba-CX OVA :

with depth=1
"GET /rest/v10.09/system/interfaces?depth=1 HTTP/1.1" "/rest/v10.09/system/interfaces?depth=1" 200 3068 "-" "python-requests/2.28.1"

with depth=2
"GET /rest/v10.09/system/interfaces?depth=2 HTTP/1.1" "/rest/v10.09/system/interfaces?depth=2" 200 1256622 "-" "python-requests/2.28.1" -

3Kb vs 1.19Mb !

sometimes like for check if an interface exist, you need only to get depth with length 1

avoid to get all data (more speed and efficentiy )

example with Aruba-CX OVA :

with depth=1
"GET /rest/v10.09/system/interfaces?depth=1 HTTP/1.1" "/rest/v10.09/system/interfaces?depth=1" 200 3068 "-" "python-requests/2.28.1"

with depth=2
"GET /rest/v10.09/system/interfaces?depth=2 HTTP/1.1" "/rest/v10.09/system/interfaces?depth=2" 200 1256622 "-" "python-requests/2.28.1" -

3Kb vs 1.19Mb !
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.

None yet

1 participant