VMware {code} Community
C_Bignoli
Contributor
Contributor

Very High CPU usage running java APis to retrieve inventory data

Hi, we are using Java VI SDK to retrieve from VC inventory information regarding VMs. My code is very similar to some of the sample code that is shipping with the VI SDK, i.e. it creates a TraversalSpec object and a PropertyFilterSpec to get name, config, runtime and guest properties for the VMs. The codes returns the expected results. However, ti takes a really long time (minutes) to return the data and, the CPU usage gets close to 100% during this operation. Our application is web based and the ViAPI code is run through the servlet execution. We have tried running several debugging tools to try to figure out what causes all this. The process appears to be very busy doing socketRead() operations so we thought that perhaps it was getting tons of data from the network, but the network traffic is minimal. We are running VirtualCenter 2.5 and VI SDK 2.5. Has anyone run into a similar situation or knows what might cause this behavior? Thanks,

Elsa

0 Kudos
0 Replies