hashicorp/nomad · error
job_summary lookup failed: %v
Error message
job_summary lookup failed: %v
What it means
JobSummaryByPrefix reads job_summary rows matching an ID prefix via the id_prefix index. This error wraps a failed txn.Get on the job_summary table — the query itself failed, rather than simply matching nothing.
Source
Thrown at nomad/state/state_store.go:2639
txn := s.db.ReadTxn()
iter, err := txn.Get("job_summary", "id")
if err != nil {
return nil, err
}
ws.Add(iter.WatchCh())
return iter, nil
}
// JobSummaryByPrefix is used to look up Job Summary by id prefix
func (s *StateStore) JobSummaryByPrefix(ws memdb.WatchSet, namespace, id string) (memdb.ResultIterator, error) {
txn := s.db.ReadTxn()
iter, err := txn.Get("job_summary", "id_prefix", namespace, id)
if err != nil {
return nil, fmt.Errorf("job_summary lookup failed: %v", err)
}
ws.Add(iter.WatchCh())
return iter, nil
}
// UpsertCSIVolume inserts a volume in the state store.
func (s *StateStore) UpsertCSIVolume(index uint64, volumes []*structs.CSIVolume) error {
txn := s.db.WriteTxnMsgT(structs.CSIVolumeRegisterRequestType, index)
defer txn.Abort()
for _, v := range volumes {
if exists, err := s.namespaceExists(txn, v.Namespace); err != nil {
return err
} else if !exists {
return fmt.Errorf("volume %s is in nonexistent namespace %s", v.ID, v.Namespace)
}View on GitHub (pinned to 482b49bf1a)
Solutions
- Read the wrapped %v cause
- Retry the query
- If persistent, verify server state store health and report upstream
Defensive patterns
Strategy: try-catch
Type guard
func isSummaryLookupErr(err error) bool {
return err != nil && strings.Contains(err.Error(), "job_summary lookup failed")
} Try / catch
sums, _, err := client.Jobs().PrefixList(prefix) // summary path via API
if err != nil && isSummaryLookupErr(err) {
return retryWithBackoff()
} Prevention
- Retry transient state store errors
- Monitor server health
- Handle empty prefix results explicitly
When it happens
Trigger: Calling JobSummaryByPrefix (job summary list with prefix) when the memdb Get on 'job_summary'/'id_prefix' errors.
Common situations: Rare; internal index errors during job summary prefix queries via the Nomad API/CLI.
Related errors
- error getting job summary: %v
- unable to create job summary: %v
- job summary lookup failed: %v
- error inserting job summary: %v
- job summary update failed %w
AI-assisted analysis of hashicorp/nomad@482b49bf1a (2026-09-04).
Data as JSON: /api/errors/a2d4b810147419c8.
Report an issue: GitHub.