שימוש ב-gRPC עם Cloud KMS

אם אתם משתמשים בספריות gRPC שנוצרו באופן ידני כדי לבצע קריאות ל-Cloud Key Management Service, אתם צריכים לציין ערך x-google-request-params במטא-נתונים או בכותרת של הקריאה. שימוש נכון ב-x-google-request-params ינתב את הקריאה לאזור המתאים למשאבי Cloud KMS.

מגדירים את הערך x-google-request-params לשדה בבקשה של השיטה, כמו שמוצג בטבלה הבאה.

‏Method שדה בקשה
AsymmetricDecrypt AsymmetricDecryptRequest.name
AsymmetricSign AsymmetricSignRequest.name
CreateCryptoKey CreateCryptoKeyRequest.parent
CreateCryptoKeyVersion CreateCryptoKeyVersionRequest.parent
CreateImportJob CreateImportJobRequest.parent
CreateKeyRing CreateKeyRingRequest.parent
פענוח DecryptRequest.name
DestroyCryptoKeyVersion DestroyCryptoKeyVersionRequest.name