Aerospike Hands-on 101

Course Description

This highly-interactive, hands-on workshop is designed as a level-setting introduction for anyone interested in Aerospike.

Each lesson allows beginner, intermediate and expert developers to “choose their own adventure” and end up with a strong Aerospike foundation at the end.

  • Beginner track - if you are new to terminal commands, containerization, Python libraries and virtual environments, you’ll want to watch the videos and code-along with them.
  • Intermediate track - choose video or high-level instructions based on each lesson’s topic area.
  • Advanced track - start with the high-level instructions and only check the video as needed.

Video and high-level instruction options are available to all learners in all lessons so feel free to move around and find the approach that works best for you in each lesson.

After the lab portion or each lesson, most lessons have practice quizzes (called “Lock It In”) where you can attempt answers as many times as you need to. The practice quizzes are followed by an exit quiz. Each question in an exit quiz will only allow two attempts. You must pass each lesson’s exit quiz with 80% or better in order to continue with the workshop.

At the end of the workshop, if you’ve met the 80% performance requirement, you will be issued a badge you can share on LinkedIn.

course badge

Lesson Content

1

Set Up Your Aerospike Container

What is a container and how will I use one to quickly deploy and explore Aerospike?
Intended learning outcomes
  • Explain what a container is in the context of database deployment.
  • Pull the official Aerospike CE image.
  • Launch Aerospike CE in a local container.
2

Log In to Your Aerospike Container

How can I log in to my Aerospike deployment and take a look around?
Intended learning outcomes
  • Launch a terminal session in Docker Desktop.
  • Use docker exec to access the Aerospike container.
  • View Aerospike’s configuration file using cat.
3

Use Aerospike's Admin Tool

How can I open and use the Aerospike ADMIN tool?
Intended learning outcomes
  • Log in to the Aerospike Admin tool (asadm).
  • Use show config to view configuration details.
  • Identify configured port and namespace.
4

Set Up Jupyter

How can I set up a way to test code quickly and easily?
Intended learning outcomes
  • Download and run a Jupyter notebooks image.
  • Launch Jupyter and access via tokenized URL.
  • Verify setup by creating and running a test notebook.
5

Install the Aerospike Python Library

How do I make sure Aerospike can understand Python commands?
Intended learning outcomes
  • List installed Python packages with pip list.
  • Import and run a pre-installed package.
  • Install and verify the Aerospike Python library.
6

Open a Port for Aerospike & Create a Network

How will Aerospike and Jupyter Notebooks be able to contact each other?
Intended learning outcomes
  • Configure Aerospike with open port 3000.
  • Create a Docker network and connect containers.
  • Test connectivity using Python client commands.
7

Create the Vest Vault Namespace

Is it time for me to create a database yet?
Intended learning outcomes
  • Install a text editor (nano).
  • Configure a new namespace vest_vault.
  • Validate namespace creation with asadm show config.
8

Aerospike PUT & GET Record Commands

How do I read & write records in Aerospike?
Intended learning outcomes
  • Navigate Aerospike’s namespace/set/item ID structure.
  • Execute PUT and GET commands.
  • Parse GET results into record ID, metadata, and details.
9

Sessions, Variables & Reboots

What happens if I stop and restart my container?
Intended learning outcomes
  • Explain how reboots affect variables and libraries.
  • Use Markdown cells in Jupyter for organization.
  • Separate once-per-session vs repeated commands.
10

Organizing Code for Success

How can I organize my code to avoid errors?
Intended learning outcomes
  • Use variables to refactor frequently reused values.
  • Define compound variables for efficiency.
  • Streamline execution with Shift+Enter.
11

The Aerospike Record Digest

Why do I sometimes see “none” instead of my item_id?
Intended learning outcomes
  • Apply POLICY_KEY_SEND for item ID visibility.
  • Compare GET outputs with/without policies.
  • Weigh pros and cons of item IDs vs digests.
12

Querying Your Records

How do I pull more than one record at a time?
Intended learning outcomes
  • Create and run a query function.
  • Use a Query object with a forEach loop.
  • Refactor queries into reusable sections.
13

Just the Good Stuff

How do I get just the parts of the record I want?
Intended learning outcomes
  • Modify UDFs to filter output.
  • Apply SEND_KEY policy during PUT.
  • Update existing records by overwriting bins.
14

Adding More Item Attributes

How do I describe items in richer detail?
Intended learning outcomes
  • Convert strings to lists for multiple values.
  • Add multiple bins (subcat, condition, material).
  • Interpret function syntax via documentation.
15

An Integrated Development Environment

How do I work in a complete Aerospike development environment?
Intended learning outcomes
  • Pull and build AS EDU image from GitHub.
  • Launch web (8080) and IDE (8081) interfaces.
  • Validate namespace config with asadm.
16

The Project Workspace & Python Venv

This looks complicated. What is all this stuff?
Intended learning outcomes
  • Navigate and clean up workspace.
  • Create and activate Python virtual environment.
  • Verify environment functionality with test scripts.
17

Aerospike PUTs & GETs from VSCode IDE

How do I read & write Aerospike records using VSCode?
Intended learning outcomes
  • Configure VSCode for Aerospike scripts.
  • Install Aerospike library in environment.
  • Write and run connection, PUT, and GET scripts.
18

Refactor Your Code

How do I organize my code into reusable blocks?
Intended learning outcomes
  • Refactor symbols and functions.
  • Encapsulate repeated code into functions.
  • Move reusable code into separate files.
19

Refine & Improve Your Code

How can I polish my Aerospike application code?
Intended learning outcomes
  • Separate PUT and GET scripts.
  • Parameterize functions for reusability.
  • Organize functions into a dedicated file.
20

Quick Intro to Uvicorn & FastAPI

How can I build a lightweight API for Aerospike?
Intended learning outcomes
  • Install and launch FastAPI with Uvicorn.
  • Create and test API routes.
  • Integrate Aerospike queries into API endpoints.
21

Making Bins Searchable

How do I search records efficiently?
Intended learning outcomes
  • Manage secondary indices with asadm.
  • Query data with AQL.
  • Evaluate performance tradeoffs of indexing.
22

Filtered Queries in FastAPI

How can I filter API query results?
Intended learning outcomes
  • Extend queries with predicates.
  • Add filtered routes to FastAPI.
  • Implement single-item endpoints with validation.
23

Service for Speed

How do I scale my code into a service?
Intended learning outcomes
  • Refactor functions into a service class.
  • Organize interactions under class methods.
  • Improve maintainability with abstraction.
24

Finishing Touches

How can I wrap up this project, get my badge, and share it?
Intended learning outcomes
  • Finalize function/file naming conventions.
  • Implement service close functions.
  • Validate workflow and publish project outcomes.