참고 자료 · 77

API 할당량과 속도 제한

제한은 용량, 재시도와 고객 간 배분에 영향을 줍니다.

업데이트됨 · 14 min

자료와 지도가 있는 빈 정보 기록실 AI로 생성한 편집용 일러스트

이 가이드가 달성하는 목표

  • 예산 정의
  • 복구 범위 제한
  • 불확실한 작업 처리
  • 재시도 책임 지정
  • 무용해진 작업 정지

빠른 확인

  • 할당 범위, 헤더, 대기, 재시도 예산을 기록하고 통제된 소진을 시험하세요.
  • 동시 재시도가 과부하를 악화할 수 있습니다.

단계별 방법

  1. 1

    예산 정의

    할당량이 계정, 키 또는 자원 중 어디에 적용되는지와 클라이언트의 동시 작업 수를 기록합니다. 평균 빈도가 낮아도 무제한 대기열은 서비스를 과부하시킬 수 있습니다.

    할당량 단위, 병렬 수와 대기열 크기를 기록합니다.

  2. 2

    복구 범위 제한

    429에 Retry-After가 있으면 해석하고 다음 요청까지 기다립니다. 증가하는 대기 시간과 클라이언트별 시간 분산을 최대 시도 수와 전체 기한에 결합합니다.

    시도 순서와 시간을 보관합니다.

  3. 3

    불확실한 작업 처리

    쓰기 응답이 사라졌다면 재시도 전에 상태를 확인합니다. 모의 시험에서 할당량, 늦은 응답과 취소를 조합하여 중복 효과 없이 대기열이 끝나는지 확인합니다.

    최종 효과와 대기 작업을 보관합니다.

  4. 4

    재시도 책임 지정

    앱, SDK, 프록시와 의존성의 자동 시도를 정리합니다. 책임 계층을 고르고 계약에 따라 추가 시도를 끄거나 조정합니다. 첫 시도도 총예산에 포함합니다. 작업 ID를 보존하고 비멱등 작업 재시도 전 불확실한 효과를 확인합니다.

    재시도 지도와 작업 총예산.

  5. 5

    무용해진 작업 정지

    클라이언트 실제 한도를 고려해 대기, 연결과 처리를 포함한 전체 기한을 정합니다. 큐 수용 전 만료 작업을 거부합니다. 로컬 취소가 서버 중단을 입증하지 않으므로 상태를 대조합니다. 모든 큐를 동시에 재시작하지 말고 점진 복구를 시험합니다.

    전달한 기한과 중단 또는 대조 근거.

재현 가능한 수락 사례

가상 예시입니다. 고객이나 실제 관측 결과를 나타내지 않습니다.

사례 입력 보기
{
    "http_status": 429,
    "retry_after_seconds": 30,
    "workers": 20,
    "retry_budget": 3,
    "retry_budget_scope": "per_worker_retries_excluding_initial_request",
    "scheduling_example": {
        "response_received_at_seconds": 0,
        "illustrative_retry_seconds": [
            30,
            31,
            32,
            33,
            34
        ],
        "workers_per_second": 4,
        "alternative_deadline_seconds": 25,
        "total_attempts_if_all_retries_used": 80
    }
}

예상 판단

30초 대기를 준수하고 20개 워커의 재시도를 분산하며 횟수를 제한합니다.

클라이언트 20개의 재시도 분산과 횟수 계산

가상 예시: 워커 20개가 +0 s에 각각 429와 Retry-After: 30을 받습니다. 시간표는 가능한 분산 예시이며 서버 용량을 보장하지 않습니다. 각 워커는 최초 요청 외에 3회 재시도할 수 있습니다.

