1
0
Fork 1
mirror of https://github.com/thatmattlove/hyperglass.git synced 2026-01-30 05:49:22 +00:00
Commit graph

107 commits

Author SHA1 Message Date
WilhelmZA
93edf34ccf
Merge branch 'main' into structured 2025-09-30 16:49:45 +02:00
Wilhelm Schonfeldt
9db9849a59
feat(structured): release structured feature set (squash merge)
Summary:
- Add structured traceroute support with comprehensive IP enrichment (ASN/org/RDNS).
- Improve MikroTik traceroute cleaning and aggregation; collapse repeated tables into a single representative table.
- Enhance traceroute logging for visibility and add traceroute-specific cleaning helpers.
- Add/adjust IP enrichment plugins and BGP/traceroute enrichment integrations.
- UI updates for traceroute output and path visualization; update docs and configuration for structured output.

This commit squashes changes from 'structured-dev' into a single release commit.
2025-09-30 16:46:01 +02:00
Jason Hall
98abca6e8e Update ssh.py
Fixed linting errors
2025-09-29 20:29:05 -04:00
Jessie Bryan
2868d505b8 fix(proxy): pass proxy.port to open_tunnel as ssh_port keyword 2025-09-29 20:29:05 -04:00
Wilhelm Schonfeldt
0398966062
feat: Add structured traceroute support with comprehensive IP enrichment
MAJOR NEW ARCHITECTURE - STRUCTURED TRACEROUTE:
- Complete rewrite of traceroute data processing with structured output
- Dedicated TracerouteResult and TracerouteHop data models
- Platform-specific parsers with unified output format
- Rich metadata including ASN, organization, country, and prefix information
- AS path visualization with organization names in React Flow charts

SUPPORTED PLATFORMS:
- TraceroutePluginMikrotik: Handles MikroTik's complex multi-table format
  * Progressive statistics parsing with deduplication
  * Timeout hop handling and continuation line processing
  * Loss percentage and RTT statistics extraction
- TraceroutePluginHuawei: Unix-style traceroute format parser
  * Standard hop_number ip_address rtt format support
  * Timeout hop detection with * notation
  * Automatic cleanup of excessive trailing timeouts

COMPREHENSIVE IP ENRICHMENT SYSTEM:
- Offline enrichment using BGP.tools bulk data (1.3M+ CIDR entries)
- PeeringDB integration for IXP detection and ASN organization data
- Ultra-fast pickle cache system with combined data files
- Integer-based bitwise IP matching for maximum performance
- Bulk ASN organization lookup capabilities
- Private/reserved IP handling with AS0 fallbacks
- Country code mapping from ASN database
- Graceful fallbacks for missing enrichment data

FRONTEND ENHANCEMENTS:
- New traceroute table components with consistent formatting
- Enhanced AS path visualization with organization names
- Improved copy-to-clipboard functionality with structured data
- Unified table styling across BGP and traceroute results
- Better error handling and loading states

CONCURRENT PROCESSING INFRASTRUCTURE:
- Thread executor implementation for blocking I/O operations
- Query deduplication system to prevent resource conflicts
- Non-blocking Redis cache operations using asyncio executors
- Event coordination for waiting requests
- Background cleanup for completed operations
- Prevents website hangs during long-running queries

PLUGIN ARCHITECTURE IMPROVEMENTS:
- Platform-aware plugin system with proper execution restrictions
- Enhanced MikroTik garbage output cleaning
- IP enrichment plugins for both BGP routes and traceroute
- Conditional plugin execution based on platform detection
- Proper async/sync plugin method handling

CRITICAL BUG FIXES:
- Fixed double AS prefix bug (ASAS123456 → AS123456)
- Resolved TracerouteHop avg_rtt field/property conflicts
- Corrected Huawei traceroute source field validation
- Fixed plugin platform restriction enforcement
- Eliminated blocking I/O causing UI freezes
- Proper timeout and empty response caching prevention
- Enhanced private IP range detection and handling

PERFORMANCE OPTIMIZATIONS:
- Pickle cache system reduces startup time from seconds to milliseconds
- Bulk processing for ASN organization lookups
- Simplified IXP detection using single PeeringDB API call
- Efficient CIDR network sorting and integer-based lookups
- Reduced external API calls by 90%+
- Optimized memory usage for large datasets

API & ROUTING ENHANCEMENTS:
- Enhanced API routes with proper error handling
- Improved middleware for concurrent request processing
- Better state management and event handling
- Enhanced task processing with thread pool execution

