rancher / convoy

A Docker volume plugin, managing persistent container volumes.
Apache License 2.0
1.31k stars 135 forks source link

extraneous aws api calls using ebs #155

Open kapilt opened 8 years ago

kapilt commented 8 years ago

the driver abstraction seems to cause quite a few extraneous api calls per ebs volume

for example convoy list, generates three api calls per volume, one for the list, one get volume, and one for get volume info, all of which result in round trips to aws api endpoints. this seems quite extraneous, note the output below was per additional logging added to daemon and the ebs driver.

DEBU[0020] list volumes found crypto-disk-6              pkg=ebs
DEBU[0025] Volume crypto-disk-6 Kms Key Id arn:aws:kms:us-east-1:619193117841:key/1c052186-6435-4a64-a4a0-bf3d395059b3  pkg=ebs
DEBU[0025] get volume crypto-disk-6                      pkg=daemon
DEBU[0030] Volume crypto-disk-6 Kms Key Id arn:aws:kms:us-east-1:619193117841:key/1c052186-6435-4a64-a4a0-bf3d395059b3  pkg=ebs
DEBU[0030] get volume info crypto-disk-6                 pkg=daemon
DEBU[0035] Volume crypto-disk-6 Kms Key Id arn:aws:kms:us-east-1:619193117841:key/1c052186-6435-4a64-a4a0-bf3d395059b3  pkg=ebs

ie. when i had 4 volumes, i had 12 api calls, a single api call returns the information for all volumes attached to the instance.