Releases: siamakrostami/SRNetworkManager
1.0.28
1.0.27
feat: Add comprehensive documentation and enhance library features - Add complete API documentation for all public interfaces - Implement comprehensive README with usage examples and best practices - Add thread safety documentation and implementation notes - Document all core components: APIClient, NetworkRouter, NetworkError - Add detailed documentation for RetryHandler and DefaultRetryHandler - Document SendablePromise with thread safety examples - Add APIVersion documentation with usage patterns - Document Data extensions with practical examples - Add comprehensive NetworkParameterEncoding documentation - Document HeaderHandler with type-safe header management
1.0.26
Fix(RetryHandler): Minor changes in RetryHandler Protocol
1.0.25
Fixed
- Swift 6 Compatibility: Added
Sendableconstraint to streaming methods to resolve data race warnings- Fixed "sending 'decodedObject' risks causing data races" errors in
StreamingSessionDelegate - All streaming methods now require decoded types to conform to both
CodableandSendable - Ensures thread-safe operation when passing decoded objects through continuations
- Fixed "sending 'decodedObject' risks causing data races" errors in
- Multi-Platform Support: Resolved Swift 6 strict concurrency build failures across all supported platforms:
- iOS 13.0+
- tvOS 13.0+
- watchOS 7.0+
- macOS 13.0+
Technical Details
- Updated
streamRequest<T>to requireT: Codable & Sendable - Updated
asyncStreamRequest<T>to requireT: Codable & Sendable - Modified
StreamingSessionDelegate<T>generic constraint toT: Codable & Sendable - No breaking changes for non-streaming API methods
1.0.24
🛡️ Thread Safety & Swift 6 Compatibility
Major Improvements
Swift 6 Ready: Full compatibility with Swift 6 concurrency model
Sendable Compliance: Properly implemented Sendable protocol across all network components
Race Condition Fixes: Eliminated potential data races in concurrent operations
Specific Enhancements
Added thread-safe property accessors throughout APIClient
Implemented queue-synchronized collections for requestsToRetry and activeSessions
Created proper barrier flags for write operations to ensure safety
Fixed StreamingSessionDelegate to safely handle concurrent data buffer access
Enhanced SendablePromise with dedicated synchronization queue
Added proper @unchecked Sendable handling with manual synchronization
Improved session tracking with thread-safe cleanup
Under the Hood
Standardized synchronization patterns with queue.sync
Optimized lock usage to prevent potential deadlocks
Reduced shared mutable state exposure
This version marks a significant improvement in stability for multi-threaded environments and prepares the framework for Swift 6's stricter concurrency requirements.
1.0.23
🛡️ Thread Safety & Swift 6 Compatibility
Major Improvements
- Swift 6 Ready: Full compatibility with Swift 6 concurrency model
- Sendable Compliance: Properly implemented Sendable protocol across all network components
- Race Condition Fixes: Eliminated potential data races in concurrent operations
Specific Enhancements
- Added thread-safe property accessors throughout APIClient
- Implemented queue-synchronized collections for requestsToRetry and activeSessions
- Created proper barrier flags for write operations to ensure safety
- Fixed StreamingSessionDelegate to safely handle concurrent data buffer access
- Enhanced SendablePromise with dedicated synchronization queue
- Added proper @unchecked Sendable handling with manual synchronization
- Improved session tracking with thread-safe cleanup
Under the Hood
- Standardized synchronization patterns with queue.sync
- Optimized lock usage to prevent potential deadlocks
- Reduced shared mutable state exposure
This version marks a significant improvement in stability for multi-threaded environments and prepares the framework for Swift 6's stricter concurrency requirements.