Skip to content

Conversation

@philjb
Copy link
Contributor

@philjb philjb commented Dec 19, 2025

@hiltontj said he used rsync in his pr to bring in iox code to _core so i did the same.

this pr is the result of rsync with the below script followed by fixing two clippy lints in the result and then works around:

AI wrote a script for me:

script

#!/bin/bash
# Sync crates from iox to core
# Only syncs crates that already exist in core

set -e

IOX_DIR="/Volumes/wk/influxdb_iox"
CORE_DIR="/Volumes/wk/influxdb3_core"

# Directories to skip (not crates to sync)
SKIP_DIRS=".git .cargo .circleci .config .idea target test_fixtures workspace-hack"

# Use -n flag for dry run, remove it for actual sync
DRY_RUN="${1:--n}"

if [ "$DRY_RUN" = "-n" ]; then
    echo "=== DRY RUN MODE (no changes will be made) ==="
    echo "Run with '--apply' to actually sync files"
    echo ""
elif [ "$DRY_RUN" = "--apply" ]; then
    DRY_RUN=""
    echo "=== APPLYING CHANGES ==="
    echo ""
else
    echo "Usage: $0 [-n|--apply]"
    echo "  -n       Dry run (default)"
    echo "  --apply  Actually sync files"
    exit 1
fi

for dir in "$CORE_DIR"/*/; do
    crate=$(basename "$dir")

    # Skip non-crate directories
    if echo "$SKIP_DIRS" | grep -qw "$crate"; then
        continue
    fi

    # Check if this crate exists in iox
    if [ -d "$IOX_DIR/$crate" ]; then
        echo "Syncing: $crate"
        rsync -av $DRY_RUN --delete "$IOX_DIR/$crate/" "$CORE_DIR/$crate/"
    else
        echo "Skipping (not in iox): $crate"
    fi
done

echo ""
echo "Done."

@philjb philjb force-pushed the pjb/update-core-with-iox branch from 1833fbd to fe89903 Compare December 19, 2025 00:17
@philjb philjb requested review from hiltontj and praveen-influx and removed request for hiltontj December 19, 2025 00:27
Copy link
Contributor

@praveen-influx praveen-influx left a comment

Choose a reason for hiding this comment

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

Looks good - had a quick look to see if there's been any internal libs brought in, none that I could spot.

FWIW there's a script here https://github.com/influxdata/influxdb3_core_internal/blob/main/sync-core.sh but that repo isn't maintained, so I'll go with your AI generated one

@philjb
Copy link
Contributor Author

philjb commented Dec 19, 2025

Thanks @praveen-influx -- i didn't know about that script.

I also noticed that there were ~16 crates in this repo that were not part of the rust project. I added them in this pr too. I'm not sure of the history of that, but it means the core and 3ent aren't depending on those crates as cargo can't find crates not in a project file (cargo.toml) with a remote git dep reference.

@philjb philjb merged commit 0b2321f into main Dec 19, 2025
5 checks passed
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.

3 participants