Developer tools, end-user computing, frontend and IoT services: CodeBuild, CodePipeline, X-Ray, WorkSpaces, AppStream 2.0, Amplify and IoT Core

Task statement 3.8 · Cloud Technology and Services · 34% of the exam

Why this matters

This lesson covers four small service families that each answer one plain business question. How do we get code from a developer’s laptop into production safely, and find out why it is slow? How do we give staff a desktop or an application without shipping them a configured laptop? How does a small frontend team build and host an app without running servers? And how do thousands of sensors talk to the cloud?

A manager hears these questions in planning meetings. A salesperson hears them from customers: “our contractors need our design software for six weeks” or “we are fitting sensors to every machine on the factory floor”. A junior engineer meets the services in the first month on a team that ships software. None of them needs to configure the services for this exam. They need to hear the requirement and name the right service.

The exam treats these families the same way. Each service has a short, distinctive job, and the wrong answers are usually real services with a nearby job. Learn the one-line job of each, and the one detail that separates it from its neighbour.

The lesson

Developer tools: CodeBuild, CodePipeline and X-Ray

Modern teams release software through continuous integration and continuous delivery (CI/CD). Continuous integration means every change a developer commits is built and tested automatically, so mistakes surface within minutes. Continuous delivery means a change that passes those tests moves on towards production automatically, through the same steps every time.

AWS CodeBuild is a fully managed build service. A build is the work that turns source code into something that can run: compiling it, running the unit tests and packaging the result (an artefact) ready to deploy. CodeBuild runs each build in a fresh environment that AWS provides and scales, so the team runs no build servers of its own and builds do not wait for a shared build machine to come free.

AWS CodePipeline is a continuous delivery service. It models the release process as a series of stages, typically source, build, test and deploy, and runs every change through them in order. A commit to the code repository starts the pipeline, and the console shows a visual picture of where each change has reached and which stage failed. CodePipeline orchestrates; it does not compile code itself. Its build stage usually hands that job to CodeBuild.

AWS X-Ray helps developers analyse and debug applications that are made of many parts, such as microservices, where one user request passes through several services. X-Ray traces each request on its journey and draws a service map showing how long each component took and where errors occurred. That turns “the checkout page is slow” into “the call to the stock service is slow”.

The guide also lists the AWS CLI among the developer tools; it is the command line for every AWS service, covered with the other ways of accessing AWS in lesson 12.

End-user computing: WorkSpaces, AppStream 2.0 and WorkSpaces Secure Browser

End-user computing means delivering a working environment to staff from the cloud instead of from the device on their desk. In all three services the software runs on AWS, and the user’s device mainly receives the screen output and sends back keystrokes and clicks. Little or nothing important lives on the laptop, so a lost device loses no company data, and a new starter can work from a personal machine on day one.

  • Amazon WorkSpaces provides fully managed virtual desktops, Windows or Linux. Each user gets a complete desktop that keeps their files, settings and installed applications between sessions, reached from a laptop, tablet or thin client. It replaces the office PC.
  • Amazon AppStream 2.0 streams individual desktop applications, often straight to a web browser. The user gets the application, not a whole desktop, and installs nothing locally. It suits one piece of specialist software, such as a design or engineering package, that many people need for a while.
  • Amazon WorkSpaces Secure Browser gives users a managed web browser that runs in AWS, for reaching internal websites and software-as-a-service (SaaS) applications. The pages are shown on the user’s device, but no data is stored there, which suits contractors and staff on unmanaged devices.

Frontend web and mobile: AWS Amplify

The frontend is the part of an application that the user sees and touches: a website in the browser or an app on a phone. The backend is everything behind it, such as sign-in, data storage and APIs. Frontend developers are often expert in the first and would rather not build the second by hand.

AWS Amplify is a set of tools and a hosting service for frontend web and mobile developers. With Amplify, a developer can add common backend features, including user authentication, data and file storage, to a web or mobile app without designing that infrastructure from scratch, and Amplify creates the AWS resources behind them. Amplify Hosting then deploys and hosts the web frontend, building and releasing it automatically when the developer commits a change to the connected repository. One set of tools covers the whole full-stack app, from sign-in to hosting.

IoT services (for example, AWS IoT Core)

The Internet of Things (IoT) means physical devices, such as sensors, meters, vehicles and appliances, that connect to a network and send or receive data.

AWS IoT Core is the service that lets those devices connect to AWS securely and at scale. It does three jobs worth remembering:

  1. Authenticates and connects devices. Each device proves its identity, typically with a certificate, before it is allowed to talk to AWS, and the connection is encrypted.
  2. Brokers messages. Devices publish and receive messages through IoT Core using lightweight protocols, most notably MQTT, which was designed for small devices on unreliable networks. HTTPS is also supported.
  3. Routes messages with rules. IoT Core’s rules engine inspects incoming messages and sends them on to other AWS services, for example to store readings in Amazon S3 or Amazon DynamoDB, or to run an AWS Lambda function when a temperature passes a limit.

IoT Core also keeps a registry of the devices it knows, and a device shadow that records each device’s last reported state, so an application can read or set that state even while the device is offline.

