Skip to content

Extract cloud object persistence logic to other crates.#11179

Merged
vorporeal merged 5 commits into
masterfrom
david/extract-cloud-object-persistence
Jun 1, 2026
Merged

Extract cloud object persistence logic to other crates.#11179
vorporeal merged 5 commits into
masterfrom
david/extract-cloud-object-persistence

Conversation

@vorporeal
Copy link
Copy Markdown
Contributor

@vorporeal vorporeal commented May 18, 2026

Description

Pulls cloud-object SQLite persistence out of the warp app crate so Diesel-heavy persistence code can live in smaller, purpose-specific crates while preserving a path toward future model verticalization.

  • Adds cloud_object_persistence for shared cloud-object persistence infrastructure, including metadata/permissions helpers, refresh scheduling, guest/link-sharing encoding, callback-based upsert/delete primitives, and generic string object table access.
  • Moves notebook, workflow, folder, and generic-string model persistence adapters under their corresponding cloud_object_models modules so model-specific persistence can move with those models later.
  • Removes warp_server_client::persistence as a compatibility home and updates imports to use cloud_object_persistence directly.
  • Keeps app/src/persistence/sqlite.rs focused on app persistence orchestration and app-local object action conversion.
  • Adds crate-level docs for the cloud-object crates to document their intended scopes and dependency boundaries.

Testing

  • cargo fmt --manifest-path /Users/david/src/warp/Cargo.toml --all
  • cargo check --manifest-path /Users/david/src/warp/Cargo.toml -p cloud_object_persistence
  • cargo check --manifest-path /Users/david/src/warp/Cargo.toml -p cloud_object_models --tests
  • cargo check --manifest-path /Users/david/src/warp/Cargo.toml -p warp --tests
  • cargo nextest run --manifest-path /Users/david/src/warp/Cargo.toml -p cloud_object_persistence
  • cargo check --manifest-path /Users/david/src/warp/Cargo.toml -p cloud_objects -p cloud_object_models -p cloud_object_persistence
  • cargo check -p warp

Not manually tested; this is an internal persistence refactor with no expected user-visible behavior changes.

Agent Mode

  • Warp Agent Mode - This PR was created via Warp's AI Agent Mode

CHANGELOG-NONE

Co-Authored-By: Oz oz-agent@warp.dev

@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from 331d1ff to 2d10540 Compare May 18, 2026 14:52
@vorporeal vorporeal force-pushed the david/extract-cloud-object-client branch from 4a71dee to 06b3f2e Compare May 18, 2026 14:53
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch 2 times, most recently from d39d8e7 to e22e7af Compare May 19, 2026 18:43
@vorporeal vorporeal force-pushed the david/extract-cloud-object-client branch from a241a1f to 705fc1d Compare May 19, 2026 18:43
@vorporeal vorporeal requested a review from bnavetta May 20, 2026 15:30
@vorporeal vorporeal marked this pull request as ready for review May 20, 2026 15:30
@oz-for-oss
Copy link
Copy Markdown
Contributor

oz-for-oss Bot commented May 20, 2026

@vorporeal

I'm starting a first review of this pull request.

You can view the conversation on Warp.

I completed the review and no human review was requested for this pull request.

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Copy link
Copy Markdown
Contributor

@oz-for-oss oz-for-oss Bot left a comment

Choose a reason for hiding this comment

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

Overview

This PR extracts cloud-object SQLite persistence into a new cloud_object_persistence crate and moves model-specific persistence adapters into cloud_object_models, while updating the app and server-client crates to use the new boundaries.

Concerns

  • No blocking correctness, security, or spec-alignment concerns found in the reviewed diff.
  • No approved spec context was available for comparison.

Verdict

Found: 0 critical, 0 important, 0 suggestions

