Skip to content

Conversation

@NathanFlurry
Copy link
Member

No description provided.

@vercel
Copy link

vercel bot commented Oct 17, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

3 Skipped Deployments
Project Deployment Preview Comments Updated (UTC)
rivet-cloud Ignored Ignored Oct 18, 2025 7:13am
rivet-inspector Ignored Ignored Preview Oct 18, 2025 7:13am
rivet-site Ignored Ignored Preview Oct 18, 2025 7:13am

💡 Enable Vercel Agent with $100 free credit for automated AI reviews

Copy link
Member Author

NathanFlurry commented Oct 17, 2025


How to use the Graphite Merge Queue

Add the label merge-queue to this PR to add it to the merge queue.

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@claude
Copy link

claude bot commented Oct 17, 2025

Claude encountered an error —— View job


I'll analyze this and get back to you.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Oct 17, 2025

Open in StackBlitz

npm i https://pkg.pr.new/rivet-dev/engine/@rivetkit/engine-runner@3220
npm i https://pkg.pr.new/rivet-dev/engine/@rivetkit/engine-runner-protocol@3220

commit: c504886

@NathanFlurry NathanFlurry changed the base branch from 10-17-fix_cloud_update_vercel_1-click_link to graphite-base/3220 October 18, 2025 07:13
@NathanFlurry NathanFlurry force-pushed the feat_engine_add_RocksDB_engine_run_script branch from 3723de7 to c504886 Compare October 18, 2025 07:13
@NathanFlurry NathanFlurry changed the base branch from graphite-base/3220 to main October 18, 2025 07:13
@NathanFlurry NathanFlurry merged commit 1d59170 into main Oct 18, 2025
11 of 18 checks passed
@NathanFlurry NathanFlurry deleted the feat_engine_add_RocksDB_engine_run_script branch October 18, 2025 07:14
@claude
Copy link

claude bot commented Oct 18, 2025

Pull Request Review

Summary

This PR adds a new run script for the engine using RocksDB (FileSystem database backend). The script follows the basic pattern of existing run scripts but has some issues that should be addressed.

Issues Found

1. Missing Database Configuration

Severity: High

The script doesn't explicitly configure the database backend. While RocksDB is the default (via FileSystem), this should be made explicit for clarity and to prevent confusion if defaults change.

Recommendation: Add explicit configuration similar to how engine-postgres.sh sets RIVET__POSTGRES__URL, or add a comment explaining the default behavior.

2. Inconsistent Naming Convention

Severity: Low

The script is named engine-rocksdb.sh but the actual database backend in the config is called FileSystem. While RocksDB is the underlying technology, the config enum is Database::FileSystem.

Recommendation: Consider renaming to engine-filesystem.sh for consistency with the config, or add a comment explaining the naming.

3. No Validation or Prerequisites Check

Severity: Medium

Unlike engine-postgres.sh which checks if Postgres is reachable and provides helpful error messages, this script has no validation.

Recommendation: Consider adding basic validation to ensure the data directory can be created.

Positive Aspects

  1. Correct bash best practices: Uses set -euo pipefail for error handling
  2. Proper shebang: Uses #!/usr/bin/env bash for portability
  3. Correct path handling: Uses proper directory resolution with SCRIPT_DIR and REPO_ROOT
  4. Argument forwarding: Correctly passes through arguments
  5. Debug logging: Includes RUST_LOG=debug for development use

Recommendation

Request Changes - The missing database configuration should be addressed to make the script's behavior explicit and prevent future confusion.

@claude
Copy link

claude bot commented Oct 18, 2025

Code Review

I've reviewed this PR and have the following feedback:

Summary

This PR adds a new script scripts/run/engine-rocksdb.sh to run the Rivet engine with RocksDB as the database backend.

Critical Issue: Missing Environment Configuration

The script doesn't configure the database backend at all. Looking at the codebase, the engine uses rivet_config::Config which defaults to Database::FileSystem (which uses RocksDB internally). The script name suggests it's specifically for RocksDB, but it doesn't actually configure anything database-specific.

Since the default is already FileSystem/RocksDB, the script works, but it's confusing because it relies on implicit defaults rather than explicit configuration.

Recommendation: Either rename to engine.sh or engine-local.sh, or add a comment explaining that RocksDB is the default.

Medium Issue: Missing Health Checks

Unlike engine-postgres.sh which includes checks for nc command availability, verifies Postgres is reachable, and provides helpful error messages, this script has no validation for the data directory writability or disk space.

Recommendation: Add basic validation for data directory creation and writability.

Minor Issue: Naming Consistency

The config uses Database::FileSystem (not Database::RocksDB) - RocksDB is an implementation detail. Consider renaming to engine-filesystem.sh or engine-local.sh to match the config enum naming (see packages/common/config/src/config/db.rs:10-13).

Positive Aspects

  • Follows existing script patterns (set -euo pipefail, directory resolution)
  • Properly changes to repo root before running
  • Sets RUST_LOG=debug for development debugging
  • Passes through additional arguments
  • Script is executable with correct permissions

Recommendation

At minimum, add a comment explaining that this uses the default FileSystem/RocksDB backend. Ideally, add validation checks similar to the Postgres script and consider renaming for clarity.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants