influxdata/influxdb · error · RepositoryError
with id not found
Error message
{resource} with id {id} not found What it means
RepositoryError::NotFound, returned by catalog Repository lookups when no entity with the given id exists; `resource` is the category label and `id` the missing key, making the message self-identifying without caller context.
Solutions
- Verify the id was obtained from this catalog and not from a stale snapshot
- List resources to confirm the entity exists before fetching by id
- Surface a not-found response to the caller rather than retrying blindly
Defensive patterns
Strategy: type-guard
When it happens
Trigger: Thrown at influxdb3_catalog/src/repository.rs:32 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of influxdata/influxdb@06200ef96b (2026-09-19).
Data as JSON: /api/errors/fe7daa3cd6c7e76d.
Report an issue: GitHub.
Appendix: source
Thrown at influxdb3_catalog/src/repository.rs:32
use crate::resource::CatalogResource;
/// Error returned by [`Repository`] operations.
///
/// Carries the resource label (from [`CatalogResource::CATEGORY`]) and the
/// offending `id` so the error message is self-identifying without requiring
/// callers to add context.
#[derive(thiserror::Error)]
pub enum RepositoryError<I: CatalogId> {
#[error("{resource} with id {id} already exists")]
AlreadyExists { resource: &'static str, id: I },
#[error("{resource} with name '{name}' already exists")]
AlreadyExistsByName {
resource: &'static str,
name: String,
},
#[error("{resource} with id {id} not found")]
NotFound { resource: &'static str, id: I },
#[error("{resource} with name '{name}' not found")]
NotFoundByName {
resource: &'static str,
name: String,
},
}
// Manual `Debug` impl so the enum does not impose a `Debug` bound on `I` ---
// every concrete [`CatalogId`] in this crate derives `Debug`, but the trait
// itself does not require it.
impl<I: CatalogId> std::fmt::Debug for RepositoryError<I> {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
Self::AlreadyExists { resource, id } => f
.debug_struct("AlreadyExists")
.field("resource", resource)View on GitHub (pinned to 06200ef96b)