當我撥打SoftLayer_Virtual_Guest_Block_Device_Template_Group:addLocations
複製私人圖片_A交叉IDC
時,此功能立即返回True
。所以我們知道這個操作是異步的。softlayer api:如何在複製os映像與IDC交叉時獲取狀態(完成或處理)?
問題是我怎麼能知道這個異步操作完成了,即image_A
已經完成複製到目標IDC
?
我已經找到了API:
SoftLayer_Virtual_Guest_Block_Device_Template_Group:getTransaction()
,但是這一次總是返回一個空的海峽??什麼是地獄~~~
對image_A的操作相同,此時我調用removeLocations()來刪除idc_x(已存在的idc),結果是一個異常:Traceback(最近一次調用最後一個): SoftLayer.exceptions.SoftLayerAPIError:SoftLayerAPIError SoftLayer_Exception_Virtual_Guest_Block_Device_Template_Group_ActiveTransactionExists):此圖像模板目前有一項未完成的交易。但是,SoftLayer_Virtual_Guest_Block_Device_Template_Group:getTransaction()總是返回一個空str。 – lippman
我如何獲得當前未完成的交易狀態? – lippman