尝试在数据中心列出VSI的SSL读取超时

时间:2016-03-08 00:29:25

标签: ibm-cloud-infrastructure

我应该解释一下历史。我曾经发过http:

https://api.softlayer.com/rest/v3/SoftLayer_Account/getVirtualGuests.json?    objectMask=mask[datacenter.name,status,globalIdentifier,primaryBackendIpAddress,primaryIpAddress,billingItem.categoryCode,billingItem.description,billingItem.createDate,billingItem.orderItem.order.userRecord.username,billingItem.orderItem.order.userRecord.email,users.username,users.email,users.userStatus,operatingSystemReferenceCode,softwareComponents.passwords,operatingSystem,hourlyBillingFlag,localDiskFlag,managedResourceFlag,privateNetworkOnlyFlag,powerState,blockDeviceTemplateGroup.name,blockDeviceTemplateGroup.id;blockDevices.diskImage,networkVlans,activeTransactionCount,activeTransactions,consoleIpAddressRecord.type,consoleIpAddressRecord.port,consoleIpAddressRecord.ipAddress.ipAddress] 

这检索了所有数据中心的所有VSI,每次我都开始得到同样的错误,所以我现在遍历每个SoftLayer数据中心获取VSI。我使用以下EST API:

 https://api.softlayer.com/rest/v3/SoftLayer_Account/getVirtualGuests.json?objectMask=mask[datacenter.name,status,globalIdentifier,primaryBackendIpAddress,primaryIpAddress,billingItem.categoryCode,billingItem.description,billingItem.createDate,billingItem.orderItem.order.userRecord.username,billingItem.orderItem.order.userRecord.email,users.username,users.email,users.userStatus,operatingSystemReferenceCode,softwareComponents.passwords,operatingSystem,hourlyBillingFlag,localDiskFlag,managedResourceFlag,privateNetworkOnlyFlag,powerState,blockDeviceTemplateGroup.name,blockDeviceTemplateGroup.id;blockDevices.diskImage,networkVlans,activeTransactionCount,activeTransactions,consoleIpAddressRecord.type,consoleIpAddressRecord.port,consoleIpAddressRecord.ipAddress.ipAddress]&objectFilter={"virtualGuests":{"datacenter":{"name":{"operation":"_=sjc01"}}}}

除了我得到的所有工作正常:

'_content' => '500 SSL read timeout:
',
'_rc' => 500,
'_headers' => bless( {
'client-warning' => 'Internal response',
'client-date' => 'Mon, 07 Mar 2016 16:23:33 GMT',
'content-type' => 'text/plain'
}, 'HTTP::Headers' ),
'_msg' => 'SSL read timeout: ',

SJC01和TOR01 SoftLayer数据中心发生此错误。为什么会发生超时。

注意此循环中其他数据中心的工作原理,但在SJC01和TOR01上失败。

1 个答案:

答案 0 :(得分:0)

问题是你的objectMask,你从softlayer数据库中获取大量数据并导致失败,你可以尝试使用限制,看看这里的信息http://sldn.softlayer.com/article/Rest

如果这不起作用,则需要将对象遮罩分解为部分,例如您使用具有一些属性的对象掩码来获取某些属性的请求,然后使用另一个获取其他属性的请求等等,直到您拥有所需的所有属性。

此致