-
Notifications
You must be signed in to change notification settings - Fork 5
2.3.0 #35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This reverts commit ab8f67a.
…goQueries/AdvancedMangoQueries-5.swift Co-authored-by: Copilot <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces version 2.2.0 with comprehensive improvements to the CouchDB Swift client library, focusing on advanced Mango queries, attachments API, and index management capabilities.
- Advanced Mango queries with type-safe selectors, comparisons, sorting, and projection support
- Complete attachments API for uploading, downloading, and deleting binary files
- Index management functionality with creation, listing, and query explanation capabilities
Reviewed Changes
Copilot reviewed 23 out of 23 changed files in this pull request and generated 5 comments.
Show a summary per file
File | Description |
---|---|
Sources/CouchDBClient/Models/MangoQuery.swift | New models for type-safe Mango query construction with selectors, sorting, and pagination |
Sources/CouchDBClient/Models/MangoIndex.swift | Index definition and management models with creation/listing response types |
Sources/CouchDBClient/Models/MangoExplainResponse.swift | Query execution plan response model for optimization analysis |
Sources/CouchDBClient/CouchDBClient.swift | Enhanced client with new find method, index operations, and complete attachments API |
Tests/CouchDBClientTests/MangoQueryTests.swift | Comprehensive test suite for Mango query encoding/decoding functionality |
Tests/CouchDBClientTests/AttachmentsAPITests.swift | Full test coverage for attachment operations with binary data handling |
Tests/CouchDBClientTests/CouchDBClientTests.swift | Updated tests using new MangoQuery API and additional error handling scenarios |
Documentation files | New tutorials and updated documentation for advanced query features |
README.md | Enhanced documentation with feature list, usage examples, and platform support details |
Major Features & Enhancements
Advanced Mango Queries Support
useIndex
in queries to optimize performance.Attachments API
Index Management
MangoIndex
,IndexDefinition
).Query Explain
_explain
endpoint viaMangoExplainResponse
to inspect how queries are executed and which indexes are used.Documentation
Testing
Breaking Changes
Mango Queries API
find
method now expects aMangoQuery
instead of a generic selector dictionary.MangoQuery
.Tests
Miscellaneous
Upgrade Notes:
If you use Mango queries or attachments, please update your code to use the new
MangoQuery
,MangoIndex
, and attachment API signatures as shown in the updated documentation and code samples. For Swift 6+, enjoy strict concurrency and actor-based client; for Swift 5.x, use version 1.7.0.