VMware Communities > Blogs > Developer Center Blog > Tags

Blog Posts

Developer Center Blog

11 Posts tagged with the code tag
0

We wanted to let you know we ran a very successful vSphere SDK lab at [Partner Exchange / Tech Exchange a few weeks ago in Orlando. For those of you who missed the event, I'm posting the manuals and code files. Going through the lab is a great way to get started with the API and includes handy sample code for modification or inclusion in your own programs.

{youtube}http://www.youtube.com/watch?v=paGqr9SWl-4{youtube}

The lab covers both the Java and C# versions of the VI SDK and uses the vSphere Web Services SDK 4.0 (formerly VI SDK 4.0). Though the lab doesn't cover any vSphere-specific features, I haven't tested it with VI SDK 2.5 and it will probably require some minor modification. For scripters that would prefer an introduction to the vSphere Perl SDK (formerly the VI Perl Toolkit) or the vSphere PowerCLI (formerly VI Toolkit for Windows), I posted a similar lab for those in an earlier blog post.

Exercises cover all the basics for using the SDK:
* Understanding managed objects and data objects
* Connecting to the VI API webservice
* getting the properties of managed objects using the PropertyCollector
* Using the SearchIndex
* Finding objects using TraversalSpecs
* Finding objects based on arbitrary criteria
* Collecting properties of multiple objects at the same time
* Understanding performance differences in some basic property collection strategies
* Monitoring properties for changes
* Monitoring tasks for completion
* Gathering performance statistics

There's obviously a lot more to do in the SDK, but once you've mastered those basic skills, most of the rest of the SDK is just an extension of what you already know. The exercises on collecting multiple objects properties at the same time and understanding performance differences due to property collector strategies cover some common problems I see with the management ecosystem partners I handle and are a great review for anyone trying to make sure their SDK code scales well.

A few things to note: I didn't update the doc with the new names of the various API components... I wrote the lab while those names were still under development. Also, I want to thank the other folks who helped put this lab together: Balaji Parimi (who wrote the Java code), Rajesh Kamal (who wrote the C# code), Alton Yu, John Kennedy, Paul Vasquez, and Steve Jin.

While most of the code handles errors gracefully and follows best practices, I’d like to point out that the code here is designed to teach concepts, not to be “enterprise ready”.

0 Comments Permalink
2

Folks,

Just wanted to clarify - event will be held in the Moscone Center in SF and not the Cal Academy of Sciences ;( I put this picture here because i think it would be a nice place to visit for anyone that is traveling from out of town - but I do agree this would be a SUPERB venue for a Developer Day.

Please save the date for VMware's first Developer Day @ VMworld 2009 - Monday August 31, 2009 in San Francisco CA.

We will be publishing session and registration information in a couple of weeks, but can provide some general information.

o 1 Day event dedicated for software developers building solutions for the VMware platform

o TAP membership is not required, or purchase of full VMworld Conference Pass

o There will be a Tech Exchange - TAP Track for Product Roadmaps (NDA - TAP membership required to attend)

o Sessions will range from vSphere SDKs to vCloud APIs - please stay tuned for session updates

o We will have plenty of demos and opportunity to meet with our R&D teams

Wanted to thank the community for your support and please keep the feedback coming. If you have ideas on what you would like to see please let us know and look forward to meeting the community members.

Nice picture below of the California Academy of Sciences - great destination for anyone that has not visited. They also have a great restaurant and Bar. My house is the little one under the television tower on the hillside - (which might explain my sense of humor and hair loss ;)

sf-cal.jpg

2 Comments Permalink
0

Folks,

We are extremely happy to announce the availability of our VMware vSphere SDKs and Toolkits to support the relase of the vSphere platform.

Congratulations to the teams around the world working day and night to make this happen.

New SDKs & Toolkits released today

VMware vSphere Web Services SDK 4.0

VMware vSphere Guest SDK 4.0

VMware Virtual Disk Development Kit 1.1

VMware CIM SDK 4.0

VMware SDK for Perl 4.0

VMware vSphere Client Plug-ins

VMware vSphere CLI 4.0

VMware vSphere PowerCLI 4.0

VMware vSphere Management Assistant 4.0

VMware Open Virtual Format Tool 1.0

Changes to our site:

o Creation of dedicated community style product pages. Product pages have links to Documentation, Discussions and community contributed documents.

o Added Events Calendar for exclusive developer / administrator topics - visit our VMware Coffee Talk Webinars for more info

o Consolidated our Community Contributed & VMware Sample Code into one site we call Code Central

o Updated the VMware Icons for the vSphere platform

lunar-landing.jpg

0 Comments Permalink
0


Folks we are excited that Hal’s book “Managing VMware Infrastructure with Windows PowerShell: TFM®” just hit the streets and we have been able to secure a 10% discount for our users out there looking to ramp up on their PowerShell skills.

SAPIENPress is offering a 10% off coupon for both ebook and print formats of Managing VMware Infrastructure with Windows PowerShell: TFM®.

Visit ScriptingOutpost.com with the coupon code VMTAP10 to receive your 10% discount.

http://communities.vmware.com/servlet/JiveServlet/downloadImage/5821/RTFM.JPG

0 Comments Permalink
4

Hello, my name is David Deeths and I’m a new contributor to the VMware Developer Blog. I wanted to share with the community the scripting lab we put together for VMworld 2008. This is a great introduction to scripting with the VI Toolkits in Perl or PowerShell. The PowerShell version doesn’t require any programming or scripting experience at all.

The labs will help you get started with scripting VMware Infrastructure to enable automation, extensibility, and integration with existing tools. When we ran this at VMworld, we had about 600 attendees and it was so popular some students camped out in line to attend the lab a second time. We had so many folks request a way to share this with their teams that we decided to publish the whole thing for the community.

The lab is available in two versions: one shows how to use the VI Perl Toolkit and the other shows how to use the PowerShell-based VI Toolkit (for Windows). The attached files contain the manuals for both versions of the lab and the exercises for both versions of the lab.

The lab takes 2-3 hours to complete (not including the time to set the environment up first), but is conveniently split into 20 minute exercises. You’ll walk away with a better understanding of VMware Infrastructure, resources for using the toolkits, and a variety of useful scripts for performing common administrative tasks. The exercises cover triggering tasks, examining VM attributes, performing actions on VMs, and exporting performance data.

My team for the lab was phenomenal, and I want to thank Doug Baer, Shridhar Deuskar, Lisa Guinn, Terry Lyons, Aaron Miller, Alket Memushaj, Owen Thomas, Brian Watrous, and Alton Yu for building this exceptional lab.

If you don’t have gear to try this out on or if you want more lab opportunities, a similar lab is in the works for VMworld EMEA (Cannes, February 24-26). For Technology Exchange (Orlando, April 14-17), we’re looking into doing a lab focused more on professional-developers that covers the VI SDK using Java and C#.

Enjoy!

PS. I’d like to point out that the code here is designed to teach concepts, not to be “enterprise ready”. Things like error checking have been kept to a minimum so concepts covered in each exercise are as easy as possible to understand. The lawyers have asked that I inform you that the sample code is provided "AS-IS" for use, modification, and redistribution in source and binary forms, provided that the copyright notice and this following list of conditions are retained and/or reproduced in your distribution. To the maximum extent permitted by law, VMware, Inc., its subsidiaries and affiliates hereby disclaim all express, implied and/or statutory warranties, including duties or conditions of merchantability, fitness for a particular purpose, and non-infringement of intellectual property rights. IN NO EVENT WILL VMWARE, ITS SUBSIDIARIES OR AFFILIATES BE LIABLE TO ANY OTHER PARTY FOR THE COST OF PROCURING SUBSTITUTE GOODS OR SERVICES, LOST PROFITS, LOSS OF USE, LOSS OF DATA, OR ANY INCIDENTAL, CONSEQUENTIAL, DIRECT, INDIRECT, OR SPECIAL DAMAGES, ARISING OUT OF THIS OR ANY OTHER AGREEMENT RELATING TO THE SAMPLE CODE.

You agree to defend, indemnify and hold harmless VMware, and any of its directors, officers, employees, agents, affiliates, or subsidiaries from and against all losses, damages, costs and liabilities arising from your use, modification and distribution of the sample code.

VMware does not certify or endorse your use of the sample code, nor is any support or other service provided in connection with the sample code.

4 Comments Permalink
0

December 31st 2008 article from NetworkWorld / NY Times recommends our VMware Developer websites as the # 3 Website IT Pros should master... ;)

"..... To get the best real-world feedback on how best to deploy VMware, keep your eyes on the VMware Communities Web site. It’s got user groups in your community and lots of tips from other VMware developers that can help you solve problems faster..."

NY Times: http://www.nytimes.com/external/idg/2008/12/31/31idg-Nine-Web-sites.html?em

Network World: http://www.nytimes.com/external/idg/2008/12/31/31idg-Nine-Web-sites.html?em

Big Thanks to our VMware community of developers for your contributions !!

number3.jpg


Pablo Roesch
VI SDK Product Marketing
http://vmware.com/developer

0 Comments 0 References Permalink
0

Folks,

Just wanted to let everyone know we have moved the great collection of scripts from the PowerShell Scripting contest over to our Community Sample Code site. We also tagged the scripts by language in order to make it a bit easier to find. We will be shutting down the Contest site shortly please update your book marks - This site will be going away -> http://vmware.com/go/powershellcontest pscontest.jpg will be going away.

If you forgot who won our contest or for the folks out there that just want to bathe in glory once again..visit http://blogs.vmware.com/vipowershell/2008/09/announcing-the.html

To see the collection of community sample code, or if you have some very cool code you want to share (it does not have to be in PowerShell:) This site is also linked from the Developer Community http://vmware.com/developer

Visit: http://communities.vmware.com/community/developer/utilities?view=documents communitysamplecode.jpg

0 Comments 0 References Permalink
1

The open source client side Java API for VI can now be found at

http://sourceforge.net/projects/vijava

Thanks!

1 Comments Permalink
0

Folks,

Just wanted to let you know that we have just published a document to help you get started when using the VI Toolkit for Windows.

Document Title: Managing VMware with PowerShell - Frequently Asked Questions.

Document contains frequently asked questions and code samples to help you get going.

A big thank you to the Product Management, Developer Support Engineering and R&D teams who contributed to document. We hope the document is useful, and please feel to comment so we can improve our products.

Link: http://communities.vmware.com/docs/DOC-4210

Regards,

Pablo

0 Comments Permalink
0

Folks latest script added to our library. Script allows users to set the boot preference for a virtual machine.

http://download3.vmware.com/sample_code/Perl/VMBootOrder.html

For complete list of scripts:
http://www.vmware.com/communities/content/developer/samplecode/index.html

Let us know what else you would like to see added...

_P

0 Comments Permalink
2

Welcome to the VMware Developer Center Blog
elsalvi.jpg


Atami Beach, San Salvador

Hello,

Welcome the VMware Developer Center Blog. My name is Pablo Roesch and I am the Product Marketing Manager for the VMware Infrastructure SDKs. My job at VMware is to help empower developers, IT administrators when integrating, and automating with our SDKs.

Before VMware I worked for Sun Microsystems in various roles, most recently responsible for building out the Developer Services Portfolio for the Sun Developer Network. On the personal side I have lived in San Francisco most of my life, and enjoy spending time with my wife and kids. Just in case you are ever in this fine city I would recommend the Slanted Door for dinner and CafeGreco for an after dinner Cappuccino. As a side note I have included a photo of my all time favorite beach in San Salvador which helps me put things into perspective.

It is an exciting time for us at VMware as our SDKs are going through a much needed evolution with recent release of the VI Perl Toolkit 1.5 and upcoming sneak peak of the VI Toolkit for Windows (manage VI using Powershell)

I often get asked what the difference is between the VMware Developer Center and the Developer Community so thought I would bring this up front.

The VMware Developer Center provides information on latest SDK product downloads, knowledge base articles, webinars, questions and answers as expressed by VMware. The Developer Community is how the community interacts with VMware. The VMware Community is where developers, scripters post questions about our SDKs, provide sample code for community use, and comments on our products.

Visit our VMware Developer Center http://vmware.com/developer as we have recently made some much needed improvements to hope you find them helpful.

Navigation: Created a new navigational bar on right hand side, which will help with navigation of our site.

Knowledge Base Articles: Growing list of KB articles, to see current list click here

SDK Questions and Answers: Adding list of frequently asked questions

New webinars and sessions: New sessions posted range Product information to VMworld Sessions.

VMware Sample Code: Ongoing effort to increase our code sample library as requested by our users. Comment or suggestion for Sample Code? Please let us know by answering this quick questionnaire.

We look forward to continuing improvements to our site, please keep the feedback coming !

Pablo Roesch - VMware SDK Product Marketing Manager

Visit the VMware Developer Center: http://vmware.com/developer Latest Downloads, Code Samples, Knowledge Base Articles

2 Comments Permalink

Developer Center Blog

VMware Developer Blog provides content for the VMware Developer Community.