Backend Flashcards
What is the MVC architecture?
MVC (Model-View-Controller) separates an application into:
- Model: Handles data and business logic.
- View: Displays data to users.
- Controller: Handles user input and updates the model or view.
What does statelessness mean in backend development?
Statelessness ensures that the server doesn’t retain client data between requests. Each request contains all necessary information, as seen in REST APIs.
What are CRUD operations?
CRUD stands for Create, Read, Update, Delete—basic operations for interacting with data in a database.
What is middleware in backend contexts?
Middleware is a function that intercepts and processes requests or responses. Examples: request logging, authentication, or validating request data.
What is dependency injection in backend development?
Dependency injection is a design pattern where dependencies (e.g., database connections) are provided to components by an external system, improving testability and modularity.
What is rate limiting, and why is it important?
Rate limiting restricts the number of API calls a client can make in a given timeframe to prevent abuse and ensure resource availability.
What is session management in backend systems?
Session management involves maintaining a user’s state (e.g., login) across multiple requests, often using server-stored sessions or tokens (e.g., JWT).
Why are logging and monitoring important in backend development?
Logging tracks system events for debugging and auditing, while monitoring tracks metrics (e.g., CPU usage) to identify performance issues or failures.
What are data migrations?
Data migrations involve modifying a database schema or data structure, often performed when introducing new features or updating the database schema.
What is error handling in backend systems?
Error handling involves detecting, responding to, and logging errors to prevent crashes and provide useful feedback to clients.
What is connection pooling in backend systems?
Connection pooling maintains a pool of reusable database connections to reduce the overhead of opening and closing connections for every request.
What is RESTful routing?
RESTful routing maps HTTP methods to CRUD operations:
- GET → Read.
- POST → Create.
- PUT/PATCH → Update.
- DELETE → Delete.
What is database indexing?
Indexing improves query performance by creating a data structure that allows faster lookups for specific columns in a database.
What is Gzip compression, and why is it used?
Gzip compresses HTTP responses, reducing payload size and improving client load times.
What is a health check endpoint in backend systems?
A health check endpoint provides information about the system’s status (e.g., /health returning service availability), useful for monitoring and auto-scaling.