본문으로 바로가기 본문 바로가기
WIKI 기술 지식 베이스

사전 함수 정책 구성 참조

원문 보기 위키 갱신

사전 함수 정책 구성 참조 (Pre-Function Policy Configuration Reference)

이 문서는 Kong AI Gateway의 Pre-Function 정책에서 설정할 수 있는 구성 옵션을 JSON 스키마 형태로 보여주는 참조 자료예요. Pre-Function 정책은 요청 처리 흐름의 여러 페이즈에서 사용자 지정 Lua 코드를 실행할 수 있게 해주는 정책이에요. header_filter나 access 같은 일반 페이즈와 ws_handshake 같은 WebSocket 페이즈별로 실행할 코드를 배열 형태로 지정하는 구조라는 점을 참고하세요

출처: 문서

본문

{
  "properties": {
    "config": {
      "type": "object",
      "properties": {
        "header_filter": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "body_filter": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "ws_close": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "certificate": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "rewrite": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "log": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "ws_handshake": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "ws_client_frame": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "ws_upstream_frame": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        },
        "access": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "default": []
        }
      }
    }
  }
}

관련 리소스

더 알아보기 (Learn more)

  • Pre-Function과 짝을 이루어 응답 이후 페이즈에서 코드를 실행하는 정책을 소개해요 — Post-function Policy
  • Pre-Function이 속한 서버리스 계열 정책들을 한눈에 살펴볼 수 있어요 — Serverless Policies