mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-16 22:50:10 +03:00
bug #1354: Handle exception when trying to connect to the marketplace
This commit is contained in:
parent
ba144487ed
commit
d5036967d4
@ -113,6 +113,12 @@ module CloudClient
|
||||
str << "Server: #{url.host}:#{url.port}"
|
||||
|
||||
return CloudClient::Error.new(str,"504")
|
||||
rescue SocketError => e
|
||||
str = "Error timeout while connected to server (#{e.to_s}).\n"
|
||||
|
||||
return CloudClient::Error.new(str,"503")
|
||||
rescue
|
||||
return CloudClient::Error.new($!.to_s,"503")
|
||||
end
|
||||
|
||||
if res.is_a?(Net::HTTPSuccess)
|
||||
|
Loading…
x
Reference in New Issue
Block a user