Approve

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from e22e7af to dd218ee Compare May 20, 2026 15:56
@vorporeal vorporeal force-pushed the david/extract-cloud-object-client branch from b9503ba to 7744b13 Compare May 21, 2026 14:59
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from dd218ee to b82656e Compare May 21, 2026 14:59
@vorporeal vorporeal force-pushed the david/extract-cloud-object-client branch from 7744b13 to 9185c98 Compare May 21, 2026 16:47
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from b82656e to 01cd413 Compare May 21, 2026 16:47
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from 01cd413 to 2ac0201 Compare May 22, 2026 18:51
@vorporeal vorporeal force-pushed the david/extract-cloud-object-client branch 2 times, most recently from e7f14b5 to 8141bbe Compare May 22, 2026 18:53
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from 2ac0201 to 4898933 Compare May 22, 2026 18:53
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from 4898933 to cdc014b Compare May 27, 2026 02:23
@vorporeal vorporeal force-pushed the david/extract-cloud-object-client branch from 8141bbe to 26a2943 Compare May 27, 2026 02:23
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from cdc014b to 28337ed Compare May 27, 2026 19:46
@vorporeal vorporeal force-pushed the david/extract-cloud-object-client branch from 26a2943 to 35a57fd Compare May 27, 2026 19:46
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from 28337ed to c0068a0 Compare May 28, 2026 18:12
@vorporeal vorporeal force-pushed the david/extract-cloud-object-client branch from 35a57fd to 2a5ea8f Compare May 28, 2026 18:12
@vorporeal vorporeal changed the base branch from david/extract-cloud-object-client to graphite-base/11179 May 28, 2026 18:59
@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from c0068a0 to 3a39635 Compare May 29, 2026 17:57
@vorporeal vorporeal force-pushed the graphite-base/11179 branch from 2a5ea8f to a6d9b93 Compare May 29, 2026 17:57
@vorporeal vorporeal changed the base branch from graphite-base/11179 to master May 29, 2026 17:57
@vorporeal vorporeal closed this May 29, 2026
@vorporeal vorporeal reopened this May 29, 2026
@oz-for-oss
Copy link
Copy Markdown
Contributor

oz-for-oss Bot commented May 29, 2026

@vorporeal

I'm starting a first review of this pull request.

You can view the conversation on Warp.

I completed the review and no human review was requested for this pull request.

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Copy link
Copy Markdown
Contributor

@oz-for-oss oz-for-oss Bot left a comment

Choose a reason for hiding this comment

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

Overview

This PR extracts shared cloud-object SQLite persistence into cloud_object_persistence and moves model-specific persistence adapters into cloud_object_models, with no approved spec context to compare against. I did not find correctness, spec-alignment, or security issues in the changed diff.

Concerns

  • Non-blocking cleanup: removing the app/src/persistence/cloud_objects module appears to leave the old source/test files orphaned in the app crate; consider deleting them or fully moving the remaining coverage alongside the extracted helpers.

Verdict

Found: 0 critical, 0 important, 1 suggestions

Approve with nits

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

if #[cfg(feature = "local_fs")] {
pub mod agent;
mod block_list;
mod cloud_objects;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

💡 [SUGGESTION] Removing this module appears to leave app/src/persistence/cloud_objects.rs and cloud_object_tests.rs orphaned; delete them or move their remaining coverage with the extracted helpers.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

+1, see that cloud_objects.rs is removed but I think the tests are still here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

ah, yeah, fixed this but forgot to push the commit, oops

if #[cfg(feature = "local_fs")] {
pub mod agent;
mod block_list;
mod cloud_objects;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

+1, see that cloud_objects.rs is removed but I think the tests are still here?

}

#[cfg(test)]
mod tests {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nit: these should go in a separate tests file

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

good catch; done. will get an agent to find and fix these across the codebase, then add a CI check to prevent new ones.

@vorporeal vorporeal force-pushed the david/extract-cloud-object-persistence branch from 0cdd16a to 3f92c61 Compare June 1, 2026 16:17
@vorporeal vorporeal enabled auto-merge (squash) June 1, 2026 16:28
@vorporeal vorporeal merged commit feff471 into master Jun 1, 2026
26 checks passed
@vorporeal vorporeal deleted the david/extract-cloud-object-persistence branch June 1, 2026 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants