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

T6695: Machine-readable operational mode support for traceroute #4151

Open
wants to merge 3 commits into
base: current
Choose a base branch
from

Conversation

natali-rs1985
Copy link
Contributor

Change Summary

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes)
  • Migration from an old Vyatta component to vyos-1x, please link to related PR inside obsoleted component
  • Other (please describe):

Related Task(s)

Related PR(s)

Component(s) name

Proposed changes

Added new endpoint for http API /traceroute

How to test

vyos@vyos:~$ curl -k --location --request POST 'https://localhost/traceroute' --form data='{"op": "traceroute", "host": "192.0.1.1"}' --form key='foo'
{"success": true, "data": "{'report': {'mtr': {'src': 'vyos', 'dst': '192.0.1.1', 'tos': 0, 'tests': 1, 'psize': '64', 'bitpattern': '0x00'}, 'hubs': [{'count': 1, 'host': '192.168.122.1', 'Loss%': 0.0, 'Snt': 1, 'Last': 1.669, 'Avg': 1.669, 'Best': 1.669, 'Wrst': 1.669, 'StDev': 0.0}, {'count': 2, 'host': '192.168.179.2', 'Loss%': 0.0, 'Snt': 1, 'Last': 1.854, 'Avg': 1.854, 'Best': 1.854, 'Wrst': 1.854, 'StDev': 0.0}, {'count': 3, 'host': '???', 'Loss%': 100.0, 'Snt': 1, 'Last': 0.0, 'Avg': 0.0, 'Best': 0.0, 'Wrst': 0.0, 'StDev': 0.0}]}}\n", "error": null}

Smoketest result

Checklist:

  • I have read the CONTRIBUTING document
  • I have linked this PR to one or more Phabricator Task(s)
  • I have run the components SMOKETESTS if applicable
  • My commit headlines contain a valid Task id
  • My change requires a change to the documentation
  • I have updated the documentation accordingly

Copy link

github-actions bot commented Oct 11, 2024


Commit title 'Merge branch 'current' into T6695' does not match the required format!. Valid title example: T99999: make IPsec secure

Copy link

github-actions bot commented Oct 11, 2024

✅ No issues found in unused-imports check.. Please refer the workflow run

Copy link
Member

@dmbaturin dmbaturin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The logic seems fine. I have reservations about mixing formatting fixes with logic in one PR. Since formatting changes are in a separate commit, it's not an obstacle for merging, however.

@sever-sever
Copy link
Member

sever-sever commented Oct 16, 2024

I’m feeling that for op-mode diagnostic commands should be a separate endpoint.
This new endpoint will include several diagnostic commands like ping/traceroute/mtr/etc
https://infocenter.nokia.com/public/7750SR222R1A/index.jsp?topic=%2Fcom.nokia.System_Mgmt_Guide%2Fgnoi_system-ai9exj5yfo.html

But I’m not against merging it as it is at the moment

@sever-sever
Copy link
Member

There are conflicts

Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Copy link

Conflicts have been resolved. A maintainer will review the pull request shortly.

Copy link

CI integration ❌ failed!

Details

CI logs

  • CLI Smoketests (no interfaces) ❌ failed
  • CLI Smoketests (interfaces only) 👍 passed
  • Config tests 👍 passed
  • RAID1 tests 👍 passed
  • TPM tests 👍 passed

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

Successfully merging this pull request may close these issues.

4 participants