정책계산 또는 일정효과와 한계
동시 재시도20 × 1 = 20 @ +30 s30초를 기다리면 대기 지시는 지키지만 20개 요청이 동시에 돌아오므로 부하가 다시 집중될 수 있습니다.
분산 재시도4 × 5 = 20 @ +30…+34 s초당 4개씩 5초 동안 보내면 재시도 20개가 분산되지만 총수는 줄지 않습니다. 이 예시 일정은 무작위 지연을 더하는 백오프 정책을 대신하지 않습니다.
25초 후 마감25 s < 30 s → 0남은 시간이 요구된 30초보다 짧으면 계약에 따라 중단하거나 연기합니다. 마감에 맞추려고 대기를 줄이지 않습니다.
최대 예산20 × (1 + 3) = 80모든 시도를 사용하면 최초 요청 20개와 재시도 60개로 총 80개입니다. 상한이 있어도 성공이나 안전한 반복은 보장되지 않습니다.

검증할 가상 변형 사례

Retry-After에 초 대신 HTTP 날짜가 들어 있다.

문서에 정한 형식을 해석하고 시계를 확인하세요. 계산한 대기 시간을 기록하고 날짜를 임의 지연으로 바꾸지 마세요.

각 워커가 별도 재시도 예산을 가진다.

합산 부하도 계산하세요. 공유 할당량을 조정하고 재시도를 분산해 동시 폭주가 반복되지 않게 하세요.

업무상 효과가 있는 작업 후 응답이 없다.

재실행 전에 기준 상태와 멱등성 계약을 확인하세요. 시간 초과가 실행되지 않았다는 증거는 아닙니다.

보관할 증거

  • 받은 헤더, 대기 형식, 사용한 시계.
  • 총 시도 예산과 최대 지속 시간.
  • 작업 식별자와 대조한 결과.

추가 참고 자료 : IETF — RFC 9110, Retry-After [EN]

검증 절차

  1. 할당 범위 및 재시도 예산을 기록합니다.
  2. 허가된 시험에서만 할당량을 소진합니다.
  3. 429, Retry-After 및 제한된 시간선을 보존합니다. 기술적 제한과 업무 결과를 구분하세요. 할당량 소진을 재고 0이라는 응답으로 바꾸면 안 됩니다.
  4. 외부 부하 없는 모의 환경에서 네 계층 각 세 총호출을 셉니다.
  5. 가상 큐 작업을 만료시켜 새 작업이 시작되지 않는지 확인합니다.
  6. 모의 실패 뒤 허가한 작업을 점진 복구하고 호출, 기한과 고유 결과를 보존합니다.

AWS — Timeouts, retries, and backoff with jitter

API: 계층 간 재시도 증폭 방지

앱, SDK, 프록시와 서비스가 같은 호출을 재시도할 수 있습니다. 가상 네 계층에서 각 세 번의 총시도를 하면 실패한 의존성에 최대81번 호출합니다. 기존 할당 관리에 공유 예산과 유효 기한을 추가합니다.

가상 예시

예시 상황

할당 범위, 헤더, 대기, 재시도 예산을 기록하고 통제된 소진을 시험하세요.

결정 및 예상 증거

아닙니다. 응답이 사라진 작업은 별도로 대조해야 하며 다른 시도의 응답으로 그 상태를 판단하면 안 됩니다.

관리 지표

지표측정 대상첫 번째 조치
작업당 시도 수같은 논리 작업에 보낸 시도 수예산을 조정하고 반복 중단
대기열 나이작업 수락 후 대기 시간기한 초과 작업 취소 또는 상위 처리
호출 증폭의존성 호출 / 같은 기간의 초기 업무 작업총시도, 재시도와 계획된 하위 호출 구분
수용한 만료 작업유효 기한 후 시작한 작업큐, 취소와 시작된 효과도 관찰

일반적인 실수

  • 동시 재시도가 과부하를 악화할 수 있습니다.

자주 묻는 질문

429가 이전 쓰기 미실행을 증명하나요?

아닙니다. 응답이 사라진 작업은 별도로 대조해야 하며 다른 시도의 응답으로 그 상태를 판단하면 안 됩니다.

각 계층 세 번이면 전체 세 번인가요?

