Commit Graph

5754 Commits

Author SHA1 Message Date
Jeff Storck c74e71306e
Merge pull request #4071 from bbende/NIFI-7026
NIFI-7026 Add kerberos password property to NiFi HortonworksSchemaReg…
2020-03-02 12:50:20 -05:00
jstorck ab1658130d
NIFI-7024: Added Kerberos Password support to HBase_1_1_2_ClientService and HBase_2_ClientService
This closes #4103.
2020-03-02 11:43:13 -05:00
jstorck 1678531638
NIFI-7025: Initial commit adding Kerberos Password feature for Hive components
Kerberos Password property should not support EL, this includes a change to KerberosProperties which is also used by the HDFS processors (AbstractHadoopProcessor)
Added wiring in a KerberosContext to a TestRunner's MockProcessorInitializationContext
Removed synchronization blocks around KerberosUser.checkTGTAndRelogin, since that method is already synchronized
Updated AbstractHadoopProcessor to have a boolean accessor method to determine if explicit keytab configuration is allowed
Removed synchronization block from HiveConnectionPool's getConnection method (in Hive, Hive_1_1, Hive3 modules), since new TGT ticket acquisition is handled by the KerberosUser implementation.  If UGI is used to relogin, synchronization is handled internally by UGI.
Added Kerberos Principal and Kerberos Password properties to Hive, Hive_1_1, and Hive3 components
Hive, Hive_1_1, and Hive3 components now use KerberosUser implementations to authenticate with a KDC

Updated handling of the NIFI_ALLOW_EXPLICIT_KEYTAB environment variable in Hive and Hive3 components.  An accessor method has been added that uses Boolean.parseBoolean, which returns true if the environment variable is set to true, and false otherwise (including when the environment variable is unset).

Addressing PR feedback

Addressing PR feedback

This closes #4102.
2020-03-02 11:28:59 -05:00
jstorck 614136ce51
NIFI-7018: Initial commit of processors extending AbstractHadoopProcessor supporting kerberos passwords
AbstractHadoopProcessor will always authenticate the principal with a KerberosUser implementation and a UGI will be acquired from the Subject associated with the KerberosUser implementation
AbstractHadoopProcessor's getUserGroupInformation method will now attempt to check the TGT and relogin if a KerberosUser impelmentation is available, otherwise it will return the UGI referenced in the HdfsResource instance
Updated AbstractHadoopProcessor's customValidate method to consider the provided password and updated validation failure explanations when a KerberosCredentialsService is specified together with a principal, password, or keytab
Added toString method override to AbstractKerberosUser
Updated Hive/HBase components to be compatible with the KerberosProperties.validatePrincipalWithKeytabOrPassword method
Fixed null ComponentLog in GetHDFSSequenceFileTest

Added package-protected accessor method (getAllowExplicitKeytabEnvironmentVariable) to AbstractHadoopProcessor for determining if the environment variable "NIFI_ALLOW_EXPLICIT_KEYTAB" has been set
AbstractHadoopProcessor will now only fail validation when the NIFI_ALLOW_EXPLICIT_KEYTAB environment variable is set to false if a keytab is provided to allow the user to specify a principal and password
Added AbstractHadoopProcessorSpec to verify validation of principal/keytab/password/kerberos credential service combinations

This closes #4095.
2020-02-28 10:10:19 -05:00
Joey Frazee ddfc425d98 Bump commons-lang3 and commons-codec versions 2020-02-27 14:57:55 -06:00
Joey Frazee ccb62826b7 NIFI-6791 Add UUID3 and UUID5 functions to Expression Language
This closes #4031
2020-02-27 14:57:55 -06:00
Justin Miller 23b04ae968
NIFI-6856 - Make client ID a non-required field for the MQTTConsume and MQTTProduce processors. Generates a
random ID if not set.

Also add group ID field to ConsumeMQTT processor. Allows consumer to join consumer group at $share/<group_id>/<topic_filter>

add expression language support for the MQTT client ID

Setting client id in publish test fails because it is not a flowfile attribute.
Remove client id and autogenerate it when testing.

Since the evaluation is done in onScheduled, there is no flow file available and we're not using the attributes to make the expression language evaluation. You can change the scope to use the Variable Registry.

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

This closes #3879.
2020-02-26 15:54:53 -08:00
Joe Witt 4cd63c99e8
NIFI-7205 NIFI-7206
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4093.
2020-02-26 14:02:49 -08:00
Shawn Weeks 0bb8ce7438
NIFI-7139 Add record.error.message on failure of a record reader or writer
Handle scenario where message might be null.

Update to test case that was failing because adding attributes modified a flow file even if you don't change the contents.

Fixed Style Issues and Updated WritesAttributes.

Added Test Case for Error Message

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

This closes #4052
2020-02-26 08:50:32 -05:00
Joe Witt bad0f10a52
NIFI-7201 - Update build to latest apache-maven-parent and split Github Actions builds to include OSX and distribute localization
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4091.
2020-02-25 17:38:33 -08:00
Przemysław Dubaniewicz c092a23bdf
NIFI-7164 Upgrade shyiko/mysql-binlog-connector-java dependency
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4076.
2020-02-25 14:05:47 -08:00
Andy LoPresto 815e4cf51f
NIFI-7152 Added custom ExceptionMappers to handle invalid Remote Process Group port value - (#4085)
JsonContentConversionExceptionMapper, JsonMappingExceptionMapper, JsonParseExceptionMapper.
Registered the custom ExceptionMappers.
Added unit tests to throw Exception for string port value and sanitize script input. Handled null or empty JsonMappingException reference path.
Added the Apache license to Groovy Test.

Signed-off-by: Andy LoPresto <alopresto@apache.org>
2020-02-25 13:14:52 -08:00
Pierre Villard cff1e329a2
NIFI-7173 - This closes #4084. add nifi-metrics jar to scripting bundle
Signed-off-by: Joe Witt <joewitt@apache.org>
2020-02-25 13:12:53 -08:00
Yolanda M. Davis abf223d574
NIFI-7163 - added RulesEngine and RulesEngineProvider interfaces, enhanced easy rules to support provider interface and refactored to extract rules engine implementation
NIFI-7163 - updated documentation and comments

NIFI-7163 - fix checkstyle issues

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

This closes #4081
2020-02-25 09:59:39 -05:00
Joe Witt 778012412a
Revert "NIFI-6363 Refactors sensitive properties, adds additional providers."
This reverts commit 479fcfdc0b.

It does not build properly as shown in Github Actions.
2020-02-24 22:07:53 -08:00
Troy Melhase 479fcfdc0b NIFI-6363 Refactors sensitive properties, adds additional providers.
NIFI-6363 Additional fixes.

NIFI-6363 Fix Hadoop compile problem.  Add GCP IT instructions.

NIFI-6363 - Removed GCP provider due to dependency conflicts with GRPC processors. Fixed unit test to match master branch after rebase.

NIFI-6363 - Added some docs and experimental tag to the relevant classes.

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

This closes #4080.
2020-02-24 16:35:19 -05:00
MatthewKnight-NG acaf321af0
NIFI-5924 Labels should be searchable
Signed-off-by: Matthew Burgess <mattyb149@apache.org>

This closes #4070
2020-02-24 16:14:21 -05:00
Wouter de Vries 9848eb4409
NIFI-7007: Add update functionality to the PutCassandraRecord processor.
NIFI-7007: Add additional unit tests that hit non-happy path

NIFI-7007: Use AllowableValue instead of string

NIFI-7007: Add the use of attributes for the update method, statement type and batch statement type

NIFI-7007: Add additional tests, mainly for the use of attributes

NIFI-7007: add some ReadsAttribute properties to the PutCassandraRecord processor

NIFI-7007: additional update keys validation logic

NIFI-7007: fix imports

NIFI-7007: Convert fieldValue to long in separate method

NIFI-7007: Add new style of tests checking actual CQL output

NIFI-7007: add license to new test file

NIFI-7007: add customValidate to check for certain incompatible property combinations

NIFI-7007: remove check on updateMethod and replace Set.of with java 8 compatible replacmenet

NIFI-7007: Add test for failure with empty update method via attributes

NIFI-7007: remove unused variable

NIFI-7007: Fix customValidate that incorrectly invalidated a valid config

Fix Checkstyle

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

This closes #3977
2020-02-24 15:14:16 -05:00
Pierre Villard 4f315edc6e
NIFI-7133 - This closes #4049. Clarification of EnforceOrder description
Signed-off-by: Joe Witt <joewitt@apache.org>
2020-02-23 11:59:49 -08:00
Pierre Villard fd7c01453b
NIFI-7184 - This closes #4074. Added mime type property to GenerateFlowFile
Signed-off-by: Joe Witt <joewitt@apache.org>
2020-02-23 11:54:28 -08:00
Pierre Villard 9a8a551e03
NIFI-7183 - This closes #4073. Improve ReplaceText when removing FF's content
Signed-off-by: Joe Witt <joewitt@apache.org>
2020-02-23 11:50:34 -08:00
Joe Witt 722b99432c
NIFI-7185 relaxed timing constrained for builds on lower resources environments like our Github CI builds
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4075.
2020-02-22 11:18:56 -08:00
Zoltan Kornel Torok e631851e0f
NIFI-7178 - Handle the case when schema is not available
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4067.
2020-02-22 11:07:31 -08:00
Joe Witt 49ba9e8196
NIFI-7181 convert integration test to proper name so it isnt run as unit test 2020-02-21 18:05:40 -05:00
Matthew Burgess 6ea78c5548
NIFI-7114: This closes #4069. Update time-sensitive tests in TestLuceneEventIndex
Signed-off-by: Joe Witt <joewitt@apache.org>
2020-02-21 17:38:36 -05:00
Matthew Burgess 1b0e3865e9
NIFI-7114: Fix file leaks in StandardCommsSession and S2S Reporting components
Signed-off-by: Joe Witt <joewitt@apache.org>
2020-02-21 17:37:54 -05:00
Bryan Bende 8fa855c8c3
NIFI-7026 Add kerberos password property to NiFi HortonworksSchemaRegistry 2020-02-21 14:56:33 -05:00
Andy LoPresto eef04709b9
NIFI-7175 Fixed core attributes formatting in Developer Guide. (#4066)
* NIFI-7175 Fixed core attributes formatting in Developer Guide.

* NIFI-7175 Made core attribute names more consistent.
2020-02-21 10:41:41 -08:00
Pierre Villard c5c1fa4e85
NIFI-7175 README.md 2020-02-20 16:41:40 -08:00
Joe Witt f8a5d1295c
NIFI-7175 removed appveyor and travis builds which have become unreliable. Added Github Actions based CI build for pull requests and pushes. Removed unit tests which make unreadable or unaccesible dirs. Includes windows build as well as ubuntu. we can do localization based builds later as this is all proven stable.
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4058.
2020-02-20 16:36:51 -08:00
Andy LoPresto c5873eceb7
NIFI-7165 Fixed TLS Toolkit Guide flags with default validity days.
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4064.
2020-02-19 21:00:33 -08:00
Pierre Villard 41518d953c
NIFI-7135 - Fix Java 11 build with com.puppycrawl.tools:checkstyle:jar:8.29 dependency
This closes #4050.

Signed-off-by: Andy LoPresto <alopresto@apache.org>
2020-02-19 20:36:57 -08:00
Troy Melhase 0de89452f1
NIFI-6927 Consolidate SSL context and trust managers for OkHttp on JDK9.
Fixes name conflicts.

This closes #4047.

Signed-off-by: Andy LoPresto <alopresto@apache.org>
2020-02-19 16:19:39 -08:00
Grant Henke 4098404596
NIFI-6551: Improve PutKudu timestamp handling
Uses `DataTypeUtils.toTimestamp` when writing to Kudu
timestamp (`UNIXTIME_MICROS`) columns. This allows
us to use the `row.addTimestamp` API and get much more
intuitive and predictable timestamp ingest behavior.

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

This closes #4054.
2020-02-18 15:30:08 -08:00
Grant Henke 09c7406d18
NIFI-6867: Validate PutKudu operation type property
This patch adds validation to the PutKudu operation type property.
It also improves the description to include the valid values and
adjusts the inputs to be case insensitive.

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

This closes #4063.
2020-02-18 14:36:02 -08:00
Grant Henke 268ba1d23e
NIFI-7142: Automatically handle schema drift in the PutKudu processor
Adds a boolean property to the PutKudu processor to optionally
enable automatic schema drift handling.

If set to true, when fields with names that are not in the target
Kudu table are encountered, the Kudu table will be altered to
include new columns for those fields.

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

This closes #4053.
2020-02-18 12:33:58 -08:00
karthik-kadajji fe416d1ea0
NIFI-6064 MockComponentLog misplaces reported exceptions
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4061.
2020-02-18 12:30:25 -08:00
Peter Turcsanyi 7e5e332842
NIFI-7143: Upgrade GCP dependency
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes NIFI-7143.
2020-02-17 12:11:16 -08:00
M Tien 37614d02cd
NIFI-7136 Added autocomplete="off" to login password input (#4055)
NIFI-7136 Added autocomplete="off" to login password input
Updated nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/WEB-INF/partials/login/login-form.jsp

Co-authored-by: Pierre Villard <pierre.villard.fr@gmail.com>

Signed-off-by: Andy LoPresto <alopresto@apache.org>
2020-02-14 20:46:08 -08:00
Otto Fowler 6e8f10c4f6
NIFI-7109 Unit tests should be able to determine if item validator was called
- Create a mock Validator to track count of calls to validate().
We cannot use Mockito for this, because it can't mock all the
StandardValidators

refactor based on review comments

fix naming in comments

moved to main based on review

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

This closes #4043
2020-02-12 11:22:31 -05:00
Joe Ferner 62606ff89a NIFI-6873: Added support for replacing a process group
- decoupled flow update request behavior from VersionsResource into new abstract FlowUpdateResource
 - added replace process group functionality in ProcessGroupResource
 - parameterized FlowUpdateResource and created entity hierarchies to allow for maximum code sharing across different update types
 - refactored flow update methods to make use of commonality across different update types whenever possible
 - fixed issues in StandardProcessGroup verify update methods where same components existed in different ancestry chains but were considered a match when they shouldn't be
 - improved StandardProcessGroup to properly match up components on update using generated versioned component ids, when necessary to allow for update flow to efficiently match common components on flow import

This closes #4023.

Signed-off-by: Mark Payne <markap14@hotmail.com>
2020-02-11 14:46:40 -05:00
Wouter de Vries a80b2475f7
NIFI-7132: fix handling of UUIDs in PutCassandraQL
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4048.
2020-02-11 11:21:27 -08:00
Mark Payne 65b2a9bc2c
NIFI-7117: When SocketLoadBalancedFlowFileQueue creates its array of Queue Partitions in the constructor, it added the local partition as the first element in that list. This list should be ordered the same across all nodes in the cluster. By making the local partition the first in the array, each node had a different ordering of these partitions. As a result, Partition by Attribute strategy would constantly rebalance flowfiles that it received to other node, and Single Node always transferred data to the first partition, which was the local node, instead of whichever node should have been the first in the list. This commit addresses this issue by instead inserting the local partition intot he 'queuePartitions' array based on the local node identifier.
Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #4045.
2020-02-11 10:59:19 -08:00
David Savage 5e964fbc47
NIFI-4792: Add support for querying array fields in QueryRecord
Work in progress adding support for array based queries
updated calcite dependency

tidy up unused imports highlighted by checkstyle in travis build

tidy up }s highlighted by checkstyle in travis build

Add test for use case referenced in NIFI-4792

Bumped Calcite version to 1.21.0

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

This closes #4015
2020-02-11 10:59:20 -05:00
M Tien 8faea04ff1
NIFI-7082 Updated tls-toolkit default server and client certificates validity days to 825 days. (#4046)
Signed-off-by: Andy LoPresto <alopresto@apache.org>
2020-02-10 17:22:49 -08:00
Pierre Villard 58bcd6c5dd
NIFI-7106 - Add parent name and parent path in SiteToSiteStatusReportingTask
Signed-off-by: Matthew Burgess <mattyb149@apache.org>

This closes #4039
2020-02-10 12:07:21 -05:00
John Highcock f738e19a75
NIFI-2537: Add custom MIME type configuration support to IdentifyMimeType
Add two new properties to IdentifyMimeType (Config File and Config Body).
Specifying one of these properties will override the default NiFi MIME
type configuration and use the configured property's MIME config instead.
Add additional runtime documentation for IdentifyMimeType's usage. The
default behavior of IdentifyMimeType is unchanged.

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

This closes #4016.
2020-02-06 19:34:18 -05:00
Andrew Lim 62830122cb
NIFI-6491 Improve installation instructions in Admin Guide and Getting Starting Guide
Clarified homebrew install instructions.

This closes #4029.

Signed-off-by: Andy LoPresto <alopresto@apache.org>
2020-02-06 14:30:51 -05:00
Andrew Lim ac0382c7ae
NIFI-7075 Add missing FlowFile core attributes to Developer Guide (#4030)
Signed-off-by: Andy LoPresto <alopresto@apache.org>
2020-02-06 14:17:39 -05:00
Pierre Villard 089013aa59
NIFI-7105 - fix NPE for counters in SiteToSiteStatusReportingTask (#4038)
Signed-off-by: Andy LoPresto <alopresto@apache.org>
2020-02-06 14:10:48 -05:00