您可以使用 Wasm 和 Proxy-Wasm ABI 构建插件。Proxy-Wasm ABI 支持 Rust、C++ 和 Go。
Service Extensions 插件在完全无服务器的 Google 管理的基础架构上运行。它们靠近数据平面运行,并且会对延迟优化进行管理。
Service Extensions 插件适用于对 CPU 和内存有严格限制的轻量级应用场景。您可以通过边缘扩展程序将 Service Extensions 插件附加到全球外部应用负载均衡器。
[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["很难理解","hardToUnderstand","thumb-down"],["信息或示例代码不正确","incorrectInformationOrSampleCode","thumb-down"],["没有我需要的信息/示例","missingTheInformationSamplesINeed","thumb-down"],["翻译问题","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-09-05。"],[],[],null,["# Use Service Extensions for edge compute\n\n| **Preview**\n|\n|\n| This product or feature is subject to the \"Pre-GA Offerings Terms\" in the General Service Terms section\n| of the [Service Specific Terms](/terms/service-terms#1).\n|\n| Pre-GA products and features are available \"as is\" and might have limited support.\n|\n| For more information, see the\n| [launch stage descriptions](/products#product-launch-stages).\n\nYou can use [Service Extensions](/service-extensions/docs/overview)\nto run your own [WebAssembly (Wasm)](https://webassembly.org/) code in a\nfully serverless, Google-managed compute environment. This page describes\nextensibility by using Service Extensions.\n\nAbout Service Extensions edge extensions for Cloud CDN\n------------------------------------------------------\n\nYou build plugins using Wasm and the [Proxy-Wasm ABI](https://github.com/proxy-wasm).\nThe Proxy-Wasm ABI offers support for Rust, C++, and Go.\n[Service Extensions plugins](/service-extensions/docs/plugins-overview)\nrun on a fully serverless, Google-managed infrastructure. They run close to the\ndata plane, and latency optimization is managed.\nService Extensions plugins are intended for lightweight use\ncases with tight limits on CPU and memory. You attach a\nService Extensions plugin to a global external Application Load Balancer\nthrough an edge extension.\n\nFor more information, see\n[How edge extensions work](/service-extensions/docs/lb-extensions-overview#edge-extensions).\n\nCommon use cases\n----------------\n\nUse Service Extensions plugins with global external Application Load Balancers in\nthe following sample scenarios:\n\n**Custom traffic steering**\n: Manipulate request headers to influence backend service selection.\n\n**Cache optimization**\n: Influence which content is served from a Cloud CDN cache.\n\n**Exception handling**\n: Redirect clients to a custom error page for certain response classes.\n\n**Custom logging**\n: Log user-defined headers or custom data into Cloud Logging.\n\n**Header addition**\n: Create new headers relevant for your applications or specific customers.\n: Insert new headers for request.\n\n**Header manipulation**\n: Rewrite existing request headers or override client headers on their way\n to the backend.\n\n**Security**\n: Write custom security policies based on client requests and make enforcement\n decisions within your plugin.\n\nGet started\n-----------\n\n1. [Create a plugin](/service-extensions/docs/create-plugin)\n2. [Configure an edge extension](/service-extensions/docs/configure-edge-extensions)\n\nWhat's next\n-----------\n\n- Learn more about [Service Extensions](/service-extensions/docs/overview) concepts.\n- View Rust, Go, and C++ plugin examples and testing tools in the [Service Extensions GitHub repository for plugins](https://github.com/GoogleCloudPlatform/service-extensions/tree/main/plugins#docs).\n- Learn how to [prepare and upload the files required](/service-extensions/docs/access-control) to create plugins by using Service Extensions.\n- Learn how to [create a plugin](/service-extensions/docs/create-plugin).\n- Learn how to [configure an edge extension](/service-extensions/docs/configure-edge-extensions)."]]