Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding car generation to warehouse scripts #18

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions warehouse-upload-to-storage-bucket.sh
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,28 @@ while true; do
fi
fi

if [[ -n $OLD_FAITHFUL ]]; then
EPOCH=`cat $archive_dir/epoch | tr -d '\n'`
if [[ ! -f "$archive_dir"/.old-faithful ]]; then
if ! timeout 2h radiance car create2 "$EPOCH" --db=$rocksdb --out="$archive_dir/epoch-$EPOCH.car" --check; then
echo "This epoch does not have access to a full set of slots from the epoch."
datapoint_error old-faithful-generation-slots-missing
else
echo "Generating epoch-$EPOCH.car from $archive_dir"
SECONDS=
while ! timeout 48h radiance car create2 $EPOCH --db=$rocksdb --out="$archive_dir/epoch-$EPOCH.car"; do
echo "old faithful generation failed..."
datapoint_error old-faithful-generation-failure
sleep 30
done
touch "$archive_dir"/.old-faithful

echo Car generation took $SECONDS seconds
datapoint old-faithful-generation-complete "duration_secs=$SECONDS"
fi
fi
fi

echo "Creating rocksdb.tar.bz2 in $archive_dir"
rm -rf rocksdb.tar.bz2
tar jcf rocksdb.tar.bz2 rocksdb
Expand Down