The VMworld 2016 is coming in about two weeks. Although I’ve attended every single VMworld after 2007, it’s my first time as an exhibitor myself, to be exact, as a new innovator in the show. If you follow my blog and Twitter, you probably have know the company DoubleCloud that I had founded and the cool products/technologies we’ve been working on. This is the first year for us to promote our products in show. Please come to see our product demos, or simply stop by and say hi. Our booth is 841#4. Read more...
In my previous posts, I showed samples on virtual machine creation, virtual machine instances listing, storage volume listing. This sample shows how to list all the networks that you have.
With the information about your networks, you can get all the private and public IP addresses.
To run the following sample, you can check out the previous post for the pom.xml file and how to get AWS credentials from AWS console.
c7822baf808b44ad52830b1fc9c4534c002 Read more...
In my previous posts, I showed samples on how to create a new virtual machine instance, and how to list all the virtual machine instances you own. This sample shows how to list all the disk volumes that you have.
To run the following sample, you can check out the previous posts for the pom.xml file and how to get AWS credentials from AWS console.
public class AwsEc2ListVolumes
public static void main(String args) throws Exception
AWSCredentials credentials = new PropertiesCredentials(AwsEc2ListVolumes.class.getResourceAsStream("/AwsCredentials.properties"));
AmazonEC2 ec2 = new AmazonEC2Client(credentials);
DescribeVolumesResult volReq = ec2.describeVolumes();
int count = 1;
for (Volume vol : volReq.getVolumes())
System.out.println("Volume " + count + "\n Details: " + vol);
The output will be something as follows: Read more...
In my previous post, I showed a sample on how to list virtual machine instances. While that is helpful, maybe even more so is to create a new virtual machine. Here comes another sample that creates new virtual machine instance using the Amazon Java SDK. Read more...
I looked at Amazon Web Services SDK a while back and started to work with it recently. While searching it the Internet, I got all the results on the first two pages on Google pointing back to Amazon, which is great. After reading these documents, however, I got headaches. Why? For one thing, they are pretty long and sometimes run over different Web pages. Do you want to read for an hour to get your first program running? Or you are like me who would like to get my first program like Hello World to run in 5 minutes or even shorter. We should then read more if we don’t understand some parts. If you have gone through the Amazon documents, you’d know it’s impossible. Read more...
I flew to Vegas this week for Microsoft Management Summit 2013, which happens to be in the same hotel (Mandalay Bay) as VMware Partner Exchange one and half months ago. The organizations and activities of both conferences are pretty similar – keynotes, breakout sessions, hands on labs (HOL). It’s pretty exciting to learn new technologies and meet new people.
Hands On Labs Read more...
Amazon released its SDK for Java last month. It’s a complete set of APIs that cover almost all the services from EC2, S3, SQS, RDS to SimpleDB. Overall Amazon has done a consistent job, but the SDK is NOT really object oriented. And that I think is critical for higher development productivity.
Structure of the SDK
Before explaining why it’s not quite there, let’s take a look at the structure of the API itself. The SDK includes many packages. For each service, you find two or three packages: basic, model, and possibly util package.
In each of the basic packages you can find the two interfaces, and two implementation classes. Let’s pick EC2 as a sample here. The AmazonEC2 and AmazonEC2Async are two interfaces and implemented by AmazonEC2Client and AmazonEC2AsyncClient respectively. More methods are defined in the synchronous than the asynchronous versions with the majority of them overlapping with similar method names.
AllocateAddressResult allocateAddress(AllocateAddressRequest allocateAddressRequest)
Future<AllocateAddressResult> allocateAddressAsync(AllocateAddressRequest allocateAddressRequest)
The first two versions wait and get you results upon return. The third version doesn’t wait and gets the result later. Read more...