[nifi] branch NIFI-11312 created (now de1c0e855e)
This is an automated email from the ASF dual-hosted git repository. chriss pushed a change to branch NIFI-11312 in repository https://gitbox.apache.org/repos/asf/nifi.git at de1c0e855e NIFI-11312 rationalise nifi-registry docker image startup scripts This branch includes the following new commits: new de1c0e855e NIFI-11312 rationalise nifi-registry docker image startup scripts The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference.
[nifi] 01/01: NIFI-11312 rationalise nifi-registry docker image startup scripts
This is an automated email from the ASF dual-hosted git repository. chriss pushed a commit to branch NIFI-11312 in repository https://gitbox.apache.org/repos/asf/nifi.git commit de1c0e855eef8e21441ca04142bc13d44e8abd71 Author: Chris Sampson AuthorDate: Mon Mar 20 21:57:57 2023 + NIFI-11312 rationalise nifi-registry docker image startup scripts --- .../nifi-registry-docker/dockerhub/sh/start.sh | 1 + .../dockerhub/sh/update_flow_provider.sh | 3 ++ .../dockerhub/sh/update_login_providers.sh | 1 + .../dockerhub/sh/update_oidc_properties.sh | 18 +++ .../nifi-registry-docker-maven/dockermaven/pom.xml | 16 ++ .../dockermaven/sh/common.sh | 28 -- .../dockermaven/sh/secure.sh | 57 .../dockermaven/sh/start.sh| 63 -- .../dockermaven/sh/update_bundle_provider.sh | 48 - .../dockermaven/sh/update_database.sh | 24 - .../dockermaven/sh/update_flow_provider.sh | 47 .../dockermaven/sh/update_login_providers.sh | 48 - .../dockermaven/sh/update_oidc_properties.sh | 27 -- 13 files changed, 29 insertions(+), 352 deletions(-) diff --git a/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/start.sh b/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/start.sh index eba4ef217e..2703395516 100755 --- a/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/start.sh +++ b/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/start.sh @@ -42,6 +42,7 @@ case ${AUTH} in ;; oidc) echo 'Enabling OIDC user authentication' +prop_replace 'nifi.registry.security.needClientAuth' 'false' . "${scripts_dir}/secure.sh" . "${scripts_dir}/update_oidc_properties.sh" diff --git a/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_flow_provider.sh b/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_flow_provider.sh index 92a921422d..87fa5bdf72 100644 --- a/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_flow_provider.sh +++ b/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_flow_provider.sh @@ -35,6 +35,9 @@ case ${NIFI_REGISTRY_FLOW_PROVIDER} in file) xmlstarlet ed --inplace -u "${property_xpath}/class" -v "org.apache.nifi.registry.provider.flow.FileSystemFlowPersistenceProvider" "${providers_file}" ;; +database) +xmlstarlet ed --inplace -u "${property_xpath}/class" -v "org.apache.nifi.registry.provider.flow.DatabaseFlowPersistenceProvider" "${providers_file}" +;; git) xmlstarlet ed --inplace -u "${property_xpath}/class" -v "org.apache.nifi.registry.provider.flow.git.GitFlowPersistenceProvider" "${providers_file}" add_property "Remote To Push" "${NIFI_REGISTRY_GIT_REMOTE:-}" diff --git a/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_login_providers.sh b/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_login_providers.sh index e3280b56aa..b6e4650a42 100755 --- a/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_login_providers.sh +++ b/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_login_providers.sh @@ -45,3 +45,4 @@ edit_property 'Url' "${LDAP_URL}" edit_property 'User Search Base'"${LDAP_USER_SEARCH_BASE}" edit_property 'User Search Filter' "${LDAP_USER_SEARCH_FILTER}" edit_property 'Identity Strategy' "${LDAP_IDENTITY_STRATEGY}" +edit_property 'Referral Strategy' "${LDAP_REFERRAL_STRATEGY}" diff --git a/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_oidc_properties.sh b/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_oidc_properties.sh index 827a40edba..d1ddff7f94 100644 --- a/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_oidc_properties.sh +++ b/nifi-registry/nifi-registry-core/nifi-registry-docker/dockerhub/sh/update_oidc_properties.sh @@ -15,13 +15,11 @@ #See the License for the specific language governing permissions and #limitations under the License. -prop_replace 'nifi.security.user.oidc.discovery.url' "${NIFI_SECURITY_USER_OIDC_DISCOVERY_URL}" -prop_replace 'nifi.security.user.oidc.connect.timeout' "${NIFI_SECURITY_USER_OIDC_CONNECT_TIMEOUT}" -prop_replace 'nifi.security.user.oidc.read.timeout' "${NIFI_SECURITY_USER_OIDC_READ_TIMEOUT}" -prop_replace 'nifi.security.user.oidc.client.id' "${NIFI_SECURITY_USER_OIDC_CLIENT_ID}" -prop_replace 'nifi.security.user.oidc.client.secret'
[nifi] branch support/nifi-1.x updated: NIFI-11305: Fix logic to correctly stop CaptureChangeMySQL (#7059)
This is an automated email from the ASF dual-hosted git repository. markap14 pushed a commit to branch support/nifi-1.x in repository https://gitbox.apache.org/repos/asf/nifi.git The following commit(s) were added to refs/heads/support/nifi-1.x by this push: new b554102f4a NIFI-11305: Fix logic to correctly stop CaptureChangeMySQL (#7059) b554102f4a is described below commit b554102f4aa5f3cd40ba505ad233d4032b4accff Author: Matt Burgess AuthorDate: Mon Mar 20 16:04:19 2023 -0400 NIFI-11305: Fix logic to correctly stop CaptureChangeMySQL (#7059) --- .../org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java b/nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java index 37a6820b8a..4298af4379 100644 --- a/nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java +++ b/nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java @@ -492,7 +492,6 @@ public class CaptureChangeMySQL extends AbstractSessionFactoryProcessor { private volatile boolean inTransaction = false; private volatile boolean skipTable = false; -private final AtomicBoolean doStop = new AtomicBoolean(false); private final AtomicBoolean hasRun = new AtomicBoolean(false); private int currentHost = 0; @@ -923,7 +922,6 @@ public class CaptureChangeMySQL extends AbstractSessionFactoryProcessor { } gtidSet = new GtidSet(binlogClient.getGtidSet()); -doStop.set(false); } @@ -931,7 +929,7 @@ public class CaptureChangeMySQL extends AbstractSessionFactoryProcessor { RawBinlogEvent rawBinlogEvent; // Drain the queue -while ((rawBinlogEvent = queue.poll()) != null && !doStop.get()) { +while (isScheduled() && (rawBinlogEvent = queue.poll()) != null) { Event event = rawBinlogEvent.getEvent(); EventHeaderV4 header = event.getHeader(); long timestamp = header.getTimestamp(); @@ -1266,7 +1264,6 @@ public class CaptureChangeMySQL extends AbstractSessionFactoryProcessor { currentSession.commitAsync(); } -doStop.set(true); currentBinlogPosition = -1; } catch (IOException e) { throw new CDCException("Error closing CDC connection", e);
[nifi] branch main updated: NIFI-11305: Fix logic to correctly stop CaptureChangeMySQL (#7059)
This is an automated email from the ASF dual-hosted git repository. markap14 pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/nifi.git The following commit(s) were added to refs/heads/main by this push: new 0c7de2c748 NIFI-11305: Fix logic to correctly stop CaptureChangeMySQL (#7059) 0c7de2c748 is described below commit 0c7de2c7482f18507877750ea00f9e9b9134fac7 Author: Matt Burgess AuthorDate: Mon Mar 20 16:04:19 2023 -0400 NIFI-11305: Fix logic to correctly stop CaptureChangeMySQL (#7059) --- .../org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java b/nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java index 37a6820b8a..4298af4379 100644 --- a/nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java +++ b/nifi-nar-bundles/nifi-cdc/nifi-cdc-mysql-bundle/nifi-cdc-mysql-processors/src/main/java/org/apache/nifi/cdc/mysql/processors/CaptureChangeMySQL.java @@ -492,7 +492,6 @@ public class CaptureChangeMySQL extends AbstractSessionFactoryProcessor { private volatile boolean inTransaction = false; private volatile boolean skipTable = false; -private final AtomicBoolean doStop = new AtomicBoolean(false); private final AtomicBoolean hasRun = new AtomicBoolean(false); private int currentHost = 0; @@ -923,7 +922,6 @@ public class CaptureChangeMySQL extends AbstractSessionFactoryProcessor { } gtidSet = new GtidSet(binlogClient.getGtidSet()); -doStop.set(false); } @@ -931,7 +929,7 @@ public class CaptureChangeMySQL extends AbstractSessionFactoryProcessor { RawBinlogEvent rawBinlogEvent; // Drain the queue -while ((rawBinlogEvent = queue.poll()) != null && !doStop.get()) { +while (isScheduled() && (rawBinlogEvent = queue.poll()) != null) { Event event = rawBinlogEvent.getEvent(); EventHeaderV4 header = event.getHeader(); long timestamp = header.getTimestamp(); @@ -1266,7 +1264,6 @@ public class CaptureChangeMySQL extends AbstractSessionFactoryProcessor { currentSession.commitAsync(); } -doStop.set(true); currentBinlogPosition = -1; } catch (IOException e) { throw new CDCException("Error closing CDC connection", e);
[nifi] branch support/nifi-1.x updated: NIFI-11204: Add configurable retry logic for table commits in PutIceberg processor
This is an automated email from the ASF dual-hosted git repository. turcsanyi pushed a commit to branch support/nifi-1.x in repository https://gitbox.apache.org/repos/asf/nifi.git The following commit(s) were added to refs/heads/support/nifi-1.x by this push: new 835c95fca0 NIFI-11204: Add configurable retry logic for table commits in PutIceberg processor 835c95fca0 is described below commit 835c95fca0d4d4aff69096e9683f73a05dc4c196 Author: Mark Bathori AuthorDate: Tue Feb 21 15:11:19 2023 +0100 NIFI-11204: Add configurable retry logic for table commits in PutIceberg processor This closes #6976. Signed-off-by: Peter Turcsanyi --- .../iceberg/AbstractIcebergProcessor.java | 2 +- .../apache/nifi/processors/iceberg/PutIceberg.java | 68 ++- .../additionalDetails.html | 58 ++ .../processors/iceberg/TestDataFileActions.java| 195 + .../nifi/processors/iceberg/TestFileAbort.java | 108 5 files changed, 314 insertions(+), 117 deletions(-) diff --git a/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/AbstractIcebergProcessor.java b/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/AbstractIcebergProcessor.java index 7dc53eefd7..a4ec2ccf07 100644 --- a/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/AbstractIcebergProcessor.java +++ b/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/AbstractIcebergProcessor.java @@ -107,7 +107,7 @@ public abstract class AbstractIcebergProcessor extends AbstractProcessor { } catch (Exception e) { getLogger().error("Privileged action failed with kerberos user " + kerberosUser, e); -session.transfer(flowFile, REL_FAILURE); +session.transfer(session.penalize(flowFile), REL_FAILURE); } } } diff --git a/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/PutIceberg.java b/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/PutIceberg.java index cdd2997a58..1af97768f3 100644 --- a/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/PutIceberg.java +++ b/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/PutIceberg.java @@ -19,10 +19,12 @@ package org.apache.nifi.processors.iceberg; import org.apache.iceberg.AppendFiles; import org.apache.iceberg.DataFile; import org.apache.iceberg.FileFormat; +import org.apache.iceberg.PendingUpdate; import org.apache.iceberg.Table; import org.apache.iceberg.catalog.Catalog; import org.apache.iceberg.catalog.Namespace; import org.apache.iceberg.catalog.TableIdentifier; +import org.apache.iceberg.exceptions.CommitFailedException; import org.apache.iceberg.io.TaskWriter; import org.apache.iceberg.io.WriteResult; import org.apache.iceberg.util.Tasks; @@ -54,6 +56,7 @@ import java.util.List; import java.util.Locale; import java.util.Map; import java.util.Set; +import java.util.concurrent.TimeUnit; import static org.apache.iceberg.TableProperties.DEFAULT_FILE_FORMAT; import static org.apache.iceberg.TableProperties.DEFAULT_FILE_FORMAT_DEFAULT; @@ -114,6 +117,42 @@ public class PutIceberg extends AbstractIcebergProcessor { .addValidator(StandardValidators.LONG_VALIDATOR) .build(); +static final PropertyDescriptor NUMBER_OF_COMMIT_RETRIES = new PropertyDescriptor.Builder() +.name("number-of-commit-retries") +.displayName("Number of Commit Retries") +.description("Number of times to retry a commit before failing.") +.required(true) +.defaultValue("10") +.addValidator(StandardValidators.INTEGER_VALIDATOR) +.build(); + +static final PropertyDescriptor MINIMUM_COMMIT_WAIT_TIME = new PropertyDescriptor.Builder() +.name("minimum-commit-wait-time") +.displayName("Minimum Commit Wait Time") +.description("Minimum time to wait before retrying a commit.") +.required(true) +.defaultValue("100 ms") +.addValidator(StandardValidators.TIME_PERIOD_VALIDATOR) +.build(); + +static final PropertyDescriptor MAXIMUM_COMMIT_WAIT_TIME = new PropertyDescriptor.Builder() +.name("maximum-commit-wait-time") +.displayName("Maximum Commit Wait Time") +.description("Maximum time to wait before retrying a commit.") +.required(true) +.defaultValue("2 sec") +
[nifi] branch main updated: NIFI-11204: Add configurable retry logic for table commits in PutIceberg processor
This is an automated email from the ASF dual-hosted git repository. turcsanyi pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/nifi.git The following commit(s) were added to refs/heads/main by this push: new e370292d7f NIFI-11204: Add configurable retry logic for table commits in PutIceberg processor e370292d7f is described below commit e370292d7f3c295a1810532e9349a11b4104e82b Author: Mark Bathori AuthorDate: Tue Feb 21 15:11:19 2023 +0100 NIFI-11204: Add configurable retry logic for table commits in PutIceberg processor This closes #6976. Signed-off-by: Peter Turcsanyi --- .../iceberg/AbstractIcebergProcessor.java | 2 +- .../apache/nifi/processors/iceberg/PutIceberg.java | 68 ++- .../additionalDetails.html | 58 ++ .../processors/iceberg/TestDataFileActions.java| 195 + .../nifi/processors/iceberg/TestFileAbort.java | 108 5 files changed, 314 insertions(+), 117 deletions(-) diff --git a/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/AbstractIcebergProcessor.java b/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/AbstractIcebergProcessor.java index 7dc53eefd7..a4ec2ccf07 100644 --- a/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/AbstractIcebergProcessor.java +++ b/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/AbstractIcebergProcessor.java @@ -107,7 +107,7 @@ public abstract class AbstractIcebergProcessor extends AbstractProcessor { } catch (Exception e) { getLogger().error("Privileged action failed with kerberos user " + kerberosUser, e); -session.transfer(flowFile, REL_FAILURE); +session.transfer(session.penalize(flowFile), REL_FAILURE); } } } diff --git a/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/PutIceberg.java b/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/PutIceberg.java index cdd2997a58..1af97768f3 100644 --- a/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/PutIceberg.java +++ b/nifi-nar-bundles/nifi-iceberg-bundle/nifi-iceberg-processors/src/main/java/org/apache/nifi/processors/iceberg/PutIceberg.java @@ -19,10 +19,12 @@ package org.apache.nifi.processors.iceberg; import org.apache.iceberg.AppendFiles; import org.apache.iceberg.DataFile; import org.apache.iceberg.FileFormat; +import org.apache.iceberg.PendingUpdate; import org.apache.iceberg.Table; import org.apache.iceberg.catalog.Catalog; import org.apache.iceberg.catalog.Namespace; import org.apache.iceberg.catalog.TableIdentifier; +import org.apache.iceberg.exceptions.CommitFailedException; import org.apache.iceberg.io.TaskWriter; import org.apache.iceberg.io.WriteResult; import org.apache.iceberg.util.Tasks; @@ -54,6 +56,7 @@ import java.util.List; import java.util.Locale; import java.util.Map; import java.util.Set; +import java.util.concurrent.TimeUnit; import static org.apache.iceberg.TableProperties.DEFAULT_FILE_FORMAT; import static org.apache.iceberg.TableProperties.DEFAULT_FILE_FORMAT_DEFAULT; @@ -114,6 +117,42 @@ public class PutIceberg extends AbstractIcebergProcessor { .addValidator(StandardValidators.LONG_VALIDATOR) .build(); +static final PropertyDescriptor NUMBER_OF_COMMIT_RETRIES = new PropertyDescriptor.Builder() +.name("number-of-commit-retries") +.displayName("Number of Commit Retries") +.description("Number of times to retry a commit before failing.") +.required(true) +.defaultValue("10") +.addValidator(StandardValidators.INTEGER_VALIDATOR) +.build(); + +static final PropertyDescriptor MINIMUM_COMMIT_WAIT_TIME = new PropertyDescriptor.Builder() +.name("minimum-commit-wait-time") +.displayName("Minimum Commit Wait Time") +.description("Minimum time to wait before retrying a commit.") +.required(true) +.defaultValue("100 ms") +.addValidator(StandardValidators.TIME_PERIOD_VALIDATOR) +.build(); + +static final PropertyDescriptor MAXIMUM_COMMIT_WAIT_TIME = new PropertyDescriptor.Builder() +.name("maximum-commit-wait-time") +.displayName("Maximum Commit Wait Time") +.description("Maximum time to wait before retrying a commit.") +.required(true) +.defaultValue("2 sec") +.addValidator(StandardValidators.TIME_PERIOD_VALIDATOR) +
[nifi] branch support/nifi-1.x updated: NIFI-11213 Showing version change in older (pre 1.18.0) contained version flows properly (#7017)
This is an automated email from the ASF dual-hosted git repository. bsimon pushed a commit to branch support/nifi-1.x in repository https://gitbox.apache.org/repos/asf/nifi.git The following commit(s) were added to refs/heads/support/nifi-1.x by this push: new 4a6e6751d5 NIFI-11213 Showing version change in older (pre 1.18.0) contained version flows properly (#7017) 4a6e6751d5 is described below commit 4a6e6751d5478514ab6fe937685b057193365f65 Author: simonbence <61191107+simonbe...@users.noreply.github.com> AuthorDate: Mon Mar 20 16:52:07 2023 +0100 NIFI-11213 Showing version change in older (pre 1.18.0) contained version flows properly (#7017) --- .../apache/nifi/util/FlowDifferenceFilters.java| 22 +++--- .../diff/ConciseEvolvingDifferenceDescriptor.java | 2 +- .../registry/flow/diff/FlowDifferenceUtil.java | 50 ++ 3 files changed, 58 insertions(+), 16 deletions(-) diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/util/FlowDifferenceFilters.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/util/FlowDifferenceFilters.java index db714946db..ad2fa76122 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/util/FlowDifferenceFilters.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/util/FlowDifferenceFilters.java @@ -34,6 +34,7 @@ import org.apache.nifi.groups.ProcessGroup; import org.apache.nifi.processor.Relationship; import org.apache.nifi.registry.flow.diff.DifferenceType; import org.apache.nifi.registry.flow.diff.FlowDifference; +import org.apache.nifi.registry.flow.diff.FlowDifferenceUtil; import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedComponent; import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedControllerService; import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedProcessor; @@ -192,22 +193,13 @@ public class FlowDifferenceFilters { final VersionedFlowCoordinates coordinatesB = versionedProcessGroupB.getVersionedFlowCoordinates(); if (coordinatesA != null && coordinatesB != null) { -String registryUrlA = coordinatesA.getRegistryUrl(); -String registryUrlB = coordinatesB.getRegistryUrl(); - -if (registryUrlA != null && registryUrlB != null && !registryUrlA.equals(registryUrlB)) { -if (registryUrlA.endsWith("/")) { -registryUrlA = registryUrlA.substring(0, registryUrlA.length() - 1); -} - -if (registryUrlB.endsWith("/")) { -registryUrlB = registryUrlB.substring(0, registryUrlB.length() - 1); -} - -if (registryUrlA.equals(registryUrlB)) { -return true; -} +if (coordinatesA.getStorageLocation() != null || coordinatesB.getStorageLocation() != null) { +return false; } + +return !FlowDifferenceUtil.areRegistryStrictlyEqual(coordinatesA, coordinatesB) +&& FlowDifferenceUtil.areRegistryUrlsEqual(coordinatesA, coordinatesB) +&& coordinatesA.getVersion() == coordinatesB.getVersion(); } } } diff --git a/nifi-registry/nifi-registry-core/nifi-registry-flow-diff/src/main/java/org/apache/nifi/registry/flow/diff/ConciseEvolvingDifferenceDescriptor.java b/nifi-registry/nifi-registry-core/nifi-registry-flow-diff/src/main/java/org/apache/nifi/registry/flow/diff/ConciseEvolvingDifferenceDescriptor.java index 144f865af4..3fc4e4b1bf 100644 --- a/nifi-registry/nifi-registry-core/nifi-registry-flow-diff/src/main/java/org/apache/nifi/registry/flow/diff/ConciseEvolvingDifferenceDescriptor.java +++ b/nifi-registry/nifi-registry-core/nifi-registry-flow-diff/src/main/java/org/apache/nifi/registry/flow/diff/ConciseEvolvingDifferenceDescriptor.java @@ -80,7 +80,7 @@ public class ConciseEvolvingDifferenceDescriptor implements DifferenceDescriptor final VersionedFlowCoordinates coordinatesB = (VersionedFlowCoordinates) valueB; // If the two vary only by version, then use a more concise message. If anything else is different, then use a fully explanation. -if (Objects.equals(coordinatesA.getRegistryUrl(), coordinatesB.getRegistryUrl()) && Objects.equals(coordinatesA.getBucketId(), coordinatesB.getBucketId()) +if (FlowDifferenceUtil.areRegistryUrlsEqual(coordinatesA, coordinatesB) && Objects.equals(coordinatesA.getBucketId(),
[nifi] branch main updated: NIFI-11213 Showing version change in older (pre 1.18.0) contained version flows properly (#7017)
This is an automated email from the ASF dual-hosted git repository. markap14 pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/nifi.git The following commit(s) were added to refs/heads/main by this push: new 7954ff355c NIFI-11213 Showing version change in older (pre 1.18.0) contained version flows properly (#7017) 7954ff355c is described below commit 7954ff355cbadefd070a3601a91128e380f5aa87 Author: simonbence <61191107+simonbe...@users.noreply.github.com> AuthorDate: Mon Mar 20 16:52:07 2023 +0100 NIFI-11213 Showing version change in older (pre 1.18.0) contained version flows properly (#7017) --- .../apache/nifi/util/FlowDifferenceFilters.java| 22 +++--- .../diff/ConciseEvolvingDifferenceDescriptor.java | 2 +- .../registry/flow/diff/FlowDifferenceUtil.java | 50 ++ 3 files changed, 58 insertions(+), 16 deletions(-) diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/util/FlowDifferenceFilters.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/util/FlowDifferenceFilters.java index db714946db..ad2fa76122 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/util/FlowDifferenceFilters.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/util/FlowDifferenceFilters.java @@ -34,6 +34,7 @@ import org.apache.nifi.groups.ProcessGroup; import org.apache.nifi.processor.Relationship; import org.apache.nifi.registry.flow.diff.DifferenceType; import org.apache.nifi.registry.flow.diff.FlowDifference; +import org.apache.nifi.registry.flow.diff.FlowDifferenceUtil; import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedComponent; import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedControllerService; import org.apache.nifi.registry.flow.mapping.InstantiatedVersionedProcessor; @@ -192,22 +193,13 @@ public class FlowDifferenceFilters { final VersionedFlowCoordinates coordinatesB = versionedProcessGroupB.getVersionedFlowCoordinates(); if (coordinatesA != null && coordinatesB != null) { -String registryUrlA = coordinatesA.getRegistryUrl(); -String registryUrlB = coordinatesB.getRegistryUrl(); - -if (registryUrlA != null && registryUrlB != null && !registryUrlA.equals(registryUrlB)) { -if (registryUrlA.endsWith("/")) { -registryUrlA = registryUrlA.substring(0, registryUrlA.length() - 1); -} - -if (registryUrlB.endsWith("/")) { -registryUrlB = registryUrlB.substring(0, registryUrlB.length() - 1); -} - -if (registryUrlA.equals(registryUrlB)) { -return true; -} +if (coordinatesA.getStorageLocation() != null || coordinatesB.getStorageLocation() != null) { +return false; } + +return !FlowDifferenceUtil.areRegistryStrictlyEqual(coordinatesA, coordinatesB) +&& FlowDifferenceUtil.areRegistryUrlsEqual(coordinatesA, coordinatesB) +&& coordinatesA.getVersion() == coordinatesB.getVersion(); } } } diff --git a/nifi-registry/nifi-registry-core/nifi-registry-flow-diff/src/main/java/org/apache/nifi/registry/flow/diff/ConciseEvolvingDifferenceDescriptor.java b/nifi-registry/nifi-registry-core/nifi-registry-flow-diff/src/main/java/org/apache/nifi/registry/flow/diff/ConciseEvolvingDifferenceDescriptor.java index 144f865af4..3fc4e4b1bf 100644 --- a/nifi-registry/nifi-registry-core/nifi-registry-flow-diff/src/main/java/org/apache/nifi/registry/flow/diff/ConciseEvolvingDifferenceDescriptor.java +++ b/nifi-registry/nifi-registry-core/nifi-registry-flow-diff/src/main/java/org/apache/nifi/registry/flow/diff/ConciseEvolvingDifferenceDescriptor.java @@ -80,7 +80,7 @@ public class ConciseEvolvingDifferenceDescriptor implements DifferenceDescriptor final VersionedFlowCoordinates coordinatesB = (VersionedFlowCoordinates) valueB; // If the two vary only by version, then use a more concise message. If anything else is different, then use a fully explanation. -if (Objects.equals(coordinatesA.getRegistryUrl(), coordinatesB.getRegistryUrl()) && Objects.equals(coordinatesA.getBucketId(), coordinatesB.getBucketId()) +if (FlowDifferenceUtil.areRegistryUrlsEqual(coordinatesA, coordinatesB) && Objects.equals(coordinatesA.getBucketId(), coordinatesB.getBucketId())
[nifi] 01/03: NIFI-11299 Upgraded SLF4J from 2.0.6 to 2.0.7
This is an automated email from the ASF dual-hosted git repository. exceptionfactory pushed a commit to branch support/nifi-1.x in repository https://gitbox.apache.org/repos/asf/nifi.git commit 626edcd80c639f839a6b596a1ce5db28e66be775 Author: Pierre Villard AuthorDate: Sat Mar 18 18:34:35 2023 +0200 NIFI-11299 Upgraded SLF4J from 2.0.6 to 2.0.7 This closes #7054 Signed-off-by: David Handermann --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 19a900af70..2c0f5bfae9 100644 --- a/pom.xml +++ b/pom.xml @@ -118,7 +118,7 @@ 4.4.15 1.71 1.17.6 -2.0.6 +2.0.7 2.3.0 9.4.50.v20221201 2.14.1
[nifi] 02/03: NIFI-11300 Upgraded json-smart from 2.4.8 to 2.4.10
This is an automated email from the ASF dual-hosted git repository. exceptionfactory pushed a commit to branch support/nifi-1.x in repository https://gitbox.apache.org/repos/asf/nifi.git commit 073d107f6eaeabd585f84002472eb8ed94080382 Author: Pierre Villard AuthorDate: Sat Mar 18 18:41:19 2023 +0200 NIFI-11300 Upgraded json-smart from 2.4.8 to 2.4.10 This closes #7055 Signed-off-by: David Handermann --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 2c0f5bfae9..75723036c2 100644 --- a/pom.xml +++ b/pom.xml @@ -126,7 +126,7 @@ 2.3.5 1.3.2 2.3.3 -2.4.8 +2.4.10 3.0.14 3.0.8-01 3.0.0-M8
[nifi] branch support/nifi-1.x updated (171c2ae670 -> c15f47da92)
This is an automated email from the ASF dual-hosted git repository. exceptionfactory pushed a change to branch support/nifi-1.x in repository https://gitbox.apache.org/repos/asf/nifi.git from 171c2ae670 NIFI-11263: Backported. Add case-insensitive and order independent field mapping to PutIceberg record converter new 626edcd80c NIFI-11299 Upgraded SLF4J from 2.0.6 to 2.0.7 new 073d107f6e NIFI-11300 Upgraded json-smart from 2.4.8 to 2.4.10 new c15f47da92 NIFI-11301 Fixed typos in ISPEnrichIP and DistributeLoad The 3 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference. Summary of changes: .../src/main/java/org/apache/nifi/processors/ISPEnrichIP.java | 2 +- .../main/java/org/apache/nifi/processors/standard/DistributeLoad.java | 2 +- pom.xml | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-)
[nifi] 03/03: NIFI-11301 Fixed typos in ISPEnrichIP and DistributeLoad
This is an automated email from the ASF dual-hosted git repository. exceptionfactory pushed a commit to branch support/nifi-1.x in repository https://gitbox.apache.org/repos/asf/nifi.git commit c15f47da92e51b193d673f6c4abf691ffe9142c4 Author: Dustin Rodrigues AuthorDate: Sat Mar 18 19:53:38 2023 -0400 NIFI-11301 Fixed typos in ISPEnrichIP and DistributeLoad This closes #7056 Signed-off-by: David Handermann --- .../src/main/java/org/apache/nifi/processors/ISPEnrichIP.java | 2 +- .../main/java/org/apache/nifi/processors/standard/DistributeLoad.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/nifi-nar-bundles/nifi-enrich-bundle/nifi-enrich-processors/src/main/java/org/apache/nifi/processors/ISPEnrichIP.java b/nifi-nar-bundles/nifi-enrich-bundle/nifi-enrich-processors/src/main/java/org/apache/nifi/processors/ISPEnrichIP.java index 7365c2f960..8a03d2ae0b 100644 --- a/nifi-nar-bundles/nifi-enrich-bundle/nifi-enrich-processors/src/main/java/org/apache/nifi/processors/ISPEnrichIP.java +++ b/nifi-nar-bundles/nifi-enrich-bundle/nifi-enrich-processors/src/main/java/org/apache/nifi/processors/ISPEnrichIP.java @@ -47,7 +47,7 @@ import java.util.concurrent.TimeUnit; @Tags({"ISP", "enrich", "ip", "maxmind"}) @InputRequirement(Requirement.INPUT_REQUIRED) @CapabilityDescription("Looks up ISP information for an IP address and adds the information to FlowFile attributes. The " -+ "ISP data is provided as a MaxMind ISP database (Note that this is NOT the same as the GeoLite database utilized" + ++ "ISP data is provided as a MaxMind ISP database. (Note that this is NOT the same as the GeoLite database utilized " + "by some geo enrichment tools). The attribute that contains the IP address to lookup is provided by the " + "'IP Address Attribute' property. If the name of the attribute provided is 'X', then the the attributes added by" + " enrichment will take the form X.isp.") diff --git a/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/DistributeLoad.java b/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/DistributeLoad.java index 1009846373..1e05d96aaf 100644 --- a/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/DistributeLoad.java +++ b/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/DistributeLoad.java @@ -67,7 +67,7 @@ import org.apache.nifi.processor.util.StandardValidators; @TriggerWhenAnyDestinationAvailable @Tags({"distribute", "load balance", "route", "round robin", "weighted"}) @CapabilityDescription("Distributes FlowFiles to downstream processors based on a Distribution Strategy. If using the Round Robin " -+ "strategy, the default is to assign each destination a weighting of 1 (evenly distributed). However, optional properties" ++ "strategy, the default is to assign each destination a weighting of 1 (evenly distributed). However, optional properties " + "can be added to the change this; adding a property with the name '5' and value '10' means that the relationship with name " + "'5' will be receive 10 FlowFiles in each iteration instead of 1.") @DynamicProperty(name = "The relationship name (positive number)", value = "The relationship Weight (positive number)", description = "Adding a "
[nifi] 01/03: NIFI-11299 Upgraded SLF4J from 2.0.6 to 2.0.7
This is an automated email from the ASF dual-hosted git repository. exceptionfactory pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/nifi.git commit 76244b18bca2c20f0b77f58c871e938aded8c952 Author: Pierre Villard AuthorDate: Sat Mar 18 18:34:35 2023 +0200 NIFI-11299 Upgraded SLF4J from 2.0.6 to 2.0.7 This closes #7054 Signed-off-by: David Handermann --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index edc9e987a1..f9e2a6b10f 100644 --- a/pom.xml +++ b/pom.xml @@ -118,7 +118,7 @@ 4.4.15 1.71 1.17.6 -2.0.6 +2.0.7 2.3.0 9.4.50.v20221201 2.14.1
[nifi] 03/03: NIFI-11301 Fixed typos in ISPEnrichIP and DistributeLoad
This is an automated email from the ASF dual-hosted git repository. exceptionfactory pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/nifi.git commit cb6e530a3cfc1b44aa9e52dc7a32402eb86b1b37 Author: Dustin Rodrigues AuthorDate: Sat Mar 18 19:53:38 2023 -0400 NIFI-11301 Fixed typos in ISPEnrichIP and DistributeLoad This closes #7056 Signed-off-by: David Handermann --- .../src/main/java/org/apache/nifi/processors/ISPEnrichIP.java | 2 +- .../main/java/org/apache/nifi/processors/standard/DistributeLoad.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/nifi-nar-bundles/nifi-enrich-bundle/nifi-enrich-processors/src/main/java/org/apache/nifi/processors/ISPEnrichIP.java b/nifi-nar-bundles/nifi-enrich-bundle/nifi-enrich-processors/src/main/java/org/apache/nifi/processors/ISPEnrichIP.java index 7365c2f960..8a03d2ae0b 100644 --- a/nifi-nar-bundles/nifi-enrich-bundle/nifi-enrich-processors/src/main/java/org/apache/nifi/processors/ISPEnrichIP.java +++ b/nifi-nar-bundles/nifi-enrich-bundle/nifi-enrich-processors/src/main/java/org/apache/nifi/processors/ISPEnrichIP.java @@ -47,7 +47,7 @@ import java.util.concurrent.TimeUnit; @Tags({"ISP", "enrich", "ip", "maxmind"}) @InputRequirement(Requirement.INPUT_REQUIRED) @CapabilityDescription("Looks up ISP information for an IP address and adds the information to FlowFile attributes. The " -+ "ISP data is provided as a MaxMind ISP database (Note that this is NOT the same as the GeoLite database utilized" + ++ "ISP data is provided as a MaxMind ISP database. (Note that this is NOT the same as the GeoLite database utilized " + "by some geo enrichment tools). The attribute that contains the IP address to lookup is provided by the " + "'IP Address Attribute' property. If the name of the attribute provided is 'X', then the the attributes added by" + " enrichment will take the form X.isp.") diff --git a/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/DistributeLoad.java b/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/DistributeLoad.java index fd4ac28b4d..812730d9c2 100644 --- a/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/DistributeLoad.java +++ b/nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/DistributeLoad.java @@ -61,7 +61,7 @@ import org.apache.nifi.processor.util.StandardValidators; @TriggerWhenAnyDestinationAvailable @Tags({"distribute", "load balance", "route", "round robin", "weighted"}) @CapabilityDescription("Distributes FlowFiles to downstream processors based on a Distribution Strategy. If using the Round Robin " -+ "strategy, the default is to assign each destination a weighting of 1 (evenly distributed). However, optional properties" ++ "strategy, the default is to assign each destination a weighting of 1 (evenly distributed). However, optional properties " + "can be added to the change this; adding a property with the name '5' and value '10' means that the relationship with name " + "'5' will be receive 10 FlowFiles in each iteration instead of 1.") @DynamicProperty(name = "The relationship name (positive number)", value = "The relationship Weight (positive number)", description = "Adding a "
[nifi] 02/03: NIFI-11300 Upgraded json-smart from 2.4.8 to 2.4.10
This is an automated email from the ASF dual-hosted git repository. exceptionfactory pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/nifi.git commit d563f522d45300b7ad11562bae59e7948e731366 Author: Pierre Villard AuthorDate: Sat Mar 18 18:41:19 2023 +0200 NIFI-11300 Upgraded json-smart from 2.4.8 to 2.4.10 This closes #7055 Signed-off-by: David Handermann --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index f9e2a6b10f..5b1fa24e1a 100644 --- a/pom.xml +++ b/pom.xml @@ -126,7 +126,7 @@ 2.3.5 1.3.2 2.3.3 -2.4.8 +2.4.10 3.0.14 3.0.8-01 3.0.0-M8
[nifi] branch main updated (4bec56ed81 -> cb6e530a3c)
This is an automated email from the ASF dual-hosted git repository. exceptionfactory pushed a change to branch main in repository https://gitbox.apache.org/repos/asf/nifi.git from 4bec56ed81 NIFI-11296 Improved code reusability of GRPC modules new 76244b18bc NIFI-11299 Upgraded SLF4J from 2.0.6 to 2.0.7 new d563f522d4 NIFI-11300 Upgraded json-smart from 2.4.8 to 2.4.10 new cb6e530a3c NIFI-11301 Fixed typos in ISPEnrichIP and DistributeLoad The 3 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference. Summary of changes: .../src/main/java/org/apache/nifi/processors/ISPEnrichIP.java | 2 +- .../main/java/org/apache/nifi/processors/standard/DistributeLoad.java | 2 +- pom.xml | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-)