mattyb149 commented on a change in pull request #5843:
URL: https://github.com/apache/nifi/pull/5843#discussion_r820895364
##########
File path:
nifi-nar-bundles/nifi-standard-services/nifi-dbcp-service-bundle/nifi-dbcp-service/src/main/java/org/apache/nifi/dbcp/DBCPConnectionPool.java
##########
@@ -398,6 +405,75 @@ protected PropertyDescriptor
getSupportedDynamicPropertyDescriptor(final String
return results;
}
+ @Override
+ public List<ConfigVerificationResult> verify(final ConfigurationContext
context, final ComponentLog verificationLogger, final Map<String, String>
variables) {
+ List<ConfigVerificationResult> results = new ArrayList<>();
+
+ KerberosUser kerberosUser = null;
+ try {
+ kerberosUser = getKerberosUser(context, Collections.emptyMap());
+ if (kerberosUser != null) {
+ results.add(new ConfigVerificationResult.Builder()
+ .verificationStepName("Configure Kerberos User")
+ .outcome(SUCCESSFUL)
+ .explanation("Successfully configured Kerberos user")
+ .build());
+ }
+ } catch (final Exception e) {
+ verificationLogger.error("Failed to configure Kerberos user", e);
+ results.add(new ConfigVerificationResult.Builder()
+ .verificationStepName("Configure Kerberos User")
+ .outcome(FAILED)
+ .explanation("Failed to configure Kerberos user: " +
e.getMessage())
+ .build());
+ }
+
+ final BasicDataSource dataSource = new BasicDataSource();
+ try {
+ configureDataSource(dataSource, kerberosUser, context, variables);
+ results.add(new ConfigVerificationResult.Builder()
Review comment:
Does this cause the Verify button to return success? I put in a bad URL
and a bad Driver name and it still passed verification. However it gave the
expected error when I hit Apply (or Enable, can't remember)
--
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]