nspcc-dev / nspcc-dev/neofs-node

Unify status usage in storage engine when object is missing

Open
#2,956 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement good first issue I4 S3 U4
Dominant language
Go
Stars
38
Forks
51
Avg merge
1d 20h
Merged PRs (30d)
38

Description

Is your feature request related to a problem? Please describe.

I'm always frustrated when we have both bool flags that mean the presence of an object in the engine and ErrObjectNotFound. Sometimes it is a flag and sometimes it is an error.

Describe the solution you'd like

It should either be error, or be a flag.

Describe alternatives you've considered

-

Additional context

Sometimes it is ok to have an error and sometimes we only accept a flag, it is unreliable.
As for me, I wouldn't say I like using client statuses (that is where they are placed in SDK) in engines at all.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by comparing the missing-object handling in pkg/local_object_storage/blobstor/fstree/fstree.go around line 338 with pkg/local_object_storage/shard/get.go around lines 116-120. Trace their callers to determine whether the engine should use an error or a flag consistently. Done means the chosen representation is applied across the affected storage-engine paths without mixed status handling.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
backend, distributed-systems
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.