diff options
author | Dan Smith <dansmith@redhat.com> | 2019-05-23 06:37:03 -0700 |
---|---|---|
committer | Dan Smith <dansmith@redhat.com> | 2019-06-05 07:42:23 -0700 |
commit | 0685139ed8e73c7fb050b22dd86b136044207516 (patch) | |
tree | 291a921e09fe9e7d89d2cf6c57a59783d62ca535 /gate | |
parent | e822360b6696c492bb583240483ee9593d7d24e1 (diff) | |
download | nova-0685139ed8e73c7fb050b22dd86b136044207516.tar.gz |
Make nova-next archive using --before
Change-Id: I4fbd0cb73c73ab680af3f341d6069addb57393fb
Diffstat (limited to 'gate')
-rwxr-xr-x | gate/post_test_hook.sh | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gate/post_test_hook.sh b/gate/post_test_hook.sh index b27274b049..385d83d4f9 100755 --- a/gate/post_test_hook.sh +++ b/gate/post_test_hook.sh @@ -5,8 +5,12 @@ MANAGE="/usr/local/bin/nova-manage" function archive_deleted_rows { # NOTE(danms): Run this a few times to make sure that we end # up with nothing more to archive + if ! $MANAGE $* db archive_deleted_rows --verbose --before "$(date -d yesterday)" 2>&1 | grep 'Nothing was archived'; then + echo "Archiving yesterday data should have done nothing" + return 1 + fi for i in `seq 30`; do - $MANAGE $* db archive_deleted_rows --verbose --max_rows 1000 + $MANAGE $* db archive_deleted_rows --verbose --max_rows 1000 --before "$(date -d tomorrow)" RET=$? if [[ $RET -gt 1 ]]; then echo Archiving failed with result $RET |