아닙니다. 가상 네 계층에서 세 번씩이면 마지막 의존성에 최대3⁴ = 81번 호출합니다.

만료가 원격 효과를 취소하나요?

꼭 그렇지 않습니다. 새 무용한 작업을 막고 시작된 원격 작업은 상태 확인과 가능한 보상이 필요합니다.

Retry-After: 대기, 예산 및 재시도 결정

이 언어판의 상세 참고 설명은 영어로 제공됩니다.

Decide whether to retry after 429 or 503

A waiting period answers “when?”, not “may this operation be repeated?”. Before retrying, identify the intended effect, read the provider contract and bound total work. An error status or a lost response does not prove that no earlier attempt produced an effect.

Local teaching model with no request, timer, storage or real write. It considers one decision after 429 or 503 using six predefined headers. Dates are read at the fictional instant 22 October 2026, 10:00:00 UTC, assuming an accurate clock. This is neither a complete HTTP parser nor a Stripe client. Obsolete HTTP-date forms, clock skew, transport and SDK-specific policies are outside the calculation.

사람이 없는 가상의 네트워크 실험실. 호박색 조명의 어두운 작업대 위에 장비가 놓여 있다. AI로 생성한 편집용 일러스트
Generated, people-free conceptual network laboratory from the editorial collection. It depicts neither real infrastructure nor a throughput test.

Twelve ways to read Retry-After

Durations are seconds. Absolute dates need an explicit clock policy; calculations here assume the stated accurate clock. Past dates become zero in this model without permitting an immediate loop. Integer syntax alone does not define a client’s numeric limits.

Twelve ways to read Retry-After
Illustrative valueReading within this scopeInterpretation decision
30Non-negative decimal integer: wait 30 seconds after receipt.This means seconds, not 30 milliseconds.
0005The 1*DIGIT syntax accepts these digits: 5 seconds.Do not treat the leading zero as octal.
0A declared delay of zero seconds.Local policy, budgets and permission to repeat still require checking.
Thu, 22 Oct 2026 10:00:45 GMTAn HTTP date 45 seconds after the fictional receipt time.Clock uncertainty must not be silently treated as certainty.
Thu, 22 Oct 2026 09:59:50 GMTA date 10 seconds in the past; the model uses zero server wait.A past date requires neither negative waiting nor unlimited replay.
Field absentNo server wait is supplied.This model uses its selected local delay, not a normative default.
1.51.5 does not meet integer delay-seconds syntax.Do not silently round it and call the field valid.
-1-1 is not a non-negative decimal integer for this field.Do not interpret it as a special permission.
30sThe s unit suffix is not part of delay-seconds syntax.Seconds are already implied; 30s is not the form 30.
30, 60Two comma-separated durations are not one valid Retry-After value.Do not split every comma: a valid HTTP date itself contains one.
Empty valueThe field exists but contains neither expected form.Keep absent and malformed values distinct in records.
9999999999999999999999The digit string meets integer syntax but exceeds this model’s numeric bounds.Record the local limit without claiming the RFC sets it; never truncate to retry sooner.

Compare waiting, remaining budget and duplicate risk

Five parameters cover 144 combinations. Fictional policy: wait for the greater of an interpretable server delay and the already selected local delay, then reserve 10 seconds for one attempt. If the remaining budget is insufficient, stop this interactive retry without shortening the server wait. The reserve is not a measured duration and the selected local delay is not a jitter generator.

Teaching decision : Retry candidate

The selected operation type and budget allow considering a retry in this model. This proves neither success nor authorisation on a real service.

Interpretable server wait
30 s
Selected wait
30 s
Attempt reserve
10 s
Wait + reserve
40 s
Budget margin
20 s

Eight reproducible cases

Eight reproducible cases
Fictional situationRelevant parametersDecision and limit
429, read and 30-second wait429 · 30 seconds

Conforming GET read

Remaining budget after receipt : 60 s
Already selected local delay : 5 s

Retry candidate

With 60 seconds remaining, 30 + 10 leaves a 20-second margin.

