Commit Graph

159 Commits

Author SHA1 Message Date
exceptionfactory ca6c7f7041 NIFI-11532 Removed JUnit 4 and Groovy Test from default dependencies
- Removed hamcrest-all from default dependencies
- Added groovy-test to selected modules with Groovy test classes
- Added junit-vintage-engine to selected modules with JUnit 4 test classes
- Corrected references to JUnit 4 assertions in JUnit 5 test classes
- Removed several unnecessary test classes from nifi-socket-utils
- Removed duplicative Registry toolkit test classes
- Removed Kudu integration tests

NIFI-11532 Corrected scope for junit-vintage-engine for Elasticsearch

Signed-off-by: Matt Burgess <mattyb149@apache.org>

This closes #7233
2023-06-13 15:36:23 -04:00
exceptionfactory 962dc9bc38
NIFI-11679 Refactored EncryptedRepoContentAccessIT Configuration (#7369) 2023-06-13 11:06:45 -04:00
Mark Payne 15f8f872f6 NIFI-11471: Added a system test to verify controller service enable timeout.
This closes #7242.
2023-06-12 14:48:16 -04:00
Mark Payne 702c635034
NIFI-11670 Refactored Content Repo OutputStream to create new Claim per FlowFile
Rather than creating many FlowFiles with the same Content Claim, refactored content repos' OutputStreams and ClaimWriteCache so that a new ContentClaim is created for each FlowFile. This ensures that we have a content claim offset of 0. The poor performance was due to having to use StreamUtils.skip() in conjunction with the CipherInputStream, which would only skip a max of 511 bytes at a time. By using a separate Content Claim per FlowFile, we no longer need to seek after creating the CipherInputStream

This closes #7363

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2023-06-12 09:47:44 -05:00
Mark Payne 4b7e20740e
NIFI-11591: Added additional logging for DynamicallyModifyClasspath system test
This closes #7312

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2023-05-31 16:23:07 -05:00
Mark Payne 9f61b5f957
NIFI-11591 Improved stability of DynamicallyClassPath and AsyncCommitCallback tests
After terminating Processor in DynamicallyModifiedClasspathIT system test, keep trying to empty queue until successful instead of assuming success after the first iteration.

When writing to a replacement file in AsyncCommitCallbackIT, write to a temp file and then rename. This prevents the processor from picking up the file while it's still being written.

This closes #7302

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2023-05-25 19:14:01 -05:00
Mark Payne 108f841525
NIFI-11591 Corrected intermittent system test failures
When waiting for a Processor to stop completely in system tests, also consider any terminated threads. Consider the processor stopped only when all active threads and all terminated threads have gone to 0. Additionally, when stopping all components in a Process Group, wait for the PG to reflect that there are no running components.  Previously, we checked for processor active thread counts. However, this was problematic because the flow that was fetched was not fetched recursively and as a result, processors running in embedded groups were not always stopped when the waitForProcessorsStopped(String groupId) method returned. Finally, removed the step for gathering surefire-reports in failed system tests because it was not working as expected and was unneeded because the tests' logs were already gathered into the diagnostic dump that is uploaded.

Added fix for BatchFlowBetweenGroupsIT. The test would intermittently fail, based on timing. The test assumed that when Input Port in Group B was scheduled to run, it would trigger before FlowFiles in Group A finished processing. The Sleep processor caused a 10 ms delay for each of 5 FlowFiles which gives the Input Port about 50 ms to trigger. If it took longer to trigger the first time, the test failed. Adjusted the Sleep processor to use 2 seconds. So now instead of 50 milliseconds to start, it has 10 seconds. Overall this adds about 30-45 seconds to the run time of the test but ensures more-than-adequate time for the test to run, even on extremely slow hardware

This closes #7289

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2023-05-24 14:03:07 -05:00
Mark Payne a12c9ca9c7
NIFI-11557: Avoid using the expensive and unnecessary Files.walkFileTree on startup and initialization of Content Repository. Also performed some code cleanup: IntelliJ flagged many warnings in the class, mostly around methods that are no longer used and potential NullPointerExceptions, so those were cleaned up. Additionally, removed the nifi property for max flowfiles per claim - this property was never implemented. It was referenced, but the way in which is was used curiously had nothing to do with what the property was intended to be used for or for how it was documented. Instead, it was used to limit the max number of claims that could remain writable. As a result, it was removed.
NIFI-11557: Added an additional system test and updated github actions to include surefire-report in order to help diagnose problem that occurred in one of the last system-test runs in Github. Could not replicate problem locally
Signed-off-by: Matthew Burgess <mattyb149@apache.org>

This closes #7265
2023-05-23 14:29:29 -04:00
Lehel Boér 265b132e73
NIFI-11493: Defaulted dynamically modified classpath fix
This closes #7201.

Co-authored-by: Peter Turcsanyi <turcsanyi@apache.org>
Signed-off-by: Peter Turcsanyi <turcsanyi@apache.org>
2023-05-04 15:20:56 +02:00
exceptionfactory ee03db0e8f
NIFI-11488 Removed Deprecated Sensitive Properties Algorithms
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #7198.
2023-04-27 20:16:26 +03:00
Mark Payne 7f7cccfdc2
NIFI-11241 Initial implementation of Python-based Processor API with Py4J
- Updated GitHub workflow so that system tests include Python 3.9
- Updated GitHub actions to build necessary modules for system tests

This closes #7003

Co-authored-by: David Handermann <exceptionfactory@apache.org>
Signed-off-by: David Handermann <exceptionfactory@apache.org>
2023-04-14 15:03:34 -05:00
Bryan Bende ba93f60731
NIFI-11436 Fix NPE during updateFlow when called from a replace request for a PG that is not under version control (#7167) 2023-04-12 19:24:22 -04:00
Mark Payne 23d6d6ede4
NIFI-11251: Fixed case in which changing Flow Version was improperly attempting to use a Temporary Funnel destination for a connection due to differences in Group ID by instead checking if the destination is reachable; fixed issue in which processors in an inner versioned group were not stopped even though they changed, when a higher-level parent (that was itself under version control) had its version changed. Wrote system tests to verify
- Fixed system tests so that they work properly in Clustered version of RegistryClientIT
- Fixed system test - ensure that we wait for processors to become valid before attempting to start them; also added an additional system test around Controller Services in versioned flows

This closes #7095

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2023-03-29 08:30:18 -05:00
Mark Payne 94ae926c42
NIFI-11333: Do not allow components to be removed while a node is disconnected
This closes #7085

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2023-03-27 17:43:38 -05:00
Mark Payne 016d58612c
NIFI-11290 Run Component Primary Node State changes in background thread
- Ensure that components are notified that primary node has changed in a background thread instead of the Leader Election thread and activate/deactivate the thread in the case of Processors so that they can be viewed in the UI and terminated

- Fixed system tests that would fail intermittently because they did not wait for node disconnection to complete and did not properly switch the client to look at the connected node before checking cluster status

This closes #7052

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2023-03-23 12:20:37 -05:00
Mark Payne 6adfb6131d
NIFI-11310: Provide appropriate classpath resources to the ReloadComponent when a processor is terminated
NIFI-11310: Fixed META-INF/services file that was mistakenly listing an extra extension point, due to rebase
Signed-off-by: Matthew Burgess <mattyb149@apache.org>

This closes #7061
2023-03-21 14:29:44 -04:00
exceptionfactory cfee993c12
NIFI-11280 Updated system-tests Sensitive Properties Algorithm
- Updated algorithm from PBEWITHMD5AND256BITAES-CBC-OPENSSL to NIFI_PBKDF2_AES_GCM_256

Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #7041.
2023-03-14 12:37:46 +01:00
exceptionfactory c8b5c0ce7b
NIFI-11220 Removed nifi-bootstrap-utils
- Replaced OSUtils.getProcessId() with java.lang.Process.pid() available on Java 9 and following

Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #6989.
2023-02-27 13:51:14 +01:00
Mark Payne 87e61c50ee
NIFI-11192: Ensure that if ports moved between parent/child group in between flow versions that we can properly handle that. Added system tests to verify.
NIFI-11192: If a failure is encountered when changing the version of a flow from 1 version to another, attempt to rollback the changes instead of just failing with the flow in a bad state
Signed-off-by: Matthew Burgess <mattyb149@apache.org>

This closes #6981
2023-02-22 15:38:00 -05:00
exceptionfactory 1156f4cbc5
NIFI-11165 This closes #6944. Removed optional jigsaw build profiles
- Removed jigsaw build profiles
- Removed Java 11 directories from assemblies

Signed-off-by: Joe Witt <joewitt@apache.org>
2023-02-13 13:01:58 -05:00
Joe Witt 43eab4c81d
NIFI-11103 prepping for 2.0.0 line 2023-02-09 15:32:53 -07:00
exceptionfactory e264f1fd77
NIFI-11097 This closes #6890. Adjusted RegistryClientIT with unique name for Clients
Signed-off-by: Joe Witt <joewitt@apache.org>
2023-01-26 09:50:35 -07:00
exceptionfactory 972667461b
NIFI-10580 This closes #6867. Upgraded SLF4J from 1.7.36 to 2.0.6
- Upgraded Logback from 1.2.11 to 1.3.5
- Updated Logback DelayingShutdownHook to DefaultShutdownHook
- Disabled Spring Boot Logging System in favor of standard Logback initialization
- Excluded logback-classic from ZooKeeper and other dependencies to avoid conflicts when running tests
- Excluded spring-boot-starter-logging to avoid failures related to Logback 1.2 and Spring Boot 2.7
- Removed ZooKeeperMigratorTest.groovy based on Apache Curator test server usage of Logback 1.2

NIFI-10580 Added logback-core as explicit dependency

- Set logback-core as provided in root configuration
- Added logback-core as compile dependency in assembly configurations

Signed-off-by: Joe Witt <joewitt@apache.org>
2023-01-23 11:38:10 -07:00
Bryan Bende 5c3ca9d537
NIFI-10981 Ensure NarAutoLoader starts after provider retrieves NARs,… (#6785)
- NIFI-10981 Ensure NarAutoLoader starts after provider retrieves NARs, and ensure the auto-loader attempts to process any NARs available before starting to watch for new files
- Add system test with NAR Provider that copies NARs from a local directory and verifies the NARs were loaded and linked correctly
- Exclude new assembly from CI test-compile
2022-12-16 11:30:37 -05:00
Joe Witt 75e7c9e47c
NIFI-10854-RC1 prepare for next development iteration 2022-11-22 19:22:47 -07:00
Joe Witt ec87bf93ad
NIFI-10854-RC1 prepare release nifi-1.19.0-RC1 2022-11-22 19:22:45 -07:00
Mark Payne d390a0becf
NIFI-10673: When a component is added to a ProcessGroup, we had a method called ensureUniqueVersionControlId but the method only took into accounts in that Process Group. Updated methods to now consider components in any Process Group that is part of the same Versioned Flow. Also added system test to verify the problem and the fix. Added Toolkit clients and additional methods as necessary in order to implement system tests
NIFI-10673: Addresed checkstyle issue

NIFI-10673: Removed TODO comment
Signed-off-by: Matthew Burgess <mattyb149@apache.org>
2022-10-26 14:38:01 -04:00
dan-s1 5da9ce525c
NIFI-10565 Removed duplicated test dependencies
This closes #6482

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-10-07 09:07:51 -05:00
Joe Witt c9ebdd2025
NIFI-10521-RC4 prepare for next development iteration 2022-10-03 10:59:36 -07:00
Joe Witt 109e54cd58
NIFI-10521-RC4 prepare release nifi-1.18.0-RC4 2022-10-03 10:59:34 -07:00
Mark Payne 3f0ef9e977
NIFI-10406: Updated Maven assemblies to ensure that we always use at least two of the GAVC parameters for includes and excludes. Updated Maven assembly plugin to version 3.4.2. Removed some includes and excludes from dependencies that previously were not matching and were generating Maven WARNING messages.
This closes #6415

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-09-15 11:02:08 -05:00
Joe Gresock 6d8dda1c03
NIFI-10487: Commenting out ClusteredVerifiableParameterProviderSystemIT assertion until NIFI-9717 can be implemented
This closes #6407
Signed-off-by: Paul Grey <greyp@apache.org>
2022-09-12 14:19:25 -04:00
Joe Gresock de7793e69b
NIFI-9003 Added framework support for Parameter Providers
- Added Environment Variable and File Parameter Provider implementations
- Added Parameter Provider commands to CLI
- Added component search handling for Parameter Providers
- Added documentation for integrating Parameter Providers

This closes #5369

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-09-09 13:04:56 -05:00
Mark Payne a0c705715b
NIFI-10429: Added the ability to Replay latest provenance event for a given Processor.
This closes #6359

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-09-08 15:55:26 -05:00
Mark Payne 21503f6353
NIFI-10362: When asynchronous node disconnect is issued, do not send disconnect to node if the node becomes reconnected in the interim. Also, addressed the issue in which a disconnected node acts on a replicated request during the first phase by detect that it's the first phase if configured for cluster, not when only when connected to a cluster.
This closes #6308

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-08-17 11:09:47 -05:00
Joe Witt ded48269fe
Merge branch 'NIFI-10272-RC2' 2022-08-01 06:10:25 -07:00
Mark Payne d5386acb4f
NIFI-10290: Updated system tests to ensure that they do not attempt to start processors while the processors are still validating.
This closes #6253

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-07-28 13:36:22 -05:00
Joe Witt 8c66bf948c
NIFI-10272-RC2 prepare for next development iteration 2022-07-27 13:24:09 -07:00
Joe Witt 8d256784d8
NIFI-10272-RC2 prepare release nifi-1.17.0-RC2 2022-07-27 13:24:06 -07:00
Mark Payne 8a1249ee39
NIFI-10279: This closes #6246. Increased timeout in TestExecuteStateless, removed explicit timeouts on stateless system tests that were too aggressive so that the tests use the default 5 minute timeout defined in StatelessSystemIT
Signed-off-by: Joe Witt <joewitt@apache.org>
2022-07-25 14:33:48 -07:00
Mark Payne 0497907829
NIFI-10262: Ensure that when an Exception is thrown from a Controller Service's @OnEnabled method that we properly handle that Exception and continue enabling the other services in the given collection of services
This closes #6236

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-07-25 10:02:21 -05:00
Mark Payne bc4e3e850b
NIFI-10246: When syncing Controller Services, wait until any DISABLING Controller Service has fully disabled before attempting to synchronize them. Also performed some minor refactoring/cleanup for System Tests in order to make writing a system test for this simpler
This closes #6219

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-07-22 13:31:06 -05:00
Nissim Shiman db11961026
NIFI-9440 Allow Controller Services to have configurable Bulletins
Signed-off-by: Matthew Burgess <mattyb149@apache.org>

This closes #6035
2022-06-28 10:44:45 -04:00
Mark Payne ac8c1b0326
NIFI-10148: Fixed bug in SwappablePriorityQueue, in which the Active Queue Size could be decremented before the Unacknowledged Queue Size is incremented when FlowFiles are polled. This can result in the SwappablePrioriotyQueue incorrectly returning a value of true from the isEmpty() method. Additionally, updated the NiFiSystemIT so that if waiting for a particular queue size we periodically log size of all queues, which aids in debugging, and added necessary methods to FlowClient to make that happen.
This closes #6143

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-06-21 15:55:47 -05:00
exceptionfactory bd45eb4995 NIFI-10100 Upgraded Jersey to 2.35
- Replaced individual version references with Jersey BOM dependency

Signed-off-by: Nathan Gough <thenatog@gmail.com>

This closes #6106.
2022-06-16 23:09:22 -04:00
Mark Payne 005fbe3c50
NIFI-10063: Wait for processor to become valid before attempting to start it
This closes #6083

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-05-31 10:34:02 -05:00
exceptionfactory 99be62be67
NIFI-9958 Add Framework Support for Sensitive Dynamic Properties (#6057)
* NIFI-9958 Implemented Sensitive Dynamic Properties

- Added SupportsSensitiveDynamicProperties annotation for components
- Added optional sensitive query parameter to Property Descriptor REST Resource methods
- Added system tests for components supporting sensitive dynamic properties
- Updated REST Resources to support Sensitive Dynamic Property Names
- Updated Documentation Writer to indicate component support for Sensitive Dynamic Properties
- Updated InvokeHTTP to support Sensitive Dynamic Properties
- Updated Auditor components to handle masking Sensitive Dynamic Properties

* Refactored Property Descriptor REST method handling

- Corrected AbstractDocumentationWriter evaluation of support for sensitive dynamic properties
- Refactored Controller Service Dynamic Properties system tests to new class

* Updated AbstractComponentNode.getProperties() to get canonical descriptor
2022-05-23 17:20:54 -04:00
Mark Payne 38b51b0dde
NIFI-10037: When system test fails to clean up flow, destroy the entire environment so that the next test starts in a healthy state. Name troubleshooting directories with the name of the test class to avoid ambiguity. Also added a log statement so that we know which test is running when looking at the log output from the tests themselves. Finally, found an issue in AbstractComponentNode in which we iterate over the elements in a Map and call setProperty, which can update the underlying Map - updated to first create a copy of the HashMap. Updated that in this Jira because I suspect it is causing one of the tests failures that I've been investigating.
This closes #6059

Signed-off-by: David Handermann <exceptionfactory@apache.org>
2022-05-19 13:14:30 -05:00
markap14 88e53eae8c
NIFI-10001: Fixed bugs that caused some components to not have their scheduled state updated. (#6049)
* NIFI-10001: Fixed issue in which some components may fail to update the scheduled state when comparing flows

* NIFI-10001: Fixed bugs that caused some components to not have their scheduled state updated. When comparing two flows, now allow specifying how to determine a VersionedComponent's ID for comparison. When comparing local flow against flow from registry, use Versioned Component ID. But when comparing two instantiated flows, such as local flow vs. cluster flow, use the VersionedComponent's Instance ID instead. This ensures that we can properly compare two components even if there are several instances of a given flow
2022-05-18 13:53:36 -04:00
exceptionfactory 85d5e2071b
NIFI-10031 Downgraded Jakarta Mail from 2.0.1 to 1.6.7 (#6052)
- Downgraded Jakarta Activation from 2.0.1 to 1.2.2 in nifi-bootstrap
- Updated assembly configurations to include Jakarta Activation in java11 directory
2022-05-18 11:38:36 -04:00