Skip to content

Commit

Permalink
CI: fix load test (#4832)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhoucheng361 authored May 10, 2024
1 parent bbeccd2 commit 84a139a
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .github/scripts/hypo/fs.py
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ def set_acl(self, sudo_user, entry, user, user_perm, group, group_perm, other_pe
modify_time=st_time,
follow_symlinks=st.booleans(),
user = st.sampled_from(USERS))
@precondition(lambda self: self.should_run('utime'))
@precondition(lambda self: self.should_run('utime') and False)
def utime(self, entry, access_time, modify_time, follow_symlinks, user='root'):
result1 = self.fsop1.do_utime(entry, access_time, modify_time, follow_symlinks, user)
result2 = self.fsop2.do_utime(entry, access_time, modify_time, follow_symlinks, user)
Expand Down
7 changes: 6 additions & 1 deletion .github/scripts/hypo/s3_op.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,12 @@ def handleException(self, e, action, **kwargs):
return Exception(f'code:{e.code} message:{e.message}')
elif isinstance(e, subprocess.CalledProcessError):
self.logger.info(f'{action} {kwargs} failed: {e.output.decode()}')
return Exception(f'returncode:{e.returncode} output:{e.output.decode()}')
try:
output = json.loads(e.output.decode())
message = output.get('error', {}).get('message', 'error message not found')
return Exception(f'returncode:{e.returncode} {message}')
except ValueError as ve:
return Exception(f'returncode:{e.returncode} output:{e.output.decode()}')
else:
self.logger.info(f'{action} {kwargs} failed: {e}')
return e
Expand Down
4 changes: 2 additions & 2 deletions .github/scripts/sync/sync_fsrand.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ test_list_threads(){
check_diff $DEST_DIR1 $DEST_DIR2
}

skip_test_update(){
test_update(){
prepare_test
./juicefs mount $META_URL /tmp/jfs -d
sync_option="--dirs --perms --check-all --links --list-threads 10 --list-depth 5"
Expand All @@ -111,7 +111,7 @@ skip_test_update(){
break
fi
done
check_diff $DEST_DIR1 $DEST_DIR2
diff -ur --no-dereference $DEST_DIR1 $DEST_DIR2
}

do_copy(){
Expand Down
9 changes: 2 additions & 7 deletions .github/workflows/load.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
if [ "${{github.event_name}}" == "schedule" ] || [ "${{github.event_name}}" == "workflow_dispatch" ]; then
echo 'meta_matrix=["sqlite3", "redis", "mysql", "tikv", "tidb", "postgres", "mariadb", "fdb"]' >> $GITHUB_OUTPUT
else
echo 'meta_matrix=["redis", "mysql"]' >> $GITHUB_OUTPUT
echo 'meta_matrix=["redis", "mysql", "tikv"]' >> $GITHUB_OUTPUT
# echo 'meta_matrix=["redis"]' >> $GITHUB_OUTPUT
fi
outputs:
Expand Down Expand Up @@ -86,13 +86,8 @@ jobs:

- name: Load and dump with small directory
timeout-minutes: 30
env:
AWS_ACCESS_KEY_ID: ${{secrets.CI_AWS_ACCESS_KEY_ID}}
AWS_SECRET_ACCESS_KEY: ${{secrets.CI_AWS_ACCESS_KEY_SECRET}}
META: ${{matrix.meta}}
START_META: true
run: |
sudo -E .github/scripts/command/load_dump_bench.sh test_load_dump_with_small_dir
sudo AWS_ACCESS_KEY_ID=${{secrets.CI_AWS_ACCESS_KEY_ID}} AWS_SECRET_ACCESS_KEY=${{secrets.CI_AWS_ACCESS_KEY_SECRET}} META=${{matrix.meta}} START_META=true .github/scripts/command/load_dump_bench.sh test_load_dump_with_small_dir
- name: Load and dump with big directory
timeout-minutes: 30
Expand Down

0 comments on commit 84a139a

Please sign in to comment.