AI & Artificial Intelligence
Explore AI foundations, generative models, agents, developer tools, and responsible use.
LinkSpot Knowledge
Explore AI foundations, generative models, agents, developer tools, and responsible use.
Learn programming fundamentals, languages, web and mobile development, databases, testing, and architecture.
Explore cloud platforms, Linux operations, containers, DevOps, and networking.
Learn practical web and network security, identity, privacy, and security operations.
Explore data engineering, SQL, analytics, visualization, and data quality.
Explore PCs, semiconductors, mobile devices, IoT, robotics, and open web standards.
Discover developer, collaboration, and design tools plus no-code and low-code workflows.
LinkSpot Knowledge
Explore practical guides and knowledge by category.
1,879 articles
To handle Rails requests safely, decide which action each URL should reach and explicitly allow only the submitted fields the application may use. RESTful resource routing creates standard CRUD paths and URL helpers. Strong Parameters defines an allowlist for mass assignment. Inspecting routes and permitted fields helps locate request errors.
An RPC (Remote Procedure Call) service exposes an interface that lets a client invoke methods or operations on a server over a network. The call may look like a local function, but it involves serialization, transport, server execution, and response handling. Design the contract around method names and parameters as well as errors, deadlines, retries, and side effects.
Routing selects a handler according to an HTTP method and URL path. In Express, connect methods and paths with calls such as `app.get()` and `app.post()`. You can group related routes in an `express.Router()` and mount that router under an application path. The examples here target Express 5.
A reverse proxy is an intermediary server in front of web servers or application services. It accepts client requests, forwards them to a backend, and returns the backend response to the client. It can give clients one public entry point while hiding backend addresses and applying routing, TLS termination, caching, or load balancing. However, headers that carry the original client IP or external protocol are not automatically trustworthy; configure which proxies are trusted and how those headers are handled.
“Try again later” is not enough. A client needs to know whether the condition is temporary, when to retry, and whether the first attempt had an effect. Use the status and Retry-After with API-specific Problem Details extensions.
A retry budget caps the volume of repeated requests so retries do not overwhelm original traffic. A per-request attempt limit prevents one request from retrying forever, but cannot stop thousands of requests from each retrying. Design both a per-request cap and a client- or service-wide budget.
A resumable upload continues from the position the server accepted after a connection failure, instead of sending the whole file again. Tus 1.0 defines an open protocol for doing this over HTTP. A client creates an upload resource, uses HEAD to read the current byte offset, then sends the remaining bytes with PATCH and Upload-Offset. Even with Tus, the service must design authentication, authorization, retention, and final file validation separately.
Parse API requests on the server, validate their structure and business meaning, check authorization, and only then process them. Browser checks are a convenience for fast feedback; the server must validate every input at trust boundaries. A schema alone does not provide authorization, injection defenses, or every business rule.
Request deduplication lets a server recognize when the same logical operation arrives again because of a network retry or repeated submission, preventing duplicate side effects. For a state-changing API, store a client-generated unique idempotency key within a caller and operation scope, and make recording the key atomic with the mutation. Comparing request bodies or caching a key alone is not enough for safe deduplication.
Compressed requests reduce transfer size, but a small encoded body can expand dramatically after decompression. A server should bound not only incoming bytes, but also decoded output and processing time. If an API does not need compressed requests, disable decoding; if it does, use a streaming decoder that counts output as it is produced.
A request deadline is the point in time after which the caller no longer wants to wait; a timeout is the maximum duration allowed for one operation. For a request that crosses services, set one overall deadline and propagate the remaining time to downstream calls. This reduces work spent after the caller has already given up.
A request correlation ID links one request to the logs produced while handling it. Generate one when a service receives a request, or validate a value from a trusted tracing system, then carry it consistently through logs and internal calls. It must not contain authentication tokens or user data, and it must never grant access by itself.
A browser Fetch request can be canceled by passing an AbortController signal and calling controller.abort(). The fetch promise rejects with AbortError. Cancellation can also interrupt response-body reading after response headers arrive. It stops the client-side wait and body processing; it does not guarantee that work already started by the server is canceled or rolled back.
A request body size limit rejects oversized input before it exhausts memory, parsers, or temporary storage. Set limits at both the public ingress proxy and the application parser, and make sure the largest supported request fits every layer. An HTTP server can return 413 when a body exceeds its limit.
Redis Streams is a Redis data type that stores time-ordered, uniquely identified entries like an append-only log and supports both ordinary reads and consumer groups. Use independent reads or separate groups when every subscriber needs each entry; use one group when workers should share work. For group consumption, acknowledge successful processing with XACK, and plan pending-entry recovery and stream trimming separately.
A Kubernetes readiness probe periodically checks whether a container can handle requests now. On failure, Kubernetes does not restart the container; it marks the Pod unready and removes its IP from matching Service EndpointSlices. Use a startup probe for lengthy initialization, and design liveness separately to detect unrecoverable hangs.
Rate limiting controls how many requests are allowed over time to protect a service or its dependencies from overload. A requests-per-second number alone may not be enough. Decide what is limited, which caller or route it applies to, how much burst to allow, and whether the real bottleneck is request rate or concurrent work. Then give clients a response they can use to recover.
Rate-limit response headers can tell a client about the quota a server currently applies or how long to wait before another request. APIs do not all use the same field names or units. Check the API’s documentation first, honor Retry-After when present, and do not retry immediately based only on a counter or reset value.
RabbitMQ is a message broker that connects applications so they can exchange messages, buffer them in queues, and have consumers process them. In RabbitMQ 4.4’s AMQP 0-9-1 model, publishers send messages to exchanges, which select queues using binding rules before delivery to consumers. First distinguish whether you need work distribution, event copies for multiple services, or a log whose retained records can be read again; this makes it easier to choose between RabbitMQ queues and streams.
RabbitMQ can requeue an unacknowledged delivery when a consumer channel or connection closes before manual ACK. If every failure immediately requeues the message, it can form a hot loop that pressures workers and the broker. Classify failures and use delayed, bounded retries for transient errors and a dead-letter path for permanent errors.