-
Couldn't load subscription status.
- Fork 239
Added few test cases #1830
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
base: feature/dcache
Are you sure you want to change the base?
Added few test cases #1830
Conversation
| Readonly: true, | ||
| State: dcache.StateReady, | ||
| Epoch: 1, | ||
| Epoch: 0, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do you change this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is needed to start with version 1.
Right now, we don't use version 1
| RVMap map[string]RawVolume `json:"rv-list"` | ||
| MVMap map[string]MirroredVolume `json:"mv-list"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and this?
it's a map and not a list, so let it be called map
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made it consistent throughout.
fs=debug consider it as rv-list mv-list, which makes the things inconsistent. While reading data in automation script.
| # Check if number of nodes is provided | ||
| if [ $# -ne 1 ]; then | ||
| echo "Usage: $0 <number_of_nodes>" | ||
| echo "Example: $0 5" | ||
| exit 1 | ||
| fi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we need to take number of nodes from user?
why can't we deduce it from clustermap.
I'd not want to take any additional info from the user. He should be able to point the test script at a cluster and it should be able to test it by gathering the reqd infro from the clustermap.
| local next_epoch=$(expr $LAST_UPDATED_AT + $CLUSTERMAP_EPOCH) | ||
| local now=$(date +%s) | ||
| local secs_to_next_epoch=$(expr $next_epoch - $now + 2) | ||
| local secs_to_next_epoch=$(expr $next_epoch - $now + 5) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why did you have to change this?
did it fail and if so did you analyze why 2 sec buffer was not sufficient.
| # Check if we're close to the heartbeat timeout boundary | ||
| local heartbeat_timeout=$(expr $HB_SECONDS \* $HB_TILL_NODE_DOWN - 2) | ||
| local secs_to_next_epoch_with_buffer | ||
|
|
||
| if [ $secs_to_next_epoch -lt $heartbeat_timeout ]; then | ||
| # Add an additional epoch period if we're close to timeout | ||
| secs_to_next_epoch_with_buffer=$(expr $secs_to_next_epoch + $CLUSTERMAP_EPOCH + 5) | ||
| echo "Close to heartbeat timeout boundary, adding extra epoch wait time" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
general comment.
pl;s indent uniformly across the file, use 4 spaces
| local file_name=$2 | ||
| local block_size=$3 | ||
| local count=$4 | ||
| ssh $vm "dd if=/dev/urandom of=$MOUNTDIR/fs=dcache/$file_name bs=$block_size count=$count" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
add conv=fsync to be safe
to all dds
| local block_size=$3 | ||
| local count=$4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just take size_in_GB as param and deduce these two internally
| ssh $vm "dd if=/dev/urandom of=$MOUNTDIR/fs=azure/$file_name bs=$block_size count=$count" | ||
| } | ||
|
|
||
| write_data_in_mountdir() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
call it write_data_on_both()
, since that's what is the intent..
for others too use on in place of in
9d56910 to
43a8bfc
Compare
No description provided.