fog / fog-google

Fog for Google Cloud Platform
MIT License
99 stars 146 forks source link

Fog::Compute::Google::Disks#get when rescuing Google::Apis::ClientError #612

Closed rchekaluk closed 7 months ago

rchekaluk commented 8 months ago

Detaching an attached disk does not invoke fog-core Fog::Model#wait_for block when Google API raises Google::Apis::ClientError status_code 404 (this case only occurs intermittently):

    server.detach_disk(device_name, true)
    disk.wait_for { users.nil? || users == []}

When this case occurs, wait_for blocks until timeout.

This is because Fog::Model#wait_for only invokes the block when reload succeeds.

rchekaluk commented 7 months ago

Fixed by https://github.com/fog/fog-google/pull/613