refactor: extract serde helpers from stored_object! macro

Move FlexibleIdVisitor, deserialize_flexible_id, and four datetime serde helpers
from repeating inside every macro expansion into a shared
common/src/storage/types/serde_helpers.rs module.

14 macro invocations × 6 items = ~84 fewer redundant function definitions.
Fragile cross-module imports (file_info::deserialize_flexible_id etc.)
are updated to point to the canonical module.
This commit is contained in:
Per Stark
2026-05-25 13:38:28 +02:00
parent f22a1e5ba4
commit 79e46e9c09
7 changed files with 94 additions and 92 deletions
+2 -1
View File
@@ -9,7 +9,8 @@ use axum::{
response::IntoResponse,
};
use common::storage::types::{
text_content::{deserialize_flexible_id, TextContent},
serde_helpers::deserialize_flexible_id,
text_content::TextContent,
StoredObject,
};
use retrieval_pipeline::{RetrievalConfig, SearchResult, SearchTarget, StrategyOutput};