sanity-hsm/test_[200-202] sometimes fail because the Cancel
reaches the CDT before the operation it targets.
This patch verifies the operation has already been registered
at CDT before to send the Cancel.
Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: Ic6299a2fdb6b6a358a0ce6ecd5a17a8cf9839c87
Reviewed-on: http://review.whamcloud.com/13173
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
# test with cdt on is made in test_221
cdt_disable
$LFS hsm_archive --archive $HSM_ARCHIVE_NUMBER $f
+ # wait archive to register at CDT
+ wait_request_state $fid ARCHIVE WAITING
$LFS hsm_cancel $f
cdt_enable
wait_request_state $fid ARCHIVE CANCELED
# test with cdt on is made in test_222
cdt_disable
$LFS hsm_restore $f
+ # wait restore to register at CDT
+ wait_request_state $fid RESTORE WAITING
$LFS hsm_cancel $f
cdt_enable
wait_request_state $fid RESTORE CANCELED
cdt_disable
$LFS hsm_remove $f
+ # wait remove to register at CDT
+ wait_request_state $fid REMOVE WAITING
$LFS hsm_cancel $f
cdt_enable
wait_request_state $fid REMOVE CANCELED