app_logger_manager 2.0.0 copy "app_logger_manager: ^2.0.0" to clipboard
app_logger_manager: ^2.0.0 copied to clipboard

A comprehensive Flutter app log manager package for your app.

Changelog #

All notable changes to the App Log Manager package will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

2.0.0 - 2025-07-29 #

⚠️ Breaking Changes #

  • Simplified Logging API: Streamlined logging methods to improve usability and performance

    • Removed optional parameters (tag, context, source, method, lineNumber) from basic logging methods (debug, info, warning, error, fatal, verbose)
    • These parameters are now handled internally or through specialized logging methods
    • This change makes the basic logging API cleaner and more intuitive
  • LogEntry Model Simplification: Reduced complexity of the LogEntry model

    • Removed fields: context, source, method, lineNumber
    • Kept essential fields: level, message, timestamp, tag, error, stackTrace, userId, sessionId, correlationId
    • This change improves performance and reduces memory usage

✨ Enhanced #

  • Dependency Updates: Updated to latest stable versions for better performance and security

    • flutter_shared_utilities: Updated from ^1.0.4 to ^1.0.14
    • logger: Updated from ^2.5.0 to ^2.6.1
    • custom_lint: Updated from ^0.7.5 to ^0.8.0
    • flutter_custom_lints: Updated from ^1.0.3 to ^1.0.18
  • Example App Improvements: Updated example application to showcase the simplified API

    • Improved log stream viewer widget performance
    • Better demonstration of new simplified logging methods
    • Enhanced UI for testing different logging scenarios

πŸ› οΈ Technical Improvements #

  • API Clarity: More focused and easier-to-use logging interface
  • Performance Optimizations: Reduced overhead from simplified models and methods
  • Better Documentation: Updated documentation to reflect the new simplified API
  • Improved Maintenance: Cleaner codebase with reduced complexity

πŸ“š Migration Guide #

To migrate from v1.x to v2.0.0:

  1. Update logging calls: Remove extra parameters from basic logging methods

    // Before (v1.x)
    logger.info('Message', tag: 'MyTag', context: {'key': 'value'});
    
    // After (v2.0.0)
    logger.info('Message');
    
  2. Use specialized methods: For advanced logging with context, use specialized methods

    // For user actions
    logger.logUserAction('button_click', screen: 'home', parameters: {'id': '123'});
    
    // For API calls
    logger.logApiCall('GET', '/api/users', statusCode: 200);
    
  3. LogEntry construction: Remove deprecated fields when creating custom LogEntry instances

    // Before (v1.x)
    LogEntry(level: LogLevel.info, message: 'Test', context: {...}, source: 'file.dart');
    
    // After (v2.0.0)
    LogEntry(level: LogLevel.info, message: 'Test', tag: 'MyTag');
    

1.0.2 - 2025-06-22 #

  • Fix linter problems
  • Add additional public API documentations

1.0.1 - 2025-06-22 #

  • Fix app logger import from flutter_shared_utilities package

1.0.0 - 2025-06-22 #

πŸŽ‰ Initial Release #

The first stable release of App Log Manager - a comprehensive Flutter logging package with advanced features for production applications.

✨ Added #

Core Logging Features

  • Complete Log Level System: 8 log levels (none, fatal, error, warning, info, debug, verbose, all) with priority-based filtering
  • Structured Logging: Rich LogEntry model with context, tags, metadata, and source tracking
  • Real-time Log Streaming: Stream-based architecture for live log monitoring and UI updates
  • Context Tracking: Built-in support for user ID, session ID, and correlation ID tracking
  • Source Code Tracking: Automatic capture of source file, method name, and line number

Advanced Logging Capabilities

  • Performance Monitoring: logPerformance() method for timing operations and performance metrics
  • API Call Logging: logApiCall() with comprehensive HTTP request/response tracking
  • User Action Tracking: logUserAction() and logFeatureUsage() for user behavior analytics
  • Security Event Logging: logSecurity() for security-focused event tracking
  • Business Event Analytics: logBusinessEvent() for custom business metrics and KPIs
  • Crash Reporting: logCrash() with automatic Flutter and platform error handling
  • Navigation Logging: logNavigation() for route changes and user flow tracking

Developer Experience

  • Interface-based Architecture: AppLogger abstract interface for dependency inversion
  • Factory Pattern: LogManagerFactory with 8+ pre-configured logger instances:
    • createDefault() - Basic logger with console output
    • createDevelopmentLogger() - Verbose development logging
    • createProductionLogger() - File-based production logging
    • createConsoleLogger() - Console-only output
    • createFileLogger() - File-based persistent logging
    • createTestLogger() - In-memory testing logger
    • createApiLogger() - API monitoring specialized logger
    • createPerformanceLogger() - Performance monitoring logger
    • createSecurityLogger() - Security-focused logging
  • Type Safety: Built with null safety and safe type conversion methods
  • Rich Formatting: Emoji icons, ANSI colors, and customizable log formatters

Storage and Persistence

  • Multiple Storage Backends: Console output, file logging, and custom storage implementations
  • File Logging: Persistent file-based logging with configurable paths
  • In-Memory Storage: Fast in-memory storage for testing and development
  • Custom Storage Interface: LogStorage interface for implementing custom backends
  • Log Retrieval: Query logs by count, level, tag, and date range
  • Export Functionality: JSON export capabilities for log sharing and analysis

Production Features

  • Environment Configurations: Optimized presets for development, production, and testing
  • Log Sanitization: Automatic removal of sensitive data (passwords, emails, credit cards, phone numbers)
  • Memory Management: Configurable log retention limits and automatic cleanup
  • Performance Optimized: Efficient logging with minimal performance impact
  • Error Handling: Comprehensive error handling with graceful degradation

Models and Utilities

  • LogLevel Enum: Complete log level enumeration with priorities, labels, and utilities
  • LogEntry Model: Comprehensive log entry model extending BaseDataModel
  • Log Formatters: Utility class for formatting durations, bytes, and objects
  • Custom Log Printer: Enhanced log printer with emoji icons and better formatting

Example Application

  • Comprehensive Demo App: Full-featured example app demonstrating all logging capabilities
  • Interactive UI: Live log streaming viewer and interactive demo controls
  • Real-world Examples: Practical examples of logging in different scenarios
  • Clean Architecture: Example follows Flutter best practices and clean architecture

πŸ› οΈ Technical Details #

Dependencies

  • flutter: SDK dependency for Flutter framework integration
  • flutter_shared_utilities: ^1.0.3: Utilities for base data models and common functionality
  • logger: ^2.5.0: Enhanced console logging capabilities

Development Dependencies

  • flutter_test: Testing framework for comprehensive test coverage
  • custom_lint: ^0.7.5: Custom linting rules for code quality
  • flutter_custom_lints: ^1.0.3: Flutter-specific linting rules

Platform Support

  • βœ… iOS: Full support for iOS applications
  • βœ… Android: Full support for Android applications
  • βœ… Web: Full support for Flutter web applications
  • βœ… macOS: Full support for macOS desktop applications
  • βœ… Windows: Full support for Windows desktop applications
  • βœ… Linux: Full support for Linux desktop applications

Dart/Flutter Requirements

  • Dart: >= 3.8.1
  • Flutter: >= 3.8.1
  • Full null safety support
  • Compatible with latest Flutter stable releases

πŸ“š Documentation #

  • Comprehensive README with usage examples and API documentation
  • Complete API documentation with detailed method descriptions
  • Example app with practical implementation patterns
  • Inline code documentation following Dart documentation standards

πŸ§ͺ Testing #

  • Unit tests for core logging functionality
  • Widget tests for UI components in example app
  • Integration tests for end-to-end logging workflows
  • Mock implementations for testing custom storage backends

πŸ”’ Security #

  • Built-in data sanitization for sensitive information
  • Secure file logging with appropriate permissions
  • No data collection or transmission to external services
  • Privacy-focused design with local-only logging by default

[Unreleased] #

πŸ”„ Coming Soon #

  • Remote logging capabilities with secure transmission
  • Log aggregation and centralized logging server support
  • Advanced filtering and search capabilities
  • Performance dashboard and analytics
  • Integration with popular monitoring services
  • Custom log level definitions
  • Batch logging for high-performance scenarios
  • Log compression and archiving features

Note: This changelog follows Keep a Changelog format. For detailed technical changes, see the GitHub commit history.

Legend #

  • πŸŽ‰ Major releases and milestones
  • ✨ New features and enhancements
  • πŸ› οΈ Technical improvements and changes
  • πŸ”§ Configuration and setup changes
  • πŸ› Bug fixes and corrections
  • πŸ“š Documentation updates
  • πŸ§ͺ Testing improvements
  • πŸ”’ Security enhancements
  • ⚠️ Deprecations and breaking changes
  • πŸ”„ Future plans and roadmap items
0
likes
160
points
279
downloads

Publisher

unverified uploader

Weekly Downloads

A comprehensive Flutter app log manager package for your app.

Repository (GitHub)
View/report issues

Topics

#logging #log-manager #log-manager-flutter #pretty-logger

Documentation

API reference

License

MIT (license)

Dependencies

flutter, flutter_shared_utilities, logger

More

Packages that depend on app_logger_manager