🌍 ExpressJS · flashcards
ExpressJS Deploying ExpressJS Applications Flashcards
51 question-and-answer cards covering Deploying ExpressJS Applications as it is examined in ExpressJS. 24 of them are printed below, taken from across the deck — no signup, no paywall on the preview.
24 sample cards from the Deploying ExpressJS Applications deck
Sampled from the end of the deck, so these are different cards from the ones shown on the syllabus page.
Where must GitHub Actions workflow files be located and in what format?
In the `.github/workflows/` directory of the repository, written as YAML files (e.g., `ci.yml`).
In a GitHub Actions workflow, what is the purpose of the `on:` key?
It defines the events that trigger the workflow, such as `push`, `pull_request`, `schedule`, or `workflow_dispatch`.
What are the core structural units of a GitHub Actions workflow, from largest to smallest?
Workflow → Jobs → Steps; jobs run on runners and contain steps, which are either shell commands (`run`) or reusable actions (`uses`).
Which GitHub Actions action is commonly used to install a specific Node.js version in a workflow?
`actions/setup-node@v4` (paired with `actions/checkout` to pull the repo), configured with a `node-version` input.
How should secrets like deployment tokens be handled in a GitHub Actions workflow?
Store them in repository/organization Secrets and reference them as `${{ secrets.NAME }}` in the workflow, never hardcoding them in the YAML.
What is Jenkins?
An open-source, self-hosted automation server used to build, test, and deploy software through configurable CI/CD pipelines, extensible via plugins.
What file defines a Jenkins pipeline as code, and what are its two main syntaxes?
A `Jenkinsfile` stored in the repo; its two syntaxes are Declarative Pipeline (structured, `pipeline { }`) and Scripted Pipeline (Groovy-based).
In a Declarative Jenkins pipeline, what is a `stage` and what is an `agent`?
A `stage` is a named phase of the pipeline (e.g., Build, Test, Deploy) containing steps; an `agent` specifies where/how the pipeline or stage executes (e.g., a node or Docker container).
Contrast Jenkins with GitHub Actions for CI/CD.
Jenkins is self-hosted (you maintain the server and plugins) offering deep control; GitHub Actions is cloud-hosted and tightly integrated with GitHub with minimal maintenance but less infrastructure control.
What is application logging and why is it essential in a production Express app?
Recording runtime events, requests, and errors to a durable output; it's essential for debugging, monitoring, auditing, and diagnosing incidents you cannot reproduce interactively.
What is Morgan in the Express ecosystem?
An HTTP request logging middleware for Express that logs incoming requests in configurable formats such as `combined`, `common`, `dev`, or `tiny`.
Name two dedicated structured-logging libraries commonly used in Node/Express instead of `console.log`.
Winston and Pino; they support log levels, structured/JSON output, and multiple transports (console, file, external services).
List common log severity levels from most to least severe used by loggers like Winston.
error, warn, info, http/verbose, debug, silly (roughly: error > warn > info > debug > trace), letting you filter output by importance.
Why is structured (JSON) logging preferred over plain-text logs in production?
JSON logs are machine-parseable, enabling aggregation, searching, filtering, and analysis by log-management tools (e.g., ELK, Datadog, CloudWatch).
In a containerized/PaaS deployment, why is logging to stdout/stderr preferred over writing to local files?
Because the platform captures stdout/stderr and forwards it to a centralized log system; local files are ephemeral and lost when the container/dyno restarts.
What is a health check endpoint in an Express app?
A lightweight route (commonly `/health` or `/healthz`) that returns a success status (e.g., HTTP 200) so load balancers and orchestrators can verify the app is alive and ready.
Distinguish a liveness probe from a readiness probe.
A liveness probe checks whether the process is alive (restart it if not); a readiness probe checks whether the app is ready to receive traffic (e.g., DB connected) and removes it from the load balancer until ready.
What HTTP status code should a healthy health check return, and what indicates unhealthy?
Healthy returns `200 OK` (sometimes `204`); unhealthy typically returns `503 Service Unavailable` so the orchestrator marks the instance as failing.
What should a thorough (deep) health check verify beyond the process being up?
Critical dependencies such as database connectivity, cache/Redis availability, and required downstream services, returning unhealthy if any essential dependency is down.
What is the difference between vertical scaling and horizontal scaling?
Vertical scaling (scaling up) adds more resources (CPU/RAM) to a single machine; horizontal scaling (scaling out) adds more instances/machines and distributes load across them.
Why can a single Node.js/Express process not utilize multiple CPU cores, and how is this overcome?
Node runs JavaScript on a single thread, so one process uses one core; the cluster module (or PM2 cluster mode) forks multiple worker processes to use all cores.
For horizontal scaling of Express across many instances, why must session state not be stored in process memory?
Because requests may hit different instances; in-memory sessions won't be shared, so state must be externalized to a shared store like Redis or a database (making the app stateless).
What is a load balancer's role when scaling an Express application horizontally?
It distributes incoming requests across multiple app instances (using algorithms like round-robin or least-connections), improving throughput and providing redundancy if an instance fails.
What is autoscaling and what metrics commonly trigger it for an Express deployment?
Automatically adding or removing instances based on load; common triggers are CPU utilization, memory usage, request rate, or response latency crossing configured thresholds.
What this deck covers
The Deploying ExpressJS Applications deck follows the ExpressJS Deploying ExpressJS Applications syllabus — 4 chapters and 10 topics — so questions land on material that is genuinely examinable rather than trivia around it. That works out to roughly 12.8 cards per chapter.
Answers are written to be recallable, not just readable — averaging about 157 characters, which is long enough to carry the reasoning and short enough to say out loud.
A deck like this earns its keep on the second and third pass. Read the syllabus first so you know the shape of the subject, then use the cards to find the specific facts that have not stuck.
Deploying ExpressJS Applications flashcards FAQ
How many Deploying ExpressJS Applications flashcards are in this ExpressJS deck?
51 cards. This page previews 24 of them, sampled evenly across the deck so you can judge the difficulty before installing anything.
Are these ExpressJS flashcards free?
Yes. The preview here is free to read with no signup, and the full 51-card deck is free inside the Examius app.
What do the Deploying ExpressJS Applications cards cover?
They follow the ExpressJS Deploying ExpressJS Applications syllabus — 4 chapters and 10 topics — so the questions track what is actually examinable.
How should I use these flashcards?
Read the syllabus first so you know the shape of the subject, then drill the deck. Examius schedules each card with spaced repetition, so cards you keep missing come back sooner and ones you know drift further apart.