Home > vSphere API > Announcing GA of VI Java API 5.1 Supporting vSphere 5.1

Announcing GA of VI Java API 5.1 Supporting vSphere 5.1

November 27th, 2012 Leave a comment Go to comments

It’s been two months since I announced beta of VI Java API 5.1 supporting vSphere 5.1 on September 23. I got many emails asking for the GA date from ISVs and IHVs as the API is now a corner stone in their products. With the long (could be longer, BTW) Thanksgiving holidays, I got some time to review the fixes and release the GA version. I intended to announce it yesterday but somehow extra spam comments pushed the database behind over 100MB limit thus I could not post any new article.

There were two regressions in the beta of 5.1. One regression was caused by the missing of the hashCode() and equals() methods in the ManagedObjectReference class. It’s not a problem unless you compare two managed objects, or use the caching framework which relies on the hashCode() and equals() methods to determine whether a managed object is already in the cache (essentially hash tables in implementation).

Time to learn how to "Google" and manage your VMware and clouds in a fast and secure

HTML5 App

The other regression manifested itself in the queryVmfsDatastoreCreateOptions() method defined in HostDatastoreSystem. Somehow I forgot to change the array size from 3 to 2, therefore the 3rd element in the array caused NullPointerException during execution. From this, you know manual process can be error prone no matter how careful I was.

Another bug fix is the missing getSummary() method on VirtualApp which is a sub type of ResourcePool type. There was a method defined on the parent type ResourcePool already but the return type is ResourcePoolSummary. While calling the inherited getSummary() with a VirtualApp object, you want to case the ResourcePoolSummary type down to its sub type VirtualAppSummary if you want to access VirtualApp specific properties. It’s doable but not quite convenient, therefore I added an overridden method getSummary() in the VirtualApp class. Given how vSphere API is designed there may be several other similar cases. Please feel free to file a bug.

In the beta announcement post, I mentioned the new base64Binary type sneaking into the vSphere API 5.1. It can definitely be supported, but need quite some effort to make it work. Luckily it’s pretty much isolated to very small part of the API. This buys me some time to do it right in the future.

Enough being said. It’s time to give it a try. To download the jar files, please click here.

Categories: vSphere API Tags: ,
  1. November 27th, 2012 at 00:43 | #1

    [DoubleCloud] Announcing GA of VI Java API 5.1 Supporting vSphere 5.1 http://t.co/cSOfrU6r

  2. November 27th, 2012 at 01:36 | #2

    Announcing GA of VI Java API 5.1 Supporting vSphere 5.1 (DoubleCloud) http://t.co/4neoqgin

  3. November 27th, 2012 at 06:36 | #3

    “@sjin2008: [DoubleCloud] Announcing GA of VI Java API 5.1 Supporting vSphere 5.1 http://t.co/zljxk4wI” – Great work Steve!

  4. santhosh
    November 28th, 2012 at 08:23 | #4

    Hi Steve ,

    I am getting performance metrics from vcenter, from esxi server not getting that information.For getting performance metrics form ESXi can we need license compulsory? Please provide information about this.

    thanks you

  5. Sebastian
    November 28th, 2012 at 14:59 | #5

    When will the GA version of VI Java API 5.1 be updated in the Maven reps?

    Best regards and thanks for the hard work on this release!

  6. December 7th, 2012 at 19:05 | #6

    yea, I am still using the 5.1-beta from maven. Any chance you can update maven central?

  7. Daniel
    January 22nd, 2013 at 10:50 | #7

    Hi!

    Thanks for vijava, it’s really a great lib !

  8. January 22nd, 2013 at 11:09 | #8

    You are welcome Daniel, I am glad you and others like it.
    Steve

  9. Paul
    January 23rd, 2013 at 07:04 | #9

    Thanks for all the work you do on this Steve, it is essential for my work! Do you have any plans for submitting the GA to maven central?

  10. January 23rd, 2013 at 11:46 | #10

    Hi Paul, I am glad you like it. I don’t have a plan yet. Is it something you can help? :-)
    Steve

  11. July 9th, 2013 at 15:52 | #11

    Seems that com.vmware:vijava:5.1 is in Central now—great! Anyone still using artifacts with the com.cloudbees.thirdparty groupId should switch. (I published a Maven relocation for this version.)

  1. November 27th, 2012 at 15:55 | #1
  2. December 8th, 2012 at 18:45 | #2