diff --git a/backend/src/main/java/com/vaessl/app/homebox/HomeboxItemClient.java b/backend/src/main/java/com/vaessl/app/homebox/HomeboxItemClient.java index 10c29ec..44a51cb 100644 --- a/backend/src/main/java/com/vaessl/app/homebox/HomeboxItemClient.java +++ b/backend/src/main/java/com/vaessl/app/homebox/HomeboxItemClient.java @@ -43,7 +43,8 @@ public class HomeboxItemClient { * @param query optional keyword filter; {@code null} returns all items for the page * @param pageable page number and size to request * @return the mapped page of items along with the resolved connection ID - * @throws com.vaessl.app.exception.ConnectionNotFoundException if no matching connection is stored + * @throws com.vaessl.app.exception.ConnectionNotFoundException if no matching connection is + * stored * @throws com.vaessl.app.exception.RemoteApiException if Homebox returns an empty response body */ public HomeboxItemPage hbResponse(ConnectionIdentifiable connection, String query, diff --git a/backend/src/main/java/com/vaessl/app/sync/HomeboxSyncProvider.java b/backend/src/main/java/com/vaessl/app/sync/HomeboxSyncProvider.java index 678932e..0693cfc 100644 --- a/backend/src/main/java/com/vaessl/app/sync/HomeboxSyncProvider.java +++ b/backend/src/main/java/com/vaessl/app/sync/HomeboxSyncProvider.java @@ -14,10 +14,10 @@ import com.vaessl.app.vector.EmbeddingService; import lombok.RequiredArgsConstructor; /** - * Pages through the full Homebox catalog and re-indexes it into the vector store. - * Item IDs are collected across all pages before {@link EmbeddingService#deleteStaleVectorEntries} - * is called once at the end, rather than after each page: deleting per page would treat every - * item outside the current page as stale, wiping out entries from pages already synced. + * Pages through the full Homebox catalog and re-indexes it into the vector store. Item IDs are + * collected across all pages before {@link EmbeddingService#deleteStaleVectorEntries} is called + * once at the end, rather than after each page: deleting per page would treat every item outside + * the current page as stale, wiping out entries from pages already synced. */ @Component @RequiredArgsConstructor diff --git a/backend/src/main/java/com/vaessl/app/vector/EmbeddingService.java b/backend/src/main/java/com/vaessl/app/vector/EmbeddingService.java index f3effd2..0bf030d 100644 --- a/backend/src/main/java/com/vaessl/app/vector/EmbeddingService.java +++ b/backend/src/main/java/com/vaessl/app/vector/EmbeddingService.java @@ -12,9 +12,9 @@ import com.vaessl.app.shared.ServiceItem; import com.vaessl.app.shared.ServiceType; /** - * Embeds {@link ServiceItem}s into the shared vector store and prunes entries that no longer - * exist upstream. Kept stateless (no instance fields besides {@code vectorStore}) since this is - * a singleton bean shared across concurrent sync runs; callers own the per-sync ID accumulator. + * Embeds {@link ServiceItem}s into the shared vector store and prunes entries that no longer exist + * upstream. Kept stateless (no instance fields besides {@code vectorStore}) since this is a + * singleton bean shared across concurrent sync runs; callers own the per-sync ID accumulator. */ @Service public class EmbeddingService { @@ -92,10 +92,10 @@ public class EmbeddingService { } /** - * Deletes every vector for {@code connectionId} whose item ID is not in - * {@code currentItemIds}, then clears the accumulator. Must be called once, after every page - * for this sync run has gone through {@link #vectorizeData}, not per page — otherwise items - * from pages other than the most recent one would look stale and get deleted too. + * Deletes every vector for {@code connectionId} whose item ID is not in {@code currentItemIds}, + * then clears the accumulator. Must be called once, after every page for this sync run has gone + * through {@link #vectorizeData}, not per page — otherwise items from pages other than the most + * recent one would look stale and get deleted too. * * @param connectionId the connection to prune stale vectors for * @param currentItemIds every item ID seen across the full sync run; cleared after this call diff --git a/backend/src/test/java/com/vaessl/app/search/SearchControllerTest.java b/backend/src/test/java/com/vaessl/app/search/SearchControllerTest.java index 6ca73bb..680a54a 100644 --- a/backend/src/test/java/com/vaessl/app/search/SearchControllerTest.java +++ b/backend/src/test/java/com/vaessl/app/search/SearchControllerTest.java @@ -26,9 +26,9 @@ import com.github.tomakehurst.wiremock.junit5.WireMockTest; import jakarta.servlet.http.Cookie; /** - * Integration tests for {@code POST /api/search}, verifying the session-gated - * contract and request validation against a mocked Homebox backend (via WireMock) - * and a real Spring MVC dispatch chain (via {@link MockMvc}). + * Integration tests for {@code POST /api/search}, verifying the session-gated contract and request + * validation against a mocked Homebox backend (via WireMock) and a real Spring MVC dispatch chain + * (via {@link MockMvc}). */ @SpringBootTest @AutoConfigureMockMvc @@ -45,12 +45,12 @@ class SearchControllerTest { private static final String SEARCH_REQUEST = SEARCH.getValue(); /** - * Logs in against a stubbed Homebox instance, then performs a keyword search using - * the resulting session cookie. Expects {@code 200 OK} with the mocked item mapped - * into the paged response body. + * Logs in against a stubbed Homebox instance, then performs a keyword search using the + * resulting session cookie. Expects {@code 200 OK} with the mocked item mapped into the paged + * response body. * - * @param wm WireMock runtime info, injected by {@link WireMockTest}, used to point - * the client at the stub server + * @param wm WireMock runtime info, injected by {@link WireMockTest}, used to point the client + * at the stub server */ @Test void shouldReturnListOfQueriedHomeboxItems(WireMockRuntimeInfo wm) throws Exception {