Search in sources :

Example 1 with KeyManagementServiceSettings

use of com.google.cloud.kms.v1.KeyManagementServiceSettings in project gapic-generator-java by googleapis.

the class SyncCreateSetEndpoint method syncCreateSetEndpoint.

public static void syncCreateSetEndpoint() throws Exception {
    // This snippet has been automatically generated for illustrative purposes only.
    // It may require modifications to work in your environment.
    KeyManagementServiceSettings keyManagementServiceSettings = KeyManagementServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
    KeyManagementServiceClient keyManagementServiceClient = KeyManagementServiceClient.create(keyManagementServiceSettings);
}
Also used : KeyManagementServiceSettings(com.google.cloud.kms.v1.KeyManagementServiceSettings) KeyManagementServiceClient(com.google.cloud.kms.v1.KeyManagementServiceClient)

Example 2 with KeyManagementServiceSettings

use of com.google.cloud.kms.v1.KeyManagementServiceSettings in project gapic-generator-java by googleapis.

the class SyncCreateSetCredentialsProvider method syncCreateSetCredentialsProvider.

public static void syncCreateSetCredentialsProvider() throws Exception {
    // This snippet has been automatically generated for illustrative purposes only.
    // It may require modifications to work in your environment.
    KeyManagementServiceSettings keyManagementServiceSettings = KeyManagementServiceSettings.newBuilder().setCredentialsProvider(FixedCredentialsProvider.create(myCredentials)).build();
    KeyManagementServiceClient keyManagementServiceClient = KeyManagementServiceClient.create(keyManagementServiceSettings);
}
Also used : KeyManagementServiceSettings(com.google.cloud.kms.v1.KeyManagementServiceSettings) KeyManagementServiceClient(com.google.cloud.kms.v1.KeyManagementServiceClient)

Example 3 with KeyManagementServiceSettings

use of com.google.cloud.kms.v1.KeyManagementServiceSettings in project gapic-generator-java by googleapis.

the class SyncGetKeyRing method syncGetKeyRing.

public static void syncGetKeyRing() throws Exception {
    // This snippet has been automatically generated for illustrative purposes only.
    // It may require modifications to work in your environment.
    KeyManagementServiceSettings.Builder keyManagementServiceSettingsBuilder = KeyManagementServiceSettings.newBuilder();
    keyManagementServiceSettingsBuilder.getKeyRingSettings().setRetrySettings(keyManagementServiceSettingsBuilder.getKeyRingSettings().getRetrySettings().toBuilder().setTotalTimeout(Duration.ofSeconds(30)).build());
    KeyManagementServiceSettings keyManagementServiceSettings = keyManagementServiceSettingsBuilder.build();
}
Also used : KeyManagementServiceSettings(com.google.cloud.kms.v1.KeyManagementServiceSettings)

Example 4 with KeyManagementServiceSettings

use of com.google.cloud.kms.v1.KeyManagementServiceSettings in project gapic-generator-java by googleapis.

the class SyncGetKeyRing method syncGetKeyRing.

public static void syncGetKeyRing() throws Exception {
    // This snippet has been automatically generated for illustrative purposes only.
    // It may require modifications to work in your environment.
    KeyManagementServiceStubSettings.Builder keyManagementServiceSettingsBuilder = KeyManagementServiceStubSettings.newBuilder();
    keyManagementServiceSettingsBuilder.getKeyRingSettings().setRetrySettings(keyManagementServiceSettingsBuilder.getKeyRingSettings().getRetrySettings().toBuilder().setTotalTimeout(Duration.ofSeconds(30)).build());
    KeyManagementServiceStubSettings keyManagementServiceSettings = keyManagementServiceSettingsBuilder.build();
}
Also used : KeyManagementServiceStubSettings(com.google.cloud.kms.v1.stub.KeyManagementServiceStubSettings)

Aggregations

KeyManagementServiceSettings (com.google.cloud.kms.v1.KeyManagementServiceSettings)3 KeyManagementServiceClient (com.google.cloud.kms.v1.KeyManagementServiceClient)2 KeyManagementServiceStubSettings (com.google.cloud.kms.v1.stub.KeyManagementServiceStubSettings)1