Waiting exceeds the budget429 · 30 seconds

Conforming GET read

Remaining budget after receipt : 20 s
Already selected local delay : 5 s

Stop this retry

With 20 seconds remaining, do not shorten 30 just to force an attempt.

Write with unknown contract503 · Future date: +45 seconds

POST write: retry contract unverified

Remaining budget after receipt : 60 s
Already selected local delay : 5 s

Check business state

Even positive margin does not validate repeating POST.

Write with verified contract503 · Future date: +45 seconds

POST write: retry contract verified

Remaining budget after receipt : 60 s
Already selected local delay : 5 s

Retry candidate

Verified contract is an assumption, not a test of your provider.

Invalid fractional value503 · Invalid value: 1.5

Conforming GET read

Remaining budget after receipt : 20 s
Already selected local delay : 5 s

Retry candidate

The five-second fallback is a local teaching choice; retain the parse error.

Absent field, long local delay429 · Field absent

Conforming GET read

Remaining budget after receipt : 60 s
Already selected local delay : 40 s

Retry candidate

The 40-second delay comes from the client rather than the server.

HTTP date already passed503 · Past date: −10 seconds

Conforming GET read

Remaining budget after receipt : 20 s
Already selected local delay : 5 s

Retry candidate

The model retains a five-second local delay; the past date triggers no immediate call.

Zero does not remove the budget429 · 0 seconds

Conforming GET read

Remaining budget after receipt : 20 s
Already selected local delay : 40 s

Stop this retry

The 40-second local delay plus reserve exceed the 20 seconds remaining.

Five distinctions that change client behaviour

Five distinctions that change client behaviour
Reference pointDocumented meaningPractical limit
429RFC 6585 describes too many requests within a period. Retry-After may be present; a 429 response must not be stored by a cache.The RFC does not set the provider’s counted identity, window or algorithm.
503Retry-After can indicate the expected duration of service unavailability.A 5xx alone does not establish whether a write can be replayed.
HTTP idempotencePUT, DELETE and safe methods are idempotent in their intended effect.Responses and logs may differ. Controlled POST retries need an additional contract.
Retries at multiple layersClient, SDK and proxy attempts can multiply load.In a fictional three-layer example with three total attempts at each layer, one request can generate up to 3 × 3 × 3 = 27 calls at the last layer.
Jitter and budgetAWS describes spreading retries to avoid synchronised clients.Randomness makes no write idempotent and replaces neither a deadline nor an attempt limit.

Five items for retry acceptance evidence

  • Method, route, contract version and logical operation identity; keep secrets out of keys and logs.
  • Status, raw field, receipt time, interpretation and clock assumption.
  • Selected delay, current attempt, remaining budget and the layer actually controlling retries.
  • Known or unknown business state, retry key, associated context and parameters, and reconciliation evidence when needed.
  • Verified final outcome and user behaviour: understandable waiting, retained input and no button that unintentionally recreates an operation.

Compare idempotency contracts →

Primary sources and limits

The RFCs define the cited HTTP elements. AWS describes design choices and Stripe documents its own APIs. Budgets, local waits, cases and diagrams are educational: they neither measure your service nor execute requests.

References reviewed

GraphQL: 오류, 목록 및 부분 데이터

이 언어판의 상세 참고 설명은 영어로 제공됩니다.

GraphQL cost and partial results: two separate checks

An authorized query can still be too costly; a partial response measures none of its resource consumption.

  • Compare absent data, partial data and data: null.
  • Keep the original path even when a parent becomes null.
  • Test permissions, quotas and interface states separately.

Explore GraphQL responses and nullability →

GraphQL Specification · September 2025 · Published edition · September 2025

공식 참조

참조는 방법을 뒷받침합니다. 상황에 맞게 검사를 조정하십시오. 이는 인증이 아닙니다. 원본 참조 제목 및 소스 문서는 다른 언어로 작성되었을 수 있습니다.

참고 자료 확인일 .