fgerlits commented on code in PR #1589:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1589#discussion_r1247998877


##########
extensions/aws/processors/S3Processor.h:
##########
@@ -83,23 +90,67 @@ struct CommonProperties {
 
 class S3Processor : public core::Processor {
  public:
-  static const std::set<std::string> REGIONS;
-
-  EXTENSIONAPI static const core::Property Bucket;
-  EXTENSIONAPI static const core::Property AccessKey;
-  EXTENSIONAPI static const core::Property SecretKey;
-  EXTENSIONAPI static const core::Property CredentialsFile;
-  EXTENSIONAPI static const core::Property AWSCredentialsProviderService;
-  EXTENSIONAPI static const core::Property Region;
-  EXTENSIONAPI static const core::Property CommunicationsTimeout;
-  EXTENSIONAPI static const core::Property EndpointOverrideURL;
-  EXTENSIONAPI static const core::Property ProxyHost;
-  EXTENSIONAPI static const core::Property ProxyPort;
-  EXTENSIONAPI static const core::Property ProxyUsername;
-  EXTENSIONAPI static const core::Property ProxyPassword;
-  EXTENSIONAPI static const core::Property UseDefaultCredentials;
-  static auto properties() {
-    return std::array{
+  EXTENSIONAPI static constexpr auto Bucket = 
core::PropertyDefinitionBuilder<>::createProperty("Bucket")
+      .withDescription("The S3 bucket")
+      .isRequired(true)
+      .supportsExpressionLanguage(true)
+      .build();
+  EXTENSIONAPI static constexpr auto AccessKey = 
core::PropertyDefinitionBuilder<>::createProperty("Access Key")
+      .withDescription("AWS account access key")
+      .supportsExpressionLanguage(true)
+      .build();
+  EXTENSIONAPI static constexpr auto SecretKey = 
core::PropertyDefinitionBuilder<>::createProperty("Secret Key")
+      .withDescription("AWS account secret key")
+      .supportsExpressionLanguage(true)
+      .build();
+  EXTENSIONAPI static constexpr auto CredentialsFile = 
core::PropertyDefinitionBuilder<>::createProperty("Credentials File")
+      .withDescription("Path to a file containing AWS access key and secret 
key in properties file format. Properties used: accessKey and secretKey")
+      .build();
+  EXTENSIONAPI static constexpr auto AWSCredentialsProviderService = 
core::PropertyDefinitionBuilder<>::createProperty("AWS Credentials Provider 
service")
+      .withDescription("The name of the AWS Credentials Provider controller 
service that is used to obtain AWS credentials.")
+      .build();
+  EXTENSIONAPI static constexpr auto Region = 
core::PropertyDefinitionBuilder<region::REGIONS.size()>::createProperty("Region")
+      .isRequired(true)
+      .withDefaultValue(region::US_WEST_2)
+      .withAllowedValues(region::REGIONS)
+      .withDescription("AWS Region")
+      .build();
+  EXTENSIONAPI static constexpr auto CommunicationsTimeout = 
core::PropertyDefinitionBuilder<>::createProperty("Communications Timeout")
+      .isRequired(true)
+      .withPropertyType(core::StandardPropertyTypes::TIME_PERIOD_TYPE)
+      .withDefaultValue("30 sec")
+      .withDescription("Sets the timeout of the communication between the AWS 
server and the client")
+      .build();
+  EXTENSIONAPI static constexpr auto EndpointOverrideURL = 
core::PropertyDefinitionBuilder<>::createProperty("Endpoint Override URL")
+      .withDescription("Endpoint URL to use instead of the AWS default 
including scheme, host, "
+          "port, and path. The AWS libraries select an endpoint URL based on 
the AWS "
+          "region, but this property overrides the selected endpoint URL, 
allowing use "
+          "with other S3-compatible endpoints.")
+      .supportsExpressionLanguage(true)
+      .build();
+  EXTENSIONAPI static constexpr auto ProxyHost = 
core::PropertyDefinitionBuilder<>::createProperty("Proxy Host")
+      .withDescription("Proxy host name or IP")
+      .supportsExpressionLanguage(true)
+      .build();
+  EXTENSIONAPI static constexpr auto ProxyPort = 
core::PropertyDefinitionBuilder<>::createProperty("Proxy Port")
+      .withDescription("The port number of the proxy host")
+      .supportsExpressionLanguage(true)
+      .build();
+  EXTENSIONAPI static constexpr auto ProxyUsername =   
core::PropertyDefinitionBuilder<>::createProperty("Proxy Username")

Review Comment:
   fixed in bde74b220d3a6755b91e5104648b0a2b0f57fafc (also the other `=  ` 
issues below)



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to