Choosing a tool to build, release or debug an application

Map the verb in the scenario to the service:

  • Build, compile, run tests, produce a package, with no build servers to manage: AWS CodeBuild.
  • Automate the whole release, every commit flowing through stages, with a visual view: AWS CodePipeline.
  • Trace requests, find a bottleneck, debug a distributed application: AWS X-Ray.

The usual traps are services that also “watch” or “deploy”. AWS CloudTrail records API calls made to AWS, for auditing who did what; it does not follow an application request between services. AWS Config records how resource configurations change. Amazon CloudWatch collects metrics and logs and raises alarms; it tells you the application is slow, while X-Ray shows where. AWS CloudFormation provisions infrastructure from templates, and AWS Elastic Beanstalk deploys and runs a web application for you; neither is a build service.

Choosing a service that streams a VM’s screen to the user

When a scenario says the software runs on virtual machines in AWS and only the display reaches the user’s device, the answer is end-user computing. Then decide how much the user needs:

  • A full, persistent personal desktop, replacing the office PC: Amazon WorkSpaces.
  • One application, streamed to a browser, with nothing installed: Amazon AppStream 2.0.
  • Websites and SaaS apps only, through a browser that leaves no data on the device: Amazon WorkSpaces Secure Browser.

A question that asks for two services that stream from VMs is pointing at WorkSpaces and AppStream 2.0 together. Distractors here include Amazon CloudFront, which delivers web content from edge locations rather than streaming desktops, and Amazon Lightsail, which provides simple virtual servers rather than a managed desktop for each employee.

Choosing a service to build and host frontend and mobile apps

Key words such as frontend developers, mobile app, add sign-in, full-stack and host the web app point to AWS Amplify. The trap is a service that solves only part of the problem: Lightsail can host a website on a small server, but it gives a mobile developer no ready-made authentication or data features, and CodeBuild only builds and tests code.

Identifying the services that manage IoT devices

If the scenario mentions devices, sensors, MQTT, device authentication or routing device messages to other services, the answer is AWS IoT Core. The common distractors handle data or events, not devices. Amazon Kinesis ingests large streams of data, but it does not authenticate devices or speak MQTT to them. Amazon EventBridge routes events between applications, and AWS Step Functions coordinates the steps of a workflow. Other IoT services exist for edge computing and device security, but they sit outside this exam’s scope; here IoT Core is the IoT answer.

What the exam is really asking

Each question in this area tests whether you can tell neighbours apart: CodeBuild builds while CodePipeline orchestrates; X-Ray traces requests while CloudTrail audits API calls; WorkSpaces gives a desktop while AppStream 2.0 gives an application; Amplify gives frontend developers a backend and hosting; IoT Core connects and routes for devices. Spot the noun that describes what is being delivered, and the answer follows.

Practise what you just read

1. A team wants every commit to its code repository to move automatically through build, test and deployment stages, with a visual view of the whole release process. Which service should it use?

Select one

  1. AWS X-Ray
  2. AWS CodeBuild
  3. AWS CodePipeline
  4. AWS CloudFormation
Show answer

C. AWS CodePipeline is a continuous delivery service that models the release process as stages and runs each change through build, test and deployment automatically. AWS CodeBuild performs the build and test work inside such a pipeline but does not orchestrate the whole release, and AWS CloudFormation provisions infrastructure from templates.

2. A company wants to give its remote employees fully managed, persistent Windows desktops in the cloud that they can reach from their own laptops. Which service should it use?

Select one

  1. Amazon WorkSpaces
  2. Amazon Lightsail
  3. Amazon CloudFront
  4. Amazon AppStream 2.0
Show answer

A. Amazon WorkSpaces provides fully managed, persistent virtual desktops that employees reach from their own devices. Amazon AppStream 2.0 streams individual applications rather than giving each user a persistent personal desktop, and Amazon Lightsail offers simple virtual servers rather than a managed desktop service.

3. A manufacturer needs to connect thousands of sensors securely to AWS so that they can send messages over MQTT and have those messages routed to other AWS services. Which service should it use?

Select one

  1. Amazon Kinesis
  2. Amazon EventBridge
  3. AWS Step Functions
  4. AWS IoT Core
Show answer

D. AWS IoT Core connects and authenticates devices, accepts their messages over protocols such as MQTT and uses rules to route those messages to other AWS services. Amazon Kinesis can ingest high-volume data, but it does not connect, authenticate or manage devices, or speak MQTT to them, and Amazon EventBridge and AWS Step Functions route events and run workflows for applications.

7 more questions on this task statement are part of the full practice bank.

Practise the full question bank in the exam simulator

Hands-on labs

Every lab runs in your own AWS account, starts from the budget alert set in lesson 1’s lab, and ends with a clean-up.

All hands-on labs

This is an independent study companion for the AWS Certified Cloud Practitioner (CLF-C02) exam and is not produced by or endorsed by Amazon Web Services. AWS, Amazon Web Services and AWS Certified Cloud Practitioner are trademarks of Amazon.com, Inc. or its affiliates.