本文整理了Java中com.cloud.resource.ResourceManager.updateGPUDetails
方法的一些代码示例,展示了ResourceManager.updateGPUDetails
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ResourceManager.updateGPUDetails
方法的具体详情如下:
包路径:com.cloud.resource.ResourceManager
类名称:ResourceManager
方法名:updateGPUDetails
[英]Update GPU device details (post VM deployment)
[中]更新GPU设备详细信息(虚拟机部署后)
代码示例来源:origin: apache/cloudstack
/**
* Updates GPU details on hosts supporting GPU.
*/
private void updateGpuEnabledHostsDetails(List<HostVO> hosts) {
List<HostVO> gpuEnabledHosts = new ArrayList<HostVO>();
List<Long> hostIds = _hostGpuGroupsDao.listHostIds();
if (CollectionUtils.isEmpty(hostIds)) {
return;
}
for (HostVO host : hosts) {
if (hostIds.contains(host.getId())) {
gpuEnabledHosts.add(host);
}
}
for (HostVO host : gpuEnabledHosts) {
HashMap<String, HashMap<String, VgpuTypesInfo>> groupDetails = _resourceMgr.getGPUStatistics(host);
if (MapUtils.isEmpty(groupDetails)) {
_resourceMgr.updateGPUDetails(host.getId(), groupDetails);
}
}
}
代码示例来源:origin: apache/cloudstack
final GPUDeviceTO gpuDevice = stop.getGpuDevice();
if (gpuDevice != null) {
_resourceMgr.updateGPUDetails(vm.getHostId(), gpuDevice.getGroupDetails());
代码示例来源:origin: apache/cloudstack
_resourceMgr.updateGPUDetails(vm.getHostId(), gpuDevice.getGroupDetails());
代码示例来源:origin: apache/cloudstack
_resourceMgr.updateGPUDetails(destHostId, gpuDevice.getGroupDetails());
内容来源于网络,如有侵权,请联系作者删除!