Chapter 14
IN THIS CHAPTER
Using the console and sample code
Learning from videos and webinars
Solving problems through alternative sources
It’s deadline time and you’ve been struggling to complete your AWS application before the boss arrives to make life interesting. Fortunately, you have this chapter to help you work faster (beating the deadline so that you can just smile as the boss walks by). Of course, you didn’t have to get so close to the deadline in the first place. By using these techniques, you can make AWS application development faster and easier.
The GUI is slow, the GUI is cumbersome, the GUI is for someone else — someone less experienced with computers than you. Of course, you can keep telling yourself these less-than-truthful memes or you can come to the decision that the GUI really can help you understand AWS better. Sometimes, the fastest way to determine how to perform a task using the Command Line Interface (CLI) or within a program is to determine how the console does it. The console can show you the process that AWS prefers when performing certain tasks. In many cases, going through the process and keeping notes can help you write applications that work much faster than a trial-and-error approach.
Another reason to use the console is to determine what values AWS actually wants. Many of the examples in this book have you go to the console to obtain a required value. For example, trying to find the Amazon Resource Number (ARN) for an object can prove nearly impossible when using CLI or code, but finding it in the console is usually quite easy. Rather than spend an afternoon fiddling with code to retrieve an ARN, you can simply hard code it while working through the specifics of the application. Later you can work through the code required to obtain the ARN you need.
Most developers spend a great deal of time looking at other people’s code. It’s sort of like viewing your neighbor’s sheet during a test in school, except this kind of cheating is perfectly legal. In fact, it’s encouraged. Here are a few places you might want to try when looking for an example that completely squashes that problem you’re having:
https://aws.amazon.com/code
https://aws.amazon.com/documentation/
https://github.com/search?q=AWS
Don’t forget to check the documentation for any SDKs or add-on libraries you use. For example, Python developers will definitely want to check the Boto3 documentation at https://boto3.readthedocs.io/en/latest/
. These sites often contain separate example application sections that you can use to get started faster.
This book shows you at least three different ways to accomplish most tasks. It might seem like overkill at first, but sometimes working with AWS doesn’t sink in by using only one technique. The three most common techniques you should use to perform trial-and-error methods when discovering a new way to interact with AWS are
It isn’t random chance that this book relies on Anaconda to perform most programmatic tasks. The combination of Python and Anaconda Notebooks provides an exceptionally friendly environment in which to write code and see what happens. Because the feedback is instantaneous and you can work in a piecemeal fashion, the Notebook environment gives you immediate and detailed feedback. You don’t have to keep going through the write ⇒ debug ⇒ run cycle with Python — you just write code and execute it.
Watching a video and then practicing what the video shows you offers you two methods of learning that have nothing to do with the usual trial-and-error coding techniques. A change of pace can help you discover that nuanced technique that you completely missed by using other methods. Every developer has had the experience of someone else checking code to find a really obvious error that the developer should have seen but didn’t. Videos work the same way, giving you a different perspective on the whole configuration and coding process so that an obvious error actually does become obvious.
Videos can also provide a needed break and a change of pace. It’s hardly surprising when you continue to attack a problem using precisely the same methods and continue to fail. There is likely nothing wrong with the method, but you become tired and stop thinking through the process correctly. You need a different viewpoint. With this in mind, here are some places to look for AWS videos that help you get a fresh start on that problem you’re currently trying to solve:
https://aws.amazon.com/training/intro_series/
https://www.youtube.com/user/AmazonWebServices
https://www.youtube.com/results?search_query=AWS
http://freevideolectures.com/Course/3649/Cloud-Computing/
Webinars involve attending a short course without actually going anywhere. You get the kind of instruction you might get from a seminar but get to be in your usual comfortable seat and drink coffee from your own mug. For many developers, it’s pure heaven because they can replay sections of the webinar as needed and don’t suffer the discomfort of going to an unfamiliar location. Viewing a webinar can help you learn new techniques that are too complex for other sorts of learning, such as videos. Here are some places you can look for AWS webinars to meet your every need:
https://aws.amazon.com/about-aws/events/monthlywebinarseries/
https://aws.amazon.com/about-aws/events/monthlywebinarseries/archive/
https://aws.amazon.com/about-aws/events/
https://aws.amazon.com/webinars/partner-webinar-series/
https://www.youtube.com/user/AWSwebinars
Case studies don’t necessarily provide you with that amazing bit of code you absolutely have to have to complete your application, but they can impart ideas. By the end of most days, developers have mush for brains because they’ve tried every idea — more than once — and sometimes to the point of being absurd. In fact, the last few hours of your workday might not even prove productive, except in improving your skills at Solitaire. That’s why the case studies at https://aws.amazon.com/websites/
are so important. By seeing how other developers deal with problems, you might get some insights into dealing with your own. Even in the worst-case scenario, reading about other people’s successes can help inspire you a lot more than yet another game of Solitaire will.
Anyone who works with open source products knows the benefits of using peer support to answer the tough questions. The same principle might not seem to apply to AWS, but it does. You can often get just the right answer from someone who has already been where you are now through an online peer resource. Some of the most popular places to get AWS-specific help are
https://developer.amazon.com/support
https://www.quora.com/
https://github.com/
Blogs can be helpful because many authors are quite knowledgeable about AWS. A blog can provide you with a process for performing a configuration or some special coding technique to use with Lambda. Blog posts can also tell you about caveats and supply fixes that Amazon sometimes buries on a page that no one visits.
https://developer.amazon.com/support
https://blog.cloudthat.com/category/aws/
https://hackernoon.com/tagged/aws
You can sometimes find answers in surprising places, and it pays to look hard sometimes rather than waste days with a problem someone else has already solved. One of the alternative sources you might try is other vendor sites. For example, you can occasionally find useful information on the MSDN forums (https://social.msdn.microsoft.com/Forums/
). Not long ago, a thread appeared on MSDN about running the MSDN subscription on AWS (to make accessing it everywhere easier). Odd bits of information like this can be elusive to find, so don’t limit your search to just one location; look everywhere.
Sites such as SlideShare (https://www.slideshare.net/
) can also prove excellent resources. For example, when considering the previous MSDN license-hosting question, you can find information on that topic on SlideShare at https://www.slideshare.net/AmazonWebServices/leveraging-amazon-web-services-to-host-msdn-licenses
. YouTube (https://www.youtube.com/
) also offers a wealth of videos to check out. Some of these videos are listed at https://www.youtube.com/results?search_query=AWS
. If everyone learned precisely the same way, you wouldn’t need to check out these other resources, but when you’re in a bind, looking into alternatives really does pay. Perhaps a coding example presented in the traditional way just isn’t enough to solve that horrifying problem that threatens your weekend.
This book is one of your main sources of information. However, even as informative as this book is, it can’t contain absolutely every piece of information about AWS in every possible form. A lot of people rely on tutorials to fill in gaps. Even the experts do (sometimes, especially the experts). Tutorials are fast and often present information in ways that you wouldn’t otherwise consider. Of course, you have all the Amazon-specific tutorials to consider as well. Every main service page contains a listing of tutorials to try. In addition, check out the tutorials at these locations:
https://aws.amazon.com/getting-started/tutorials/
http://docs.aws.amazon.com/gettingstarted/latest/awsgsg-intro/gsg-aws-tutorials.html
https://www.youtube.com/user/awstutorialseries
Amazon likely has other tutorials for you to try, but these locations give you just about everything you could ask for in the way of quick information. Of course, many third parties are also involved with AWS. Here are some of the more interesting sites to try:
https://www.tutorialspoint.com/amazon_web_services/index.htm
http://www.guru99.com/aws-tutorial.html
https://www.pluralsight.com/browse/software-development/python
and https://www.pluralsight.com/courses/aws-developer-introduction-aws-lambda
.