Middleware - CI/CD用語集の定義
middleware は、横断的な関心事を管理するためにリクエスト handler の周りを走るパイプラインのコードです。
middleware は、メインの handler の前後でリクエストパイプライン内を走るコードで、auth、logging、CORS といった関心事を扱います。CI テストは、認証されていないリクエストを拒否するといった middleware の振る舞いを検証します。
middleware のチェーンは auth、パース、logging を扱うため、handler は本来の処理に集中できます。テストは、たとえば token が欠けているときに auth の middleware が 401 を返すことを検証します。
関連ガイド
Route - CI/CD Glossary DefinitionRoute: A route is the rule that maps an incoming request path and method to the handler that serves it. Routi…
CORS - CI/CD Glossary DefinitionCORS: CORS (Cross-Origin Resource Sharing) is a browser mechanism that uses HTTP headers to let a server decl…
Status Code - CI/CD Glossary DefinitionStatus Code: A status code is the three-digit HTTP number in a response that signals the result: 2xx success,…