turcsanyip commented on a change in pull request #5486: URL: https://github.com/apache/nifi/pull/5486#discussion_r739538440
########## File path: nifi-nar-bundles/nifi-azure-bundle/nifi-azure-processors/src/main/java/org/apache/nifi/services/azure/storage/AzureStorageCredentialsControllerService_v12.java ########## @@ -0,0 +1,151 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.nifi.services.azure.storage; + +import org.apache.nifi.annotation.documentation.CapabilityDescription; +import org.apache.nifi.annotation.documentation.Tags; +import org.apache.nifi.annotation.lifecycle.OnEnabled; +import org.apache.nifi.components.PropertyDescriptor; +import org.apache.nifi.controller.AbstractControllerService; +import org.apache.nifi.controller.ConfigurationContext; +import org.apache.nifi.expression.ExpressionLanguageScope; +import org.apache.nifi.processors.azure.storage.utils.AzureStorageUtils; + +import java.util.Arrays; +import java.util.Collections; +import java.util.List; + +/** + * Provides credentials details for Azure Blob processors + * + * @see AbstractControllerService + */ +@Tags({"azure", "microsoft", "cloud", "storage", "blob", "credentials"}) +@CapabilityDescription("Provides credentials for Azure Blob processors using Azure Blob Storage client library v12.") +public class AzureStorageCredentialsControllerService_v12 extends AbstractControllerService implements AzureStorageCredentialsService_v12 { + + public static final String DEFAULT_ENDPOINT_SUFFIX = "blob.core.windows.net"; + + public static final PropertyDescriptor ACCOUNT_NAME = new PropertyDescriptor.Builder() + .fromPropertyDescriptor(AzureStorageUtils.ACCOUNT_NAME) + .description(AzureStorageUtils.ACCOUNT_NAME_BASE_DESCRIPTION) + .required(true) + .expressionLanguageSupported(ExpressionLanguageScope.NONE) + .build(); + + public static final PropertyDescriptor ENDPOINT_SUFFIX = new PropertyDescriptor.Builder() + .fromPropertyDescriptor(AzureStorageUtils.ENDPOINT_SUFFIX) + .displayName("Endpoint Suffix") + .description("Storage accounts in public Azure always use a common FQDN suffix. " + + "Override this endpoint suffix with a different suffix in certain circumstances (like Azure Stack or non-public Azure regions).") + .required(true) + .defaultValue(DEFAULT_ENDPOINT_SUFFIX) + .expressionLanguageSupported(ExpressionLanguageScope.NONE) + .build(); + + public static final PropertyDescriptor CREDENTIALS_TYPE = new PropertyDescriptor.Builder() + .name("credentials-type") + .displayName("Credentials Type") + .description("Credentials type to be used for authenticating to Azure") + .required(true) + .allowableValues(AzureStorageCredentialsType.getAllowableValues()) + .defaultValue(AzureStorageCredentialsType.ACCOUNT_KEY.name()) Review comment: I would vote for SAS Token and have set it. Managed Identity is a more specific case when NiFi is running on an Azure VM. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@nifi.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org