Skip to content

Enhance tracing and refactor blob-related keyspaces#238

Open
das-Abroxas wants to merge 24 commits into
mainfrom
refactor/blob-keyspaces
Open

Enhance tracing and refactor blob-related keyspaces#238
das-Abroxas wants to merge 24 commits into
mainfrom
refactor/blob-keyspaces

Conversation

@das-Abroxas
Copy link
Copy Markdown
Contributor

This PR combines two main lines of work:

  1. Tracing and observability improvements across the API, operations, storage, and networking layers
  2. A refactor of blob and S3 object state into dedicated blob-related keyspaces

Tracing And Observability

This part of the branch improves end-to-end visibility and debugging across the system.

  • adds richer request spans and trace ID recording in the HTTP and S3 layers
  • propagates distributed trace context through gossip messages and inbound operation handling
  • instruments storage dispatch/worker loops, operation execution, DHT handling, QUIC streams, and connection management
  • improves timeout and error logging around storage, gossip, replication, and networking paths
  • cleans up older tracing stubs and aligns telemetry helpers across crates

Blob Keyspace Refactor

This part of the branch changes how blob and object state is modeled and stored.

  • introduces dedicated blob keyspaces such as BLOB_LOCATIONS_KEYSPACE, BLOB_HEAD_KEYSPACE, BLOB_VERSIONS_KEYSPACE, and HASH_PATHS_INDEX_KEYSPACE
  • adds new shared blob primitives and helpers including BlobHeadKey, BlobVersion, HashPathIndexKey, and head-transition utilities
  • moves S3 object state management away from the previous S3-specific keyspaces and updates PUT, GET, HEAD, DELETE, multipart, and replication flows accordingly
  • centralizes blob permission-path construction and alias/index updates
  • persists reference-backed objects as blob versions and supports on-demand replication for them
  • extends aruna-doctor to inspect and debug the new blob-related keyspaces

Supporting Changes

A few additional changes support the two themes above.

  • reworks parts of the network stack around reusable QUIC connections, stream handling, and DHT/runtime plumbing
  • updates tests and supporting helpers in multipart, replication, and blob flows to match the new storage model and tracing behavior

@das-Abroxas das-Abroxas self-assigned this May 22, 2026
@das-Abroxas das-Abroxas added enhancement New feature or request fix Bug issue fix labels May 22, 2026
Copy link
Copy Markdown
Member

@St4NNi St4NNi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few minor comments, otherwise this looks ok for me.

"blake3",
));
};
let effect = match write_blob_location_effect(
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this an issue if the hash already exists ? It just overwrites the metadata without taking existing metadata into account.

group_id: Ulid,
requested_restrictions: Option<Vec<CreateS3PathRestriction>>,
) -> ServerResult<Option<Vec<PathRestriction>>> {
let Some(requested_restrictions) = requested_restrictions else {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could be a problem because it drops the restrictions from the auth-context and thus may allow for a broader scope than original granted.

key_space: BLOB_VERSIONS_KEYSPACE.to_string(),
prefix: Some(prefix),
start_after: None,
limit: 10_000,
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated to this PR but when reading through this: What if an object has more than 10000 versions -> This will not work!

}

self.state = DeleteBucketState::CheckMultipartUploads;
smallvec![Effect::Storage(StorageEffect::Iter {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has the same issue as before, it only scan suntil SCAN_LIMIT but what if there is an active multipart beyond the scan_limit ?

}

fn defined_keyspaces() -> [&'static str; 18] {
fn defined_keyspaces() -> [&'static str; 19] {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No explores for multipart keyspaces ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request fix Bug issue fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants