Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Building Stretchables

Building Stretchables

Presentation at AWS User Group Meetup KL

Avatar for Jinny Wong

Jinny Wong

May 21, 2014
Tweet

More Decks by Jinny Wong

Other Decks in Programming

Transcript

  1. B U I L D I N G S T

    R E T C H A B L E S A W S I O S S D K A N D Jinny Wong Xseed Solutions Sdn Bhd
  2. – M E & A D R I A N

    “… ok, maybe not”
  3. Instances Volumes Snapshots Elastic IP Security Group Key Pair S3

    Monitoring Load Balancer Reserved Instance SNS SQS SES …
  4. T H E A W S I O S S

    D K Request-Response Object Pair ! EC2DescribeInstanceStatusRequest EC2DescribeInstanceStatusResponse … which in turn, gets passed into another pair… ! EC2DescribeInstanceStatusRequestMarshaller EC2DescribeInstanceStatusResponseUnmarshaller … now it’s finally serialised into a EC2DescribeInstanceStatusRequestMarshaller object … request is invoked (work backwards for response)
  5. T H E A W S I O S S

    D K EC2DescribeInstanceStatusRequest *request = [[EC2DescribeInstanceStatusRequest alloc] init]; ! EC2DescribeInstanceStatusResponse *response = [self.ec2Client describeInstanceStatus:request]; // returns array of EC2Instance ! Fairly straightforward really… and freakin’ comprehensive but…
  6. T H E A W S I O S S

    D K @try { EC2DescribeInstanceStatusResponse *response = [self.ec2Client describeInstanceStatus:req]; } @catch (AmazonServiceException *e) { ... } @catch (AmazonClientException *e) { ... } @finally { ... }
  7. T H E A W S I O S S

    D K Everything throws an exception… including errors Like auth errors due to incorrect access key/secret ! [AmazonErrorHandler shouldNotThrowExceptions];