* fix(bookdrop): fix 'Select All' query logic and improve filename fallback for missing metadata
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix(tests): update BookDropServiceTest and PathPatternResolverTest to use findAllIds method
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
---------
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix: add retry and retry delays to handle smb lag
* fix: issue with importing cb7 files. missing required dependency. Scan would fail prematurely if a cb7 file was present
* fix: cleanup empty subdirectories when cleaning up parent folders
* fix: update folder cleanup to account for SMB delays
* chore: cleanup redundant and weak tests from auto-generated unit tests
* fix: make sleep function name more descriptive
* fix: minor optimisation around path matching
* fix: update xz package to latest version
* feat(bookmark): implement bookmark management with CRUD operations and UI integration
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* feat(bookmark): add uniqueness constraint for bookmarks and check for existing bookmarks before creation
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
---------
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix(search): Optimize book search with denormalized search_text column
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix(search): Enhance search text normalization for diacritics in author names
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix(migration): Implement batch processing for populating search text and enhance error handling
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix(search): Manually trigger search text update after author modifications and enhance special character handling
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix(search): Update special character handling to be more permissive in search text normalization
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* feat(AppMigrationService): add FileService dependency for enhanced file handling
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* feat(database): add search_text column to book_metadata for improved search functionality
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* feat(database): add search_text column to book_metadata for improved search functionality
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix(database): correct join condition and ordering in findBooksForMigrationBatch query
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
---------
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* refactor(api): minor QOL updates, code modernization
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* refactor(oidc): replace regex literals with compiled patterns for improved performance
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* refactor(shelf): remove redundant icon type initialization method
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
---------
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
This commit enhances the OPDS server with two major features:
1. Series Metadata in OPDS Feed:
- Add series name and book number to OPDS book entries
- Uses standard OPDS/EPUB 3 metadata format with <meta> tags
- Includes belongs-to-collection and group-position properties
2. Authors Navigation Hierarchy:
- Add new /authors endpoint for browsing books by author
- Implement authors list navigation feed with alphabetical sorting
- Add author filtering to catalog feed via ?author parameter
- Support library-based access control for author lists
- Add authors link to root OPDS navigation
Changes:
- OpdsFeedService: Add series metadata to appendMetadata(), add generateAuthorsNavigation()
- OpdsController: Add getAuthorsNavigation() endpoint
- OpdsBookService: Add getDistinctAuthors() and getBooksByAuthorName() methods
- BookOpdsRepository: Add queries for distinct authors and books by author name
- Updated generateCatalogFeed() to support author parameter
- Updated determineFeedTitle() and determineFeedId() to handle author context
Co-authored-by: Claude <noreply@anthropic.com>
* Add mobile OIDC authentication endpoint
This adds a new REST endpoint for mobile applications to complete OIDC
authentication. Mobile apps cannot use the web-based OIDC callback because
they need to receive tokens via a custom URL scheme.
New endpoints:
- POST /api/v1/auth/mobile/oidc/callback
Accepts authorization code, PKCE verifier, and redirect URI.
Returns Booklore JWT tokens (accessToken, refreshToken).
- GET /api/v1/auth/mobile/oidc/redirect
Alternative endpoint that redirects to the mobile app's URL scheme
with tokens as query parameters.
The flow works as follows:
1. Mobile app initiates OIDC auth with PKCE, using its own redirect URI
2. User authenticates with the OIDC provider
3. OIDC provider redirects to Booklore server's oauth2-callback
4. Mobile app calls this new endpoint with the authorization code
5. Booklore exchanges the code for OIDC tokens
6. Booklore validates the tokens and provisions/finds the user
7. Booklore issues its own JWT tokens to the mobile app
This enables iOS/Android apps to use OIDC authentication with Booklore.
* Fix compilation issues in MobileOidcController.java
* fix(amazon): review date parsing to support Japanese formats
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* refactor: enhance Amazon metadata parser robustness and domain support
- Add missing Amazon domains (AE, SA, CN, SG, TR, EG, BE) to DOMAIN_LOCALE_MAP.
- Implement fallback selectors for Title, Authors, Description, Publisher, Publication Date, and ISBNs to support legacy and variant page layouts.
- Support localized 'Publisher' labels (e.g., Herausgeber, Éditeur, Uitgever) in detail bullets.
- Fix brittle date parsing by searching for dates in detail bullets when RPI attributes are missing.
- Improve author extraction with multiple fallback strategies.
---------
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* fix(bookdrop): gate library re-registration during single-file moves
- query MonitoringService to see if the library is actively watched before
unregistering/re-registering it
- lower log noise for these operations and monitoring registration
- expose MonitoringService#isLibraryMonitored via MonitoringRegistrationService
- add FileMoveServiceTest covering monitored vs unmonitored scenarios
This fixes issues when importing multiple files via bookdrop.
Refs: #1608
* fix(bookdrop): avoid unnecessary stacktrace
* Use `deleteIfExists` to avoid trying to delete a missing file
This happens regularly as the file has already been removed by other methods
* Feature/kobo sync cbx support (#3)
* Feature: Add CBX syncing support to Kobo sync (#2)
* feat: add cbx sync support
* fix: phrasing of setting description to align with CBX terminology
* fix: resolve issue with CBX setting persistence
* fix: updated dev docker compose to align with Dockerfile
* feat: add cbx files as allowed entitlements
* fix: relax tomcat query characters for kobo sync
* fix: remove hardcoded epub restrictions
* fix: reduce image size and resolve relative content paths
* fix: resolve issues with the image file encoding
* feat: add rar and cb7 support
* feat: bring generated epub more in line with epub standard
* fix: resolve issues with extra metadata fields
* fix: make css background colour white to improve e-ink performance
* cleanup: code comments
* feat: add cbx unit tests
* fix: update zipfile to use builder pattern as current method is deprecated
* fix: remove comments
* fix: replace regex pattern to a simpler check
* fix: remove unused imports
* fix: update epub template to use standard language string
* fix: missing line end on css
* fix: remove duplicate query characters
* fix: grammer issue
* fix: resolve typo in the entitlement service test
* fix: redundant imports and update long types
* chore: update test descriptions for cbx conversion
* fix: add check for larger images in archive files. unlikely to occur.
* fix: merge temp dir logic for the book download
* fix: update kobo entitlement to always report the format as epub3
* fix: implement suggested changes around javadocs and some edge cases to handle gracefully
* chore: cleanup variable names to be clearer in download service
* feat: change function to extract to disk instead of storing images in memory
* fix: add temp file clean up into the conversion service
* fix: add visual divider to seperate CBX and EPUB settings
* fix: update lambdas to use method references
* fix: reword setting description for cbx to epub sync
---------
Co-authored-by: Aditya Chandel <8075870+adityachandelgit@users.noreply.github.com>
* feat: kobo sync improvements (push changes from booklore, and properly delete kobo data on reset)
* fix: issues with sync race conditions and improve readability
* fix: update function names to be clearer and more explicit
* fix: move partially_read to reading status mapping
* fix: make the bufferwindow more explicit in the unsynced progress check
* chore: add unit tests for additional sync logic
* fix: improve bi-directional logic to account for changes in progress and status
* chore: add additional tests to check the kobo sync logic and remove redundant tests
* refactor(exception): modernize exception handling and method signatures across services and controllers
- Remove unnecessary checked exceptions from method signatures
- Replace IOException with UncheckedIOException where appropriate
- Update test methods to match new signatures and remove throws declarations
- Improve converter classes with type safety, logging, and null handling
- Simplify collection assignment logic in metadata and book services
- Enhance author and category tokenization in HardcoverParser
- Add equals/hashCode to ShelfEntity for proper set behavior
- Add comprehensive unit tests for converter and service classes
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
* refactor(entity): update equality and hashCode for JPA entities to use ID; add comprehensive tests and adjust test data to set IDs
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>
---------
Signed-off-by: Balázs Szücs <bszucs1209@gmail.com>