This represents a complete transformation of hyperglass traceroute capabilities,
moving from basic text output to rich, structured data with comprehensive
network intelligence and concurrent processing support.
2025-09-28 13:48:04 +02:00
Carlos Santos
413c60e29f
Update ssh_netmiko.py 2025-09-13 00:04:44 -03:00
Jason Hall
cf137bd7e8
format and lint 2025-06-14 21:44:20 -04:00
thatmattlove
0f52bc438f closes #268: fix issue with mikrotik commands 2024-06-30 23:55:05 -04:00
thatmattlove
e0751311ba remove unnecessary logging 2024-06-30 23:54:37 -04:00
thatmattlove
41248231ae fix logging issues 2024-06-30 23:22:46 -04:00
thatmattlove
e84cc4ac00 remove deprecated pydantic constr usage 2024-05-27 14:41:04 -04:00
thatmattlove
d2f734ba1c logging overhaul 2024-04-01 23:42:07 -04:00
thatmattlove
a8476f2ea9 fix import sorting 2024-03-17 16:04:41 -04:00
thatmattlove
d706ff1959 fix test fixtures 2024-03-17 15:59:34 -04:00
thatmattlove
77c0a31256 upgrade major dependencies 2024-03-16 23:17:54 -04:00
thatmattlove
99ec07d055 fix issues causing test failure 2024-03-01 23:19:08 -05:00
thatmattlove
f0028a3df6 fix text output empty bug 2024-02-28 22:46:49 -05:00
thatmattlove
7fd35f5d6f fix device_type selection for linux platforms 2022-12-26 16:23:56 -05:00
thatmattlove
3e73d02c46 clean up compat module 2022-12-26 10:03:56 -05:00
thatmattlove
9c9a8469a4 replace flake8 with ruff for linting, refactor issues 2022-12-24 17:53:05 -05:00
thatmattlove
f37eb9abf7 add v2 docs, minor refactoring 2022-12-19 14:57:20 -05:00
thatmattlove
fc3ba3a8be clean up unused parameters and start work on 2.0.0 docs 2022-12-12 18:52:39 -05:00
thatmattlove
60429ebbc1 commit previous changes and dep updates 2022-12-11 17:30:20 -05:00
thatmattlove
dfca1a5bc1 Move isort configuration to pyproject.toml 2021-12-22 22:22:01 -07:00
thatmattlove
b49b6ea58e Allow customization of driver (Netmiko) configuration on a per-device basis 2021-12-08 12:00:02 -07:00
thatmattlove
c049569cab Update black 2021-12-06 17:12:30 -07:00
thatmattlove
55f8a62fb0 implement generic http client; remove hyperglass-agent connection handler 2021-11-07 01:19:29 -07:00
thatmattlove
60786d1cea Remove Scrapli 2021-10-06 16:54:04 -07:00
thatmattlove
7d5d64c0e2 Plugin/directive fixes 2021-09-21 07:54:16 -07:00
thatmattlove
e62af507ee Pass full query to output plugin instead of device 2021-09-18 12:47:56 -07:00
thatmattlove
85d7f8876e Refactor Device.type to Device.platform 2021-09-16 22:04:15 -07:00
thatmattlove
dda73cb370 Refactor and restructure directive model 2021-09-16 17:12:30 -07:00
thatmattlove
6bdfa9e645 Fix string output type checks 2021-09-16 15:57:33 -07:00
thatmattlove
bb1e66c2ef Implement better __repr__ generator 2021-09-16 15:35:12 -07:00
thatmattlove
4792269168 Fix query JSON serialization 2021-09-16 13:59:39 -07:00
thatmattlove
e06ea5ecb9 Add separate hooks for major state objects, add tests 2021-09-16 13:46:50 -07:00
thatmattlove
c99f98a6f0 Complete global state implementation 2021-09-15 18:25:37 -07:00
thatmattlove
a2ee4b50fa Implement global state 2021-09-15 00:57:45 -07:00
thatmattlove
f2cb15d0e2 Fix typing issues 2021-09-13 14:10:32 -07:00
thatmattlove
723048d1d1 Refactor nos naming to type/device_type 2021-09-13 10:00:44 -07:00
thatmattlove
1adad7e46d Implement plugins during execution workflow 2021-09-13 02:37:32 -07:00
thatmattlove
74fcb5dba4 Continue output plugin implementation 2021-09-12 18:27:33 -07:00
thatmattlove
52ebf4663c Update code formatting - line length 2021-09-12 15:09:24 -07:00
thatmattlove
a62785227e Start output plugin core implementation 2021-09-12 15:06:34 -07:00
thatmattlove
52b7cbdd3c Implement user API for plugins and fix plugin registration issues 2021-09-11 18:03:35 -07:00
thatmattlove
5ccfe50792 Complete directives implementation, refactor exceptions, deprecate VRFs, bump minimum Python version 2021-09-07 22:58:39 -07:00
thatmattlove
78571edb4e Closes #151: Fix issue with Junos parsing from d1160fe 2021-07-03 21:36:22 -07:00
checktheroads
d1160fe4ba Closes #150: Port BIRD AS_Path/Community handling from hyperglass-agent 2021-06-18 22:36:52 -07:00
checktheroads
6c5839be70 #143: Begin hyperglass-agent deprecation 2021-05-30 15:47:48 -07:00
checktheroads
4c948fd97f fix an issue with juniper as_path queries that only returned ipv4 or ipv6 routes (not both), causing queries to fail 2021-04-24 17:03:39 -07:00