gresockj commented on a change in pull request #5843:
URL: https://github.com/apache/nifi/pull/5843#discussion_r820902041
##########
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:
No, this will just add one successful result, but the other steps should
fail. I'm surprised, because I can easily get it to fail with a bad URL or
driver -- can you share the values you used?
--
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]