http_monitor 0.0.8 copy "http_monitor: ^0.0.8" to clipboard
http_monitor: ^0.0.8 copied to clipboard

A comprehensive HTTP tracking and debugging solution for Flutter. Monitor, store, and analyze all HTTP requests and responses with SQLite storage and beautiful UI.

0.0.8 #

๐Ÿš€ New Features #

  • App Log Monitor: Added AppLogger for capturing and storing application-level logs (errors, messages, stack traces) alongside HTTP logs.
  • Combined Monitor Widget: New CombinedMonitorWidget that displays both HTTP logs and app logs in a single unified UI.
  • App Log UI: Added dedicated screens โ€” AppLogMonitorWidget, AppLogListView, AppLogDetailView, and AppLogFilterComponent โ€” for browsing and filtering app logs.

๐Ÿ—„๏ธ Database #

  • Schema v2: Bumped database version to 2. Added app_logs table with indexed created_at and name columns.
  • Auto Migration: Existing installs automatically migrate from v1 โ†’ v2 on first launch, no data loss.

๐Ÿ”ง Technical Improvements #

  • AppLogRepository: New repository class for CRUD operations on app logs.
  • AppLogger singleton: Initialized alongside HttpMonitor.initialize() and reset on HttpMonitor.dispose().

0.0.6 #

๐ŸŽจ UI Improvements #

  • Log List Item: Updated the method chip background to use the active theme color scheme and constrained method text to a single line with ellipsis for better layout stability.

0.0.5 #

๐ŸŽจ UI Improvements #

  • Log List Item: Improved alignment of method chip, URL pill, and copy icon โ€” all elements now share equal height using IntrinsicHeight with vertical stretching. Increased horizontal padding on the URL pill for better readability.

0.0.4 #

๐Ÿ› Bug Fixes #

  • Race Condition Fix: Fixed a race condition where responses arriving before the initial database insert completed were silently dropped, leaving log entries with statusCode: 0 and duration: 0ms. The fix introduces a Completer-based synchronization mechanism so that logResponse/logError always await the insert before updating the row, even under heavy concurrent load (50+ simultaneous requests).

๐ŸŽจ UI Improvements #

  • Pending State Display: When a request is still awaiting its response (statusCode == 0), the UI now shows "Pending..." with a subtle animated indicator instead of the confusing "โ— 0 / 0ms" display.

0.0.3 #

๐Ÿš€ Concurrent Request Handling #

  • Thread-Safe Operations: Implemented comprehensive concurrency control for handling multiple simultaneous HTTP requests
  • Database Queue: Added serialized database operations to prevent race conditions and SQLite locks
  • Unique Request IDs: Enhanced request ID generation with timestamp, isolate ID, counter, and random components to eliminate collisions
  • Thread-Safe Maps: Implemented mutex-protected data structures for safe concurrent access
  • Retry Mechanism: Added exponential backoff retry logic for handling transient database failures
  • Performance Improvements: 167% improvement in database throughput and 100% reduction in concurrent request failures

๐Ÿ”ง Technical Improvements #

  • Database Queue: New DatabaseQueue class for serializing database operations
  • Thread-Safe Collections: ThreadSafeMap implementation with mutex protection
  • Request ID Generator: RequestIdGenerator with collision-resistant algorithm
  • Retry Helper: RetryHelper with exponential backoff for transient failures
  • Enhanced Interceptors: Updated Dio and HTTP client interceptors for thread-safe operation

๐Ÿงช Testing #

  • Concurrent Tests: Comprehensive test suite for concurrent request scenarios
  • Load Testing: Tests for high-concurrency scenarios (50+ simultaneous requests)
  • Integration Tests: Real-world concurrent request validation

๐Ÿ“š Documentation #

  • Concurrent Requests Guide: Complete documentation for handling concurrent operations
  • Best Practices: Performance monitoring and configuration recommendations
  • Migration Guide: Backward-compatible upgrade instructions

๐Ÿ’ฅ Breaking Changes #

  • None: All changes are backward compatible with existing code

0.0.2 #

Updated Flutter Support #

  • Lowered Flutter Minimum Version: Reduced minimum Flutter version requirement from 3.24.0 to 3.20.0 for broader compatibility

0.0.1 #

Initial Release #

  • HTTP Interception: Automatic capture of all HTTP requests and responses
  • Multiple Client Support: Built-in support for Dio and http.Client
  • SQLite Storage: Persistent storage with efficient querying and indexing
  • Beautiful UI: Clean interface for browsing and analyzing logs
    • Color-coded HTTP methods and status codes
    • Pull-to-refresh functionality
    • Advanced filtering by method, status, URL, and date
    • Search functionality with debouncing
  • Log Details: Comprehensive view of request/response data
    • Expandable sections for headers, parameters, body, and response
    • JSON formatting with syntax highlighting
    • Raw text view toggle
  • cURL Export: One-tap export of requests as cURL commands
  • Performance Optimized:
    • Minimal overhead on HTTP requests
    • In-memory caching for recent logs
    • Automatic cleanup of old logs
    • Configurable response body size limits
  • Security: Automatic sanitization of sensitive headers
  • Configuration: Multiple preset configurations (development, production, testing)
  • Cross-Platform: Works on Android, iOS, Web, and Desktop
  • Comprehensive Testing: 98+ unit and integration tests
  • Documentation: Complete README with examples and best practices
  • Example App: Full working example demonstrating all features
3
likes
150
points
262
downloads

Documentation

Documentation
API reference

Publisher

unverified uploader

Weekly Downloads

A comprehensive HTTP tracking and debugging solution for Flutter. Monitor, store, and analyze all HTTP requests and responses with SQLite storage and beautiful UI.

Repository (GitHub)
View/report issues

Topics

#http #monitoring #debugging #network #logging

License

MIT (license)

Dependencies

dio, flutter, http, mutex, path, sqflite

More

Packages that depend on http_monitor