Commit Graph

3 Commits

Author SHA1 Message Date
PSMinIO Developer 2c3cd7fb41 Reduce error handling verbosity and start enhanced upload cmdlet
- Simplified error handling to show only essential information:
  * Operation, Message, ExceptionType, InnerExceptionType, InnerExceptionMessage
  * Removed system info, stack traces, and operation details for cleaner output
- Started enhancing New-MinIOObject cmdlet with parameter sets:
  * SingleFile: Original single file upload functionality
  * Files: FileInfo[] support for multiple file uploads
  * Directory: DirectoryInfo support with recursive options
- Added new parameters for enhanced functionality:
  * BucketDirectory for organizing uploads into nested structures
  * Recursive, MaxDepth, Flatten for directory uploads
  * InclusionFilter, ExclusionFilter for file filtering
  * Force parameter for overwriting existing objects

Next: Complete the parameter set implementation and add multi-layer progress tracking.
2025-07-11 17:27:01 -04:00
PSMinIO Developer 83cbe8b1ef Fix threading issues in HTTP operations
- Resolved PowerShell cmdlet method calls from background threads
- Wrapped HTTP operations in Task.Run for proper thread context
- Fixed progress callback threading issues in upload/download
- Enhanced error handling with thread-safe logging
- All functionality now working: connection, buckets, upload, download
- Content verification passing with proper progress tracking

Threading fix ensures PowerShell cmdlet methods are only called from main thread,
eliminating 'WriteObject and WriteError methods cannot be called from outside' errors.
2025-07-11 17:21:21 -04:00
PSMinIO Developer 140257d469 Implement centralized enhanced error handling
- Created MinIOErrorHandler utility with comprehensive error details
- Captures Message, ExceptionType, InnerException, StackTrace, Timestamp, Machine, ProcessId
- Provides detailed logging with Write-Warning for debugging
- Integrated with MinIOBaseCmdlet ExecuteOperation methods
- Fixed parameter name consistency (BucketName across all cmdlets)
- Supports both terminating and non-terminating error handling
- Automatic error category determination based on exception type

This addresses the requirement for centralized C# error handling that provides
detailed debugging information without requiring manual debug code additions.
2025-07-11 14:53:41 -04:00