שימוש ב-gRPC עם Certificate Authority Service
אם אתם משתמשים בספריות gRPC שנוצרו באופן ידני כדי לבצע קריאות ל-API של Certificate Authority Service, אתם צריכים להוסיף את x-goog-request-params: '<request-field>:<resource-name>' ככותרת. שימוש נכון ב-x-goog-request-params מבטיח שהבקשה תנותב לאזור המתאים למשאבי שירות ה-CA שלכם.
בהמשך מופיעות כמה דוגמאות לשיטות עם שדה הבקשה וכותרת לדוגמה.
|
Method: CreateCertificateAuthority Request field: CreateCertificateAuthority.parent x-goog-request-params: 'parent: projects/PROJECT_ID/locations/LOCATION_ID' |
|
Method: GetCertificateAuthority Request field: GetCertificateAuthority.name x-goog-request-params: 'name: projects/PROJECT_ID/locations/LOCATION_ID/certificateAuthorities/CA_NAME' |
|
שיטה: UpdateCertificateAuthority שדה בקשה: UpdateCertificateAuthority.certificate_authority.name x-goog-request-params: 'CertificateAuthority.name: projects/PROJECT_ID/locations/LOCATION_ID/certificateAuthorities/CA_NAME' |
רשימה מלאה של רכיבי ה-method של RPC ושדות הבקשה שלהם מופיעה בחבילה google.cloud.security.privateca.v1beta1.