Di Apigee hybrid, tugas utama Synchronizer adalah melakukan polling dan mendownload kontrak runtime
yang disediakan oleh platform pengelolaan. Informasi yang dikomunikasikan melalui kontrak mencakup proxy API, produk API, cache, dan host virtual.
Instance sinkronisasi yang berjalan di platform runtime diharapkan untuk melakukan polling pada platform manajemen
secara berkala, mendownload kontrak, dan menyediakannya untuk instance runtime lokal.
Satu Synchronizer dapat mendukung banyak Message Processor yang di-deploy di pod yang sama.
Mengaktifkan akses Synchronizer
Anda harus memberikan izin Synchronizer untuk mengambil
artefak Apigee, seperti paket proxy dan resource dari platform pengelolaan. Anda harus memanggil
Apigee API untuk memberi Synchronizer otorisasi guna menarik artefak dari platform pengelolaan ke
platform runtime.
Pastikan Anda telah mengaktifkan Apigee API seperti yang dijelaskan dalam langkah-langkah penyiapan GCP.
Untuk mengetahui detailnya, lihat Langkah 3: Aktifkan API.
Temukan kunci akun layanan GCP yang mengaktifkan operasi tulis (file JSON) yang Anda download sebagai bagian dari Membuat akun layanan. Akun layanan memiliki peran Apigee Org Admin dan diberi nama "apigee-org-admin". Jika sebelumnya Anda belum membuat akun layanan ini, Anda harus melakukannya sebelum melanjutkan.
Tetapkan variabel lingkungan GOOGLE_APPLICATION_CREDENTIALS ke jalur tempat
kunci akun layanan berada:
synchronizer-manager-service-account-name: Nama akun layanan dengan peran Apigee Synchronizer Manager. Nama dibuat seperti alamat email. Misalnya:
my-synchronizer-manager-service_account@my_project_id.
[[["Mudah dipahami","easyToUnderstand","thumb-up"],["Memecahkan masalah saya","solvedMyProblem","thumb-up"],["Lainnya","otherUp","thumb-up"]],[["Sulit dipahami","hardToUnderstand","thumb-down"],["Informasi atau kode contoh salah","incorrectInformationOrSampleCode","thumb-down"],["Informasi/contoh yang saya butuhkan tidak ada","missingTheInformationSamplesINeed","thumb-down"],["Masalah terjemahan","translationIssue","thumb-down"],["Lainnya","otherDown","thumb-down"]],["Terakhir diperbarui pada 2025-09-04 UTC."],[[["\u003cp\u003eThis documentation pertains to version 1.3 of Apigee hybrid, which is no longer supported and should be upgraded.\u003c/p\u003e\n"],["\u003cp\u003eThe Synchronizer polls and downloads runtime contracts from the management plane, including API proxies, products, caches, and virtual hosts.\u003c/p\u003e\n"],["\u003cp\u003eSynchronizers, operating within the runtime plane, regularly fetch and provide contracts to local runtime instances, with each Synchronizer able to support multiple Message Processors.\u003c/p\u003e\n"],["\u003cp\u003eGranting the Synchronizer access requires using the \u003ccode\u003esetSyncAuthorization\u003c/code\u003e API, which ensures the designated service account, specifically the one with the \u003cstrong\u003eApigee Synchronizer Manager\u003c/strong\u003e role, is authorized.\u003c/p\u003e\n"],["\u003cp\u003eYou can verify the authorization of a service account using the \u003ccode\u003egetSyncAuthorization\u003c/code\u003e API.\u003c/p\u003e\n"]]],[],null,["# Configure the Synchronizer\n\n| You are currently viewing version 1.3 of the Apigee hybrid documentation. **This version is end of life.** You should upgrade to a newer version. For more information, see [Supported versions](/apigee/docs/hybrid/supported-platforms#supported-versions).\n\nThis section describes the Synchronizer.\n\nSynchronizer overview\n---------------------\n\nIn Apigee hybrid, the Synchronizer's primary job is to poll and download the runtime contracts\nwhich are supplied by the management plane. Information communicated by contract includes API\nproxies, API products, caches, and virtual hosts.\n\nSynchronizer instances running in the runtime-plane are expected to poll the management\nplane on a regular basis, download the contracts and make the same available to local runtime\ninstances.\n\nOne Synchronizer can support many Message Processors deployed in the same pod.\n\nEnable Synchronizer access\n--------------------------\n\nYou must grant the [Synchronizer](/apigee/docs/hybrid/v1.3/what-is-hybrid#synchronizer) permission to pull down\nApigee artifacts, such as proxy bundles and resources from the management plane. You must call an\nApigee API to authorize the Synchronizer to pull artifacts down from the management plane to the\nruntime plane.\n\n1. Ensure that you have enabled the Apigee API as explained in the GCP setup steps. For details, see [Step 3: Enable APIs](/apigee/docs/hybrid/v1.3/precog-enableapi).\n2. Locate the **write-enabled GCP service account key** (a JSON file) that you downloaded as part of [Create service accounts](/apigee/docs/hybrid/v1.3/install-download-install#create-service-accounts). The service account has the **Apigee Org Admin** role and is the one named \"apigee-org-admin\". If you did not previously create this service account, you must do so before continuing.\n3. Set the `GOOGLE_APPLICATION_CREDENTIALS` environment variable to the path where the\n service account key is located:\n\n export GOOGLE_APPLICATION_CREDENTIALS=\u003cvar translate=\"no\"\u003eyour_sa_credentials_file\u003c/var\u003e.json\n\n 4. Call the [setSyncAuthorization](/apigee/docs/hybrid/v1.3/syncauthorization-reference) API to enable the required permissions for Synchronizer: **IMPORTANT:** Be sure that the service account name that you add to this API has the role **Apigee Synchronizer Manager** . See also [Create service accounts](/apigee/docs/hybrid/v1.3/install-download-install#create-service-accounts). \n\n ```\n curl -X POST -H \"Authorization: Bearer $(gcloud auth application-default print-access-token)\" \\\n -H \"Content-Type:application/json\" \\\n \"https://apigee.googleapis.com/v1/organizations/your_org_name:setSyncAuthorization\" \\\n -d '{\"identities\":[\"serviceAccount:synchronizer-manager-service-account-name\"]}'\n ```\n\n Where:\n - `your_org_name`: The name of the hybrid organization.\n - `synchronizer-manager-service-account-name`: The name of a service account with the **Apigee Synchronizer Manager** role. The name is formed like an email address. For example: `my-synchronizer-manager-service_account@my_project_id.iam.gserviceaccount.com`\n\n Example: \n\n ```\n curl -X POST -H \"Authorization: Bearer $(gcloud auth application-default print-access-token)\" \\\n -H \"Content-Type:application/json\" \\\n \"https://apigee.googleapis.com/v1/organizations/my_org:setSyncAuthorization\" \\\n -d '{\"identities\":[\"serviceAccount:my-synchronizer-manager-service_account@my_project_id.iam.gserviceaccount.com\"]}'\n ```\n\n For more information on this API, see [SyncAuthorization\n API](/apigee/docs/hybrid/v1.3/syncauthorization-reference).\n5. To verify that the service account was set, call the following API to get a list of service accounts: \n\n ```\n curl -X POST -H \"Authorization: Bearer $(gcloud auth application-default print-access-token)\" \\\n -H \"Content-Type:application/json\" \\\n \"https://apigee.googleapis.com/v1/organizations/your_org_name:getSyncAuthorization\" \\\n -d ''\n ```\n\n The output looks similar to the following: \n\n ```\n {\n \"identities\":[\n \"serviceAccount:my-synchronizer-manager-service_account@my_project_id.iam.gserviceaccount.com\"\n ],\n \"etag\":\"BwWJgyS8I4w=\"\n }\n ```"]]