Repository: nifi Updated Branches: refs/heads/master 6356d7b9e -> 0305ca0fb
NIFI-5186: - Updating UI to support showing when a component is validating. Project: http://git-wip-us.apache.org/repos/asf/nifi/repo Commit: http://git-wip-us.apache.org/repos/asf/nifi/commit/568288db Tree: http://git-wip-us.apache.org/repos/asf/nifi/tree/568288db Diff: http://git-wip-us.apache.org/repos/asf/nifi/diff/568288db Branch: refs/heads/master Commit: 568288dbcd143bb874d64417f0ecd1fe10dfee9e Parents: 6356d7b Author: Matt Gilman <[email protected]> Authored: Fri May 18 14:56:10 2018 -0400 Committer: Scott Aslan <[email protected]> Committed: Tue May 22 11:05:28 2018 -0400 ---------------------------------------------------------------------- .../controller/status/ProcessGroupStatus.java | 4 +- .../nifi/controller/status/RunStatus.java | 1 + .../nifi/cluster/manager/ErrorMerger.java | 20 +++--- .../nifi/cluster/manager/StatusMerger.java | 14 ++-- .../apache/nifi/controller/FlowController.java | 71 ++++++++++---------- .../nifi-web-ui/src/main/webapp/css/graph.css | 45 ++++++++++++- .../nifi-web-ui/src/main/webapp/css/main.css | 20 ++++++ .../src/main/webapp/css/slick-nifi-theme.css | 12 ++-- .../propertytable/jquery.propertytable.js | 6 +- .../js/nf/canvas/nf-connection-configuration.js | 2 +- .../js/nf/canvas/nf-controller-services.js | 51 ++++++++------ .../main/webapp/js/nf/canvas/nf-flow-version.js | 2 +- .../webapp/js/nf/canvas/nf-policy-management.js | 4 +- .../main/webapp/js/nf/canvas/nf-processor.js | 51 +++++++++++--- .../webapp/js/nf/canvas/nf-queue-listing.js | 2 +- .../src/main/webapp/js/nf/canvas/nf-settings.js | 45 ++++++++----- .../webapp/js/nf/canvas/nf-variable-registry.js | 4 +- .../webapp/js/nf/cluster/nf-cluster-table.js | 8 +-- .../webapp/js/nf/counters/nf-counters-table.js | 2 +- .../webapp/js/nf/history/nf-history-table.js | 2 +- .../src/main/webapp/js/nf/nf-common.js | 2 +- .../js/nf/provenance/nf-provenance-table.js | 2 +- .../webapp/js/nf/summary/nf-summary-table.js | 36 +++++----- .../js/nf/templates/nf-templates-table.js | 6 +- .../main/webapp/js/nf/users/nf-users-table.js | 6 +- 25 files changed, 273 insertions(+), 145 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-api/src/main/java/org/apache/nifi/controller/status/ProcessGroupStatus.java ---------------------------------------------------------------------- diff --git a/nifi-api/src/main/java/org/apache/nifi/controller/status/ProcessGroupStatus.java b/nifi-api/src/main/java/org/apache/nifi/controller/status/ProcessGroupStatus.java index a6acbc1..f9433d7 100644 --- a/nifi-api/src/main/java/org/apache/nifi/controller/status/ProcessGroupStatus.java +++ b/nifi-api/src/main/java/org/apache/nifi/controller/status/ProcessGroupStatus.java @@ -481,7 +481,9 @@ public class ProcessGroupStatus implements Cloneable { // and should not differ amongst nodes. however, whether a processor is invalid // can be driven by environmental conditions. this check allows any of those to // take precedence over the configured run status. - if (RunStatus.Invalid.equals(statusToMerge.getRunStatus())) { + if (RunStatus.Validating.equals(statusToMerge.getRunStatus())) { + merged.setRunStatus(RunStatus.Validating); + } else if (RunStatus.Invalid.equals(statusToMerge.getRunStatus())) { merged.setRunStatus(RunStatus.Invalid); } } http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-api/src/main/java/org/apache/nifi/controller/status/RunStatus.java ---------------------------------------------------------------------- diff --git a/nifi-api/src/main/java/org/apache/nifi/controller/status/RunStatus.java b/nifi-api/src/main/java/org/apache/nifi/controller/status/RunStatus.java index 1b7c43d..e0e0027 100644 --- a/nifi-api/src/main/java/org/apache/nifi/controller/status/RunStatus.java +++ b/nifi-api/src/main/java/org/apache/nifi/controller/status/RunStatus.java @@ -23,6 +23,7 @@ public enum RunStatus { Running, Stopped, + Validating, Invalid, Disabled; } http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/ErrorMerger.java ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/ErrorMerger.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/ErrorMerger.java index 9eec1d8..9e9252e 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/ErrorMerger.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/ErrorMerger.java @@ -16,14 +16,14 @@ */ package org.apache.nifi.cluster.manager; +import org.apache.nifi.cluster.protocol.NodeIdentifier; +import org.apache.nifi.web.api.dto.ProcessorDTO; + import java.util.Collection; import java.util.HashSet; import java.util.Map; import java.util.Set; -import org.apache.nifi.cluster.protocol.NodeIdentifier; -import org.apache.nifi.web.api.dto.ProcessorDTO; - public final class ErrorMerger { private ErrorMerger() {} @@ -72,13 +72,6 @@ public final class ErrorMerger { * @return {@link ProcessorDTO#INVALID} if any status is invalid, else {@link ProcessorDTO#VALIDATING} if any status is validating, else {@link ProcessorDTO#VALID} */ public static <T> String mergeValidationStatus(final Collection<String> validationStatuses) { - final boolean anyInvalid = validationStatuses.stream() - .anyMatch(status -> ProcessorDTO.INVALID.equalsIgnoreCase(status)); - - if (anyInvalid) { - return ProcessorDTO.INVALID; - } - final boolean anyValidating = validationStatuses.stream() .anyMatch(status -> ProcessorDTO.VALIDATING.equalsIgnoreCase(status)); @@ -86,6 +79,13 @@ public final class ErrorMerger { return ProcessorDTO.VALIDATING; } + final boolean anyInvalid = validationStatuses.stream() + .anyMatch(status -> ProcessorDTO.INVALID.equalsIgnoreCase(status)); + + if (anyInvalid) { + return ProcessorDTO.INVALID; + } + return ProcessorDTO.VALID; } } http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/StatusMerger.java ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/StatusMerger.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/StatusMerger.java index dd10b5b..d15e4f6 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/StatusMerger.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-cluster/src/main/java/org/apache/nifi/cluster/manager/StatusMerger.java @@ -415,13 +415,15 @@ public class StatusMerger { target.setType(toMerge.getType()); } - // if the status to merge is invalid allow it to take precedence. whether the + // if the status to merge is validating/invalid allow it to take precedence. whether the // processor run status is disabled/stopped/running is part of the flow configuration - // and should not differ amongst nodes. however, whether a processor is invalid + // and should not differ amongst nodes. however, whether a processor is validating/invalid // can be driven by environmental conditions. this check allows any of those to // take precedence over the configured run status. - if (RunStatus.Invalid.name().equals(toMerge.getRunStatus())) { - target.setRunStatus(RunStatus.Invalid.name()); + if (RunStatus.Validating.toString().equals(toMerge.getRunStatus())) { + target.setRunStatus(RunStatus.Validating.toString()); + } else if (RunStatus.Invalid.toString().equals(toMerge.getRunStatus())) { + target.setRunStatus(RunStatus.Invalid.toString()); } target.setBytesRead(target.getBytesRead() + toMerge.getBytesRead()); @@ -573,8 +575,8 @@ public class StatusMerger { // should be unnecessary here since ports run status not should be affected by // environmental conditions but doing so in case that changes - if (RunStatus.Invalid.name().equals(toMerge.getRunStatus())) { - target.setRunStatus(RunStatus.Invalid.name()); + if (RunStatus.Invalid.toString().equals(toMerge.getRunStatus())) { + target.setRunStatus(RunStatus.Invalid.toString()); } updatePrettyPrintedFields(target); http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/FlowController.java ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/FlowController.java b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/FlowController.java index 091f0fb..98b33ec 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/FlowController.java +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/FlowController.java @@ -16,41 +16,6 @@ */ package org.apache.nifi.controller; -import static java.util.Objects.requireNonNull; - -import java.io.ByteArrayInputStream; -import java.io.IOException; -import java.io.InputStream; -import java.io.OutputStream; -import java.lang.management.GarbageCollectorMXBean; -import java.lang.management.ManagementFactory; -import java.net.URL; -import java.util.ArrayList; -import java.util.Collection; -import java.util.Collections; -import java.util.Date; -import java.util.HashMap; -import java.util.HashSet; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Map; -import java.util.Set; -import java.util.UUID; -import java.util.concurrent.CompletableFuture; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.ConcurrentMap; -import java.util.concurrent.Future; -import java.util.concurrent.ScheduledExecutorService; -import java.util.concurrent.ScheduledFuture; -import java.util.concurrent.TimeUnit; -import java.util.concurrent.atomic.AtomicBoolean; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.atomic.AtomicReference; -import java.util.concurrent.locks.ReentrantReadWriteLock; -import java.util.stream.Collectors; - -import javax.net.ssl.SSLContext; - import org.apache.commons.collections4.Predicate; import org.apache.commons.lang3.StringUtils; import org.apache.nifi.action.Action; @@ -269,6 +234,40 @@ import org.apache.zookeeper.server.quorum.QuorumPeerConfig.ConfigException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import javax.net.ssl.SSLContext; +import java.io.ByteArrayInputStream; +import java.io.IOException; +import java.io.InputStream; +import java.io.OutputStream; +import java.lang.management.GarbageCollectorMXBean; +import java.lang.management.ManagementFactory; +import java.net.URL; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.Date; +import java.util.HashMap; +import java.util.HashSet; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.UUID; +import java.util.concurrent.CompletableFuture; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.ConcurrentMap; +import java.util.concurrent.Future; +import java.util.concurrent.ScheduledExecutorService; +import java.util.concurrent.ScheduledFuture; +import java.util.concurrent.TimeUnit; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.concurrent.atomic.AtomicInteger; +import java.util.concurrent.atomic.AtomicReference; +import java.util.concurrent.locks.ReentrantReadWriteLock; +import java.util.stream.Collectors; + +import static java.util.Objects.requireNonNull; + public class FlowController implements EventAccess, ControllerServiceProvider, ReportingTaskProvider, QueueProvider, Authorizable, ProvenanceAuthorizableFactory, NodeTypeProvider, IdentifierLookup, ReloadComponent { @@ -3306,6 +3305,8 @@ public class FlowController implements EventAccess, ControllerServiceProvider, R status.setRunStatus(RunStatus.Disabled); } else if (ScheduledState.RUNNING.equals(procNode.getScheduledState())) { status.setRunStatus(RunStatus.Running); + } else if (procNode.getValidationStatus() == ValidationStatus.VALIDATING) { + status.setRunStatus(RunStatus.Validating); } else if (procNode.getValidationStatus() == ValidationStatus.INVALID) { status.setRunStatus(RunStatus.Invalid); } else { http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/graph.css ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/graph.css b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/graph.css index 95fbbbd..15daa76 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/graph.css +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/graph.css @@ -141,6 +141,48 @@ path.component-comments { stroke: #000; } +text.spin { + -webkit-animation-name: rotate; + -webkit-animation-duration: 2s; + -webkit-animation-iteration-count: infinite; + -webkit-animation-timing-function: linear; + -moz-animation-name: rotate; + -moz-animation-duration: 2s; + -moz-animation-iteration-count: infinite; + -moz-animation-timing-function: linear; + animation-name: rotate; + animation-duration: 2s; + animation-iteration-count: infinite; + animation-timing-function: linear; +} + +@-webkit-keyframes rotate { + from { + -webkit-transform: rotate(0deg); + } + to { + -webkit-transform: rotate(360deg); + } +} + +@-moz-keyframes rotate { + from { + -moz-transform: rotate(0deg); + } + to { + -moz-transform: rotate(360deg); + } +} + +@keyframes rotate { + from { + transform: rotate(0deg); + } + to { + transform: rotate(360deg); + } +} + /* Selection */ @@ -210,7 +252,8 @@ text.is-primary { } text.run-status-icon { - font-size: 13px; + font-size: 14px; + transform-origin: 62px 18px 0; } /* http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/main.css ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/main.css b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/main.css index 0cd66c2..aeff304 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/main.css +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/main.css @@ -138,6 +138,26 @@ div.context-menu-provenance { text-shadow: 0 0 4px rgba(255,255,255,1); } +.validating { + float: left; + width: 12px; + height: 12px; + line-height: 12px !important; + margin-top: 5px !important; + color: #a8a8a8 !important; + fill: #a8a8a8 !important; + text-shadow: 0 0 4px rgba(255,255,255,1); + transform-origin: 6px 6px 0; +} + +.validating:before { + font-family: FontAwesome; + font-size: 12px; + content: "\f1ce"; + color: #a8a8a8; + text-shadow: 0 0 4px rgba(255,255,255,1); +} + .transmitting { float: left; color: #44a3cf !important; http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/slick-nifi-theme.css ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/slick-nifi-theme.css b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/slick-nifi-theme.css index 398f9cd..bc77b6d 100755 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/slick-nifi-theme.css +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/css/slick-nifi-theme.css @@ -72,21 +72,23 @@ .slick-viewport .fa { color: #004849; line-height: 22px; - margin-top: 0 !important; + margin-top: 0; width: 12px; height: 12px; float: left; - margin-right: 3px !important; + margin-right: 5px; + text-align: center; } .slick-viewport .icon { color: #004849; line-height: 24px; - margin-top: 0 !important; + margin-top: 0; width: 12px; height: 12px; float: left; - margin-right: 3px !important; + margin-right: 5px; + text-align: center; } .slick-header.ui-state-default, .slick-headerrow.ui-state-default { @@ -125,7 +127,7 @@ div.status-text { padding-left: 4px; - line-height: normal; + line-height: 22px; overflow: hidden; text-overflow: ellipsis; float: left; http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/jquery/propertytable/jquery.propertytable.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/jquery/propertytable/jquery.propertytable.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/jquery/propertytable/jquery.propertytable.js index abd27b2..2aa96a4 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/jquery/propertytable/jquery.propertytable.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/jquery/propertytable/jquery.propertytable.js @@ -1195,7 +1195,7 @@ // show the property description if applicable if (nfCommon.isDefinedAndNotNull(propertyDescriptor)) { if (!nfCommon.isBlank(propertyDescriptor.description) || !nfCommon.isBlank(propertyDescriptor.defaultValue) || !nfCommon.isBlank(propertyDescriptor.supportsEl)) { - $('<div class="fa fa-question-circle" alt="Info" style="float: right; margin-right: 6px; margin-top: 4px;"></div>').appendTo(cellContent); + $('<div class="fa fa-question-circle" alt="Info" style="float: right;"></div>').appendTo(cellContent); $('<span class="hidden property-descriptor-name"></span>').text(dataContext.property).appendTo(cellContent); nameWidthOffset = 46; // 10 + icon width (10) + icon margin (6) + padding (20) } @@ -1299,7 +1299,7 @@ $.each(propertyDescriptor.allowableValues, function (_, allowableValueEntity) { var allowableValue = allowableValueEntity.allowableValue; if (allowableValue.value === dataContext.value) { - markup += '<div class="pointer go-to-service fa fa-long-arrow-right" title="Go To" style="margin-top: 2px" ></div>'; + markup += '<div class="pointer go-to-service fa fa-long-arrow-right" title="Go To"></div>'; return false; } }); @@ -1307,7 +1307,7 @@ // allow user defined properties to be removed if (options.readOnly !== true && dataContext.type === 'userDefined') { - markup += '<div title="Delete" class="delete-property pointer fa fa-trash" style="margin-top: 2px" ></div>'; + markup += '<div title="Delete" class="delete-property pointer fa fa-trash"></div>'; } return markup; http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-connection-configuration.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-connection-configuration.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-connection-configuration.js index e206bf9..82c34e5 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-connection-configuration.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-connection-configuration.js @@ -1256,7 +1256,7 @@ // add the description if applicable if (nfCommon.isDefinedAndNotNull(prioritizerType.description)) { - $('<div class="fa fa-question-circle" style="float: right; margin-right: 5px;""></div>').appendTo(prioritizer).qtip($.extend({ + $('<div class="fa fa-question-circle"></div>').appendTo(prioritizer).qtip($.extend({ content: nfCommon.escapeHtml(prioritizerType.description) }, nfCommon.config.tooltipConfig)); } http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-controller-services.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-controller-services.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-controller-services.js index 9797a47..c15d1ab 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-controller-services.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-controller-services.js @@ -814,12 +814,20 @@ var bType = nfCommon.isDefinedAndNotNull(b.component[sortDetails.columnId]) ? nfCommon.substringAfterLast(b.component[sortDetails.columnId], '.') : ''; return aType === bType ? 0 : aType > bType ? 1 : -1; } else if (sortDetails.columnId === 'state') { - var aState = 'Invalid'; - if (nfCommon.isEmpty(a.component.validationErrors)) { + var aState; + if (a.component.validationStatus === 'VALIDATING') { + aState = 'Validating'; + } else if (a.component.validationStatus === 'INVALID') { + aState = 'Invalid'; + } else { aState = nfCommon.isDefinedAndNotNull(a.component[sortDetails.columnId]) ? a.component[sortDetails.columnId] : ''; } - var bState = 'Invalid'; - if (nfCommon.isEmpty(b.component.validationErrors)) { + var bState; + if (a.component.validationStatus === 'VALIDATING') { + bState = 'Validating'; + } else if (a.component.validationStatus === 'INVALID') { + bState = 'Invalid'; + } else { bState = nfCommon.isDefinedAndNotNull(b.component[sortDetails.columnId]) ? b.component[sortDetails.columnId] : ''; } return aState === bState ? 0 : aState > bState ? 1 : -1; @@ -858,17 +866,17 @@ } // always include a button to view the usage - var markup = '<div title="Usage" class="pointer controller-service-usage fa fa-book" style="margin-top: 5px; margin-right: 3px;" ></div>'; + var markup = '<div title="Usage" class="pointer controller-service-usage fa fa-book"></div>'; var hasErrors = !nfCommon.isEmpty(dataContext.component.validationErrors); var hasBulletins = !nfCommon.isEmpty(dataContext.bulletins); if (hasErrors) { - markup += '<div class="pointer has-errors fa fa-warning" style="margin-top: 4px; margin-right: 3px; float: left;" ></div>'; + markup += '<div class="pointer has-errors fa fa-warning"></div>'; } if (hasBulletins) { - markup += '<div class="has-bulletins fa fa-sticky-note-o" style="margin-top: 5px; margin-right: 3px; float: left;"></div>'; + markup += '<div class="has-bulletins fa fa-sticky-note-o"></div>'; } if (hasErrors || hasBulletins) { @@ -885,7 +893,10 @@ // determine the appropriate label var icon = '', label = ''; - if (!nfCommon.isEmpty(dataContext.component.validationErrors)) { + if (dataContext.component.validationStatus === 'VALIDATING') { + icon = 'validating fa fa-spin fa-circle-notch'; + label = 'Validating'; + } else if (dataContext.component.validationStatus === 'INVALID') { icon = 'invalid fa fa-warning'; label = 'Invalid'; } else { @@ -905,8 +916,8 @@ } // format the markup - var formattedValue = '<div layout="row"><div class="' + icon + '" style="margin-top: 5px;"></div>'; - return formattedValue + '<div class="status-text" style="margin-top: 4px;">' + label + '</div></div>'; + var formattedValue = '<div layout="row"><div class="' + icon + '"></div>'; + return formattedValue + '<div class="status-text">' + label + '</div></div>'; }; var controllerServiceActionFormatter = function (row, cell, value, columnDef, dataContext) { @@ -928,43 +939,43 @@ if (dataContext.permissions.canWrite) { // write permission... allow actions based on the current state of the service if (dataContext.component.state === 'ENABLED' || dataContext.component.state === 'ENABLING') { - markup += '<div class="pointer view-controller-service fa fa-gear" title="View Configuration" style="margin-top: 2px; margin-right: 3px;" ></div>'; - markup += '<div class="pointer disable-controller-service icon icon-enable-false" title="Disable" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div class="pointer view-controller-service fa fa-gear" title="View Configuration"></div>'; + markup += '<div class="pointer disable-controller-service icon icon-enable-false" title="Disable"></div>'; } else if (dataContext.component.state === 'DISABLED') { - markup += '<div class="pointer edit-controller-service fa fa-gear" title="Configure" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div class="pointer edit-controller-service fa fa-gear" title="Configure"></div>'; // if there are no validation errors allow enabling if (nfCommon.isEmpty(dataContext.component.validationErrors)) { - markup += '<div class="pointer enable-controller-service fa fa-flash" title="Enable" style="margin-top: 2px; margin-right: 3px;"></div>'; + markup += '<div class="pointer enable-controller-service fa fa-flash" title="Enable"></div>'; } if (dataContext.component.multipleVersionsAvailable === true) { - markup += '<div title="Change Version" class="pointer change-version-controller-service fa fa-exchange" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="Change Version" class="pointer change-version-controller-service fa fa-exchange"></div>'; } if (canWriteControllerServiceParent(dataContext)) { - markup += '<div class="pointer delete-controller-service fa fa-trash" title="Remove" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div class="pointer delete-controller-service fa fa-trash" title="Remove"></div>'; } } if (dataContext.component.persistsState === true) { - markup += '<div title="View State" class="pointer view-state-controller-service fa fa-tasks" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="View State" class="pointer view-state-controller-service fa fa-tasks"></div>'; } } else { // no write permission... allow viewing configuration if in current group if (definedByCurrentGroup === true) { - markup += '<div class="pointer view-controller-service fa fa-gear" title="View Configuration" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div class="pointer view-controller-service fa fa-gear" title="View Configuration"></div>'; } } } else { // not defined in current group... show go to arrow - markup += '<div class="pointer go-to-controller-service fa fa-long-arrow-right" title="Go To" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div class="pointer go-to-controller-service fa fa-long-arrow-right" title="Go To"></div>'; } } // allow policy configuration conditionally if (nfCanvasUtils.isManagedAuthorizer() && nfCommon.canAccessTenants()) { - markup += '<div title="Access Policies" class="pointer edit-access-policies fa fa-key" style="margin-top: 2px;"></div>'; + markup += '<div title="Access Policies" class="pointer edit-access-policies fa fa-key"></div>'; } return markup; http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-flow-version.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-flow-version.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-flow-version.js index ebbfd25..2bb45f9 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-flow-version.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-flow-version.js @@ -618,7 +618,7 @@ var markup = ''; if (dataContext.differenceType !== 'Component Removed' && nfCommon.isDefinedAndNotNull(dataContext.processGroupId)) { - markup += '<div class="pointer go-to-component fa fa-long-arrow-right" title="Go To" style="margin-top: 2px" ></div>'; + markup += '<div class="pointer go-to-component fa fa-long-arrow-right" title="Go To"></div>'; } return markup; http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-policy-management.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-policy-management.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-policy-management.js index c0da481..b0f1d43 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-policy-management.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-policy-management.js @@ -200,7 +200,7 @@ }, _renderGroup: function (ul, match) { var groupLabel = $('<span></span>').text(match.component.identity); - var groupContent = $('<a></a>').append('<div class="fa fa-users" style="margin-right: 5px;"></div>').append(groupLabel); + var groupContent = $('<a></a>').append('<div class="fa fa-users"></div>').append(groupLabel); return $('<li></li>').data('ui-autocomplete-item', match).append(groupContent).appendTo(ul); } }); @@ -594,7 +594,7 @@ var identityFormatter = function (row, cell, value, columnDef, dataContext) { var markup = ''; if (dataContext.type === 'group') { - markup += '<div class="fa fa-users" style="margin-right: 5px;"></div>'; + markup += '<div class="fa fa-users"></div>'; } markup += nfCommon.escapeHtml(dataContext.component.identity); http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-processor.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-processor.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-processor.js index 71d6de9..751caac 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-processor.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-processor.js @@ -259,7 +259,9 @@ .attrs({ 'class': 'run-status-icon', 'x': 55, - 'y': 23 + 'y': 23, + 'width': 14, + 'height': 14 }); // processor type @@ -796,6 +798,35 @@ }; /** + * Determines whether the specific component needs a tooltip. + * + * @param d + * @return if a tip is required + */ + var needsTip = function (d) { + return (d.permissions.canRead && !nfCommon.isEmpty(d.component.validationErrors)) || d.status.aggregateSnapshot.runStatus === 'Validating'; + }; + + /** + * Gets the tooltip content. + * + * @param d + * @return the tip content + */ + var getTip = function (d) { + if (d.permissions.canRead && !nfCommon.isEmpty(d.component.validationErrors)) { + var list = nfCommon.formatUnorderedList(d.component.validationErrors); + if (list === null || list.length === 0) { + return ''; + } else { + return list; + } + } else { + return 'Validating...'; + } + }; + + /** * Updates the stats for the processors in the specified selection. * * @param {selection} updated The processors to update @@ -811,7 +842,9 @@ 'fill': function (d) { var fill = '#728e9b'; - if (d.status.aggregateSnapshot.runStatus === 'Invalid') { + if (d.status.aggregateSnapshot.runStatus === 'Validating') { + fill = '#a8a8a8'; + } else if (d.status.aggregateSnapshot.runStatus === 'Invalid') { fill = '#cf9f5d'; } else if (d.status.aggregateSnapshot.runStatus === 'Running') { fill = '#7dc7a0'; @@ -829,10 +862,15 @@ return family; } }) + .classed('fa-spin', function (d) { + return d.status.aggregateSnapshot.runStatus === 'Validating'; + }) .text(function (d) { var img = ''; if (d.status.aggregateSnapshot.runStatus === 'Disabled') { img = '\ue802'; + } else if (d.status.aggregateSnapshot.runStatus === 'Validating') { + img = '\uf1ce'; } else if (d.status.aggregateSnapshot.runStatus === 'Invalid') { img = '\uf071'; } else if (d.status.aggregateSnapshot.runStatus === 'Running') { @@ -847,7 +885,7 @@ var tip = d3.select('#run-status-tip-' + d.id); // if there are validation errors generate a tooltip - if (d.permissions.canRead && !nfCommon.isEmpty(d.component.validationErrors)) { + if (needsTip(d)) { // create the tip if necessary if (tip.empty()) { tip = d3.select('#processor-tooltips').append('div') @@ -859,12 +897,7 @@ // update the tip tip.html(function () { - var list = nfCommon.formatUnorderedList(d.component.validationErrors); - if (list === null || list.length === 0) { - return ''; - } else { - return $('<div></div>').append(list).html(); - } + return $('<div></div>').append(getTip(d)).html(); }); // add the tooltip http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-queue-listing.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-queue-listing.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-queue-listing.js index f214158..65f1311 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-queue-listing.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-queue-listing.js @@ -499,7 +499,7 @@ // define a custom formatter for showing more processor details var moreDetailsFormatter = function (row, cell, value, columnDef, dataContext) { - return '<div class="pointer show-flowfile-details fa fa-info-circle" title="View Details" style="margin-top: 5px; float: left;"></div>'; + return '<div class="pointer show-flowfile-details fa fa-info-circle" title="View Details" style="float: left;"></div>'; }; // function for formatting data sizes http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js index 563aff3..198f62a 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-settings.js @@ -264,12 +264,20 @@ var bType = nfCommon.isDefinedAndNotNull(b.component[sortDetails.columnId]) ? nfCommon.substringAfterLast(b.component[sortDetails.columnId], '.') : ''; return aType === bType ? 0 : aType > bType ? 1 : -1; } else if (sortDetails.columnId === 'state') { - var aState = 'Invalid'; - if (nfCommon.isEmpty(a.component.validationErrors)) { + var aState; + if (a.component.validationStatus === 'VALIDATING') { + aState = 'Validating'; + } else if (a.component.validationStatus === 'INVALID') { + aState = 'Invalid'; + } else { aState = nfCommon.isDefinedAndNotNull(a.component[sortDetails.columnId]) ? a.component[sortDetails.columnId] : ''; } - var bState = 'Invalid'; - if (nfCommon.isEmpty(b.component.validationErrors)) { + var bState; + if (a.component.validationStatus === 'VALIDATING') { + bState = 'Validating'; + } else if (a.component.validationStatus === 'INVALID') { + bState = 'Invalid'; + } else { bState = nfCommon.isDefinedAndNotNull(b.component[sortDetails.columnId]) ? b.component[sortDetails.columnId] : ''; } return aState === bState ? 0 : aState > bState ? 1 : -1; @@ -997,9 +1005,12 @@ // determine the appropriate label var icon = '', label = ''; - if (!nfCommon.isEmpty(dataContext.component.validationErrors)) { - label = 'Invalid'; + if (dataContext.component.validationStatus === 'VALIDATING') { + icon = 'validating fa fa-spin fa-circle-notch'; + label = 'Validating'; + } else if (dataContext.component.validationStatus === 'INVALID') { icon = 'invalid fa fa-warning'; + label = 'Invalid'; } else { if (dataContext.component.state === 'STOPPED') { label = 'Stopped'; @@ -1020,8 +1031,8 @@ } // format the markup - var formattedValue = '<div layout="row"><div class="' + icon + '" style="margin-top: 3px;"></div>'; - return formattedValue + '<div class="status-text" style="margin-top: 4px;">' + nfCommon.escapeHtml(label) + '</div><div style="float: left; margin-left: 4px;">' + nfCommon.escapeHtml(activeThreadCount) + '</div></div>'; + var formattedValue = '<div layout="row"><div class="' + icon + '"></div>'; + return formattedValue + '<div class="status-text">' + nfCommon.escapeHtml(label) + '</div><div style="float: left; margin-left: 4px;">' + nfCommon.escapeHtml(activeThreadCount) + '</div></div>'; }; var reportingTaskActionFormatter = function (row, cell, value, columnDef, dataContext) { @@ -1029,32 +1040,32 @@ if (dataContext.permissions.canRead && dataContext.permissions.canWrite) { if (dataContext.component.state === 'RUNNING') { - markup += '<div title="Stop" class="pointer stop-reporting-task fa fa-stop" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="Stop" class="pointer stop-reporting-task fa fa-stop"></div>'; } else if (dataContext.component.state === 'STOPPED' || dataContext.component.state === 'DISABLED') { - markup += '<div title="Edit" class="pointer edit-reporting-task fa fa-pencil" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="Edit" class="pointer edit-reporting-task fa fa-pencil"></div>'; // support starting when stopped and no validation errors if (dataContext.component.state === 'STOPPED' && nfCommon.isEmpty(dataContext.component.validationErrors)) { - markup += '<div title="Start" class="pointer start-reporting-task fa fa-play" style="margin-top: 2px; margin-right: 3px;"></div>'; + markup += '<div title="Start" class="pointer start-reporting-task fa fa-play"></div>'; } if (dataContext.component.multipleVersionsAvailable === true) { - markup += '<div title="Change Version" class="pointer change-version-reporting-task fa fa-exchange" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="Change Version" class="pointer change-version-reporting-task fa fa-exchange"></div>'; } if (nfCommon.canModifyController()) { - markup += '<div title="Remove" class="pointer delete-reporting-task fa fa-trash" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="Remove" class="pointer delete-reporting-task fa fa-trash"></div>'; } } if (dataContext.component.persistsState === true) { - markup += '<div title="View State" class="pointer view-state-reporting-task fa fa-tasks" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="View State" class="pointer view-state-reporting-task fa fa-tasks"></div>'; } } // allow policy configuration conditionally if (nfCanvasUtils.isManagedAuthorizer() && nfCommon.canAccessTenants()) { - markup += '<div title="Access Policies" class="pointer edit-access-policies fa fa-key" style="margin-top: 2px;"></div>'; + markup += '<div title="Access Policies" class="pointer edit-access-policies fa fa-key"></div>'; } return markup; @@ -1283,10 +1294,10 @@ if (nfCommon.canModifyController()) { // edit registry - markup += '<div title="Edit" class="pointer edit-registry fa fa-pencil" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="Edit" class="pointer edit-registry fa fa-pencil"></div>'; // remove registry - markup += '<div title="Remove" class="pointer remove-registry fa fa-trash" style="margin-top: 2px; margin-right: 3px;" ></div>'; + markup += '<div title="Remove" class="pointer remove-registry fa fa-trash"></div>'; } return markup; http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-variable-registry.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-variable-registry.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-variable-registry.js index 7265b70..86590f6 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-variable-registry.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/canvas/nf-variable-registry.js @@ -398,12 +398,12 @@ var markup = ''; if (dataContext.isEditable === true) { - markup += '<div title="Delete" class="delete-variable pointer fa fa-trash" style="margin-top: 2px;" ></div>'; + markup += '<div title="Delete" class="delete-variable pointer fa fa-trash"></div>'; } else { var currentProcessGroupId = $('#variable-registry-process-group-id').text(); if (dataContext.processGroupId !== currentProcessGroupId) { - markup += '<div title="Go To" class="go-to-variable pointer fa fa-long-arrow-right" style="margin-top: 2px;" ></div>'; + markup += '<div title="Go To" class="go-to-variable pointer fa fa-long-arrow-right"></div>'; } } http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/cluster/nf-cluster-table.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/cluster/nf-cluster-table.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/cluster/nf-cluster-table.js index ef1d2f9..095f714 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/cluster/nf-cluster-table.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/cluster/nf-cluster-table.js @@ -543,7 +543,7 @@ */ function createNodeTableColumnModel() { var moreDetailsFormatter = function (row, cell, value, columnDef, dataContext) { - return '<div title="View Details" class="pointer show-node-details fa fa-info-circle" style="margin-top: 2px;"></div>'; + return '<div title="View Details" class="pointer show-node-details fa fa-info-circle"></div>'; }; // define a custom formatter for the run status column @@ -640,9 +640,9 @@ // return the appropriate markup if (canConnect) { - return '<div title="Connect" class="pointer prompt-for-connect fa fa-plug" style="margin-top: 2px;"></div><div title="Delete" class="pointer prompt-for-removal fa fa-trash" style="margin-top: 2px;"></div>'; + return '<div title="Connect" class="pointer prompt-for-connect fa fa-plug"></div><div title="Delete" class="pointer prompt-for-removal fa fa-trash"></div>'; } else if (canDisconnect) { - return '<div title="Disconnect" class="pointer prompt-for-disconnect fa fa-power-off" style="margin-top: 2px;"></div>'; + return '<div title="Disconnect" class="pointer prompt-for-disconnect fa fa-power-off"></div>'; } else { return '<div style="width: 16px; height: 16px;"> </div>'; } @@ -705,7 +705,7 @@ function createJvmTableColumnModel() { var gcFormatter = function (row, cell, value, columnDef, dataContext) { - return '<div class="pointer show-jvm-gc fa fa-question-circle" style="margin-top: 2px;"></div><span class="hidden row-id">' + nfCommon.escapeHtml(dataContext.id) + '</span>'; + return '<div class="pointer show-jvm-gc fa fa-question-circle"></div><span class="hidden row-id">' + nfCommon.escapeHtml(dataContext.id) + '</span>'; }; return [ http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/counters/nf-counters-table.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/counters/nf-counters-table.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/counters/nf-counters-table.js index ab549bb..81577f4 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/counters/nf-counters-table.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/counters/nf-counters-table.js @@ -214,7 +214,7 @@ if (nfCommon.canModifyCounters()) { // function for formatting the actions column var actionFormatter = function (row, cell, value, columnDef, dataContext) { - return '<div title="Reset Counter" class="pointer reset-counter fa fa-undo" style="margin-top: 2px;"></div>'; + return '<div title="Reset Counter" class="pointer reset-counter fa fa-undo"></div>'; }; // add the action column http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/history/nf-history-table.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/history/nf-history-table.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/history/nf-history-table.js index 64bcab0..efab6ed 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/history/nf-history-table.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/history/nf-history-table.js @@ -301,7 +301,7 @@ // define a custom formatter for the more details column var moreDetailsFormatter = function (row, cell, value, columnDef, dataContext) { if (dataContext.canRead === true) { - return '<div title="View Details" class="pointer show-action-details fa fa-info-circle" style="margin-top: 4px;"></div>'; + return '<div title="View Details" class="pointer show-action-details fa fa-info-circle"></div>'; } return ""; }; http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/nf-common.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/nf-common.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/nf-common.js index 99b2d35..6b31fe9 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/nf-common.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/nf-common.js @@ -375,7 +375,7 @@ } if (!nfCommon.isEmpty(dataContext.controllerServiceApis)) { - markup += '<div class="controller-service-apis fa fa-list" title="Compatible Controller Service" style="margin-top: 2px; margin-left: 4px;"></div><span class="hidden row-id">' + nfCommon.escapeHtml(dataContext.id) + '</span>'; + markup += '<div class="controller-service-apis fa fa-list" title="Compatible Controller Service" style="margin-left: 4px;"></div><span class="hidden row-id">' + nfCommon.escapeHtml(dataContext.id) + '</span>'; } markup += '<div class="clear"></div>'; http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/provenance/nf-provenance-table.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/provenance/nf-provenance-table.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/provenance/nf-provenance-table.js index 9094795..3229b82 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/provenance/nf-provenance-table.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/provenance/nf-provenance-table.js @@ -635,7 +635,7 @@ // conditionally include the cluster node id if (nfCommon.SUPPORTS_SVG) { - markup += '<div title="Show Lineage" class="pointer show-lineage icon icon-lineage" style="margin-right: 3px;"></div>'; + markup += '<div title="Show Lineage" class="pointer show-lineage icon icon-lineage"></div>'; } // conditionally support going to the component http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/summary/nf-summary-table.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/summary/nf-summary-table.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/summary/nf-summary-table.js index e1311b4..1838a66 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/summary/nf-summary-table.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/summary/nf-summary-table.js @@ -266,7 +266,7 @@ // define a custom formatter for showing more processor details var moreProcessorDetails = function (row, cell, value, columnDef, dataContext) { - var markup = '<div title="View Processor Details" class="pointer show-processor-details fa fa-info-circle" style="margin-right: 3px;"></div>'; + var markup = '<div title="View Processor Details" class="pointer show-processor-details fa fa-info-circle"></div>'; // if there are bulletins, render them on the graph if (!nfCommon.isEmpty(dataContext.bulletins)) { @@ -329,6 +329,9 @@ case 'disabled': classes = 'icon icon-enable-false disabled'; break; + case 'validating': + classes = 'fa fa-spin fa-circle-notch validating'; + break; case 'invalid': classes = 'fa fa-warning invalid'; break; @@ -336,11 +339,10 @@ classes = ''; } - var markup = '<div layout="row">' + '<div class="' + classes + '"></div>' + - '<div class="status-text" style="margin-top: 4px;">' + + '<div class="status-text">' + nfCommon.escapeHtml(value) + '</div>' + '<div style="float: left; margin-left: 4px;" title="' + threadTip + '">' + @@ -456,11 +458,11 @@ var markup = ''; if (isInShell) { - markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Processor in ' + nfCommon.escapeHtml(dataContext.processGroupNamePath) + '" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Processor in ' + nfCommon.escapeHtml(dataContext.processGroupNamePath) + '"></div>'; } if (nfCommon.SUPPORTS_SVG) { - markup += '<div class="pointer show-processor-status-history fa fa-area-chart" title="View Status History" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer show-processor-status-history fa fa-area-chart" title="View Status History"></div>'; } if (isClustered) { @@ -703,7 +705,7 @@ // define a custom formatter for showing more processor details var moreConnectionDetails = function (row, cell, value, columnDef, dataContext) { - return '<div class="pointer show-connection-details fa fa-info-circle" title="View Connection Details" style="margin-top: 5px;"></div>'; + return '<div class="pointer show-connection-details fa fa-info-circle" title="View Connection Details"></div>'; }; var backpressureFormatter = function (row, cell, value, columnDef, dataContext) { @@ -788,11 +790,11 @@ var markup = ''; if (isInShell) { - markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Connection" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Connection"></div>'; } if (nfCommon.SUPPORTS_SVG) { - markup += '<div class="pointer show-connection-status-history fa fa-area-chart" title="View Status History" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer show-connection-status-history fa fa-area-chart" title="View Status History"></div>'; } if (isClustered) { @@ -1010,7 +1012,7 @@ // if there are bulletins, render them on the graph if (!nfCommon.isEmpty(dataContext.bulletins)) { - markup += '<div class="has-bulletins fa fa-sticky-note-o" style="margin-top: 5px; margin-left: 5px; float: left;"></div><span class="hidden row-id">' + nfCommon.escapeHtml(dataContext.id) + '</span>'; + markup += '<div class="has-bulletins fa fa-sticky-note-o" style="margin-left: 5px; float: left;"></div><span class="hidden row-id">' + nfCommon.escapeHtml(dataContext.id) + '</span>'; } return markup; @@ -1086,7 +1088,7 @@ classes = ''; label = ''; } - return '<div layout="row"><div class="' + classes + '"></div><div class="status-text" style="margin-top: 4px;">' + label + '</div></div>'; + return '<div layout="row"><div class="' + classes + '"></div><div class="status-text">' + label + '</div></div>'; }; // define the column model for the summary table @@ -1123,11 +1125,11 @@ var markup = ''; if (isInShell && dataContext.groupId !== null) { - markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Process Group" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Process Group"></div>'; } if (nfCommon.SUPPORTS_SVG) { - markup += '<div class="pointer show-process-group-status-history fa fa-area-chart" title="View Status History" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer show-process-group-status-history fa fa-area-chart" title="View Status History"></div>'; } if (isClustered) { @@ -1383,7 +1385,7 @@ var markup = ''; if (isInShell) { - markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Input Port" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Input Port"></div>'; } if (isClustered) { @@ -1630,7 +1632,7 @@ var markup = ''; if (isInShell) { - markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Output Port" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Output Port"></div>'; } if (isClustered) { @@ -1882,7 +1884,7 @@ // generate the mark up var formattedValue = '<div layout="row"><div class="' + transmissionClass + '"></div>'; - return formattedValue + '<div class="status-text" style="margin-top: 4px;">' + transmissionLabel + '</div><div style="float: left; margin-left: 4px;">' + nfCommon.escapeHtml(activeThreadCount) + '</div></div>'; + return formattedValue + '<div class="status-text">' + transmissionLabel + '</div><div style="float: left; margin-left: 4px;">' + nfCommon.escapeHtml(activeThreadCount) + '</div></div>'; }; var transmissionStatusColumn = { @@ -1929,11 +1931,11 @@ var markup = ''; if (isInShell) { - markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Process Group" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer go-to fa fa-long-arrow-right" title="Go To Process Group"></div>'; } if (nfCommon.SUPPORTS_SVG) { - markup += '<div class="pointer show-remote-process-group-status-history fa fa-area-chart" title="View Status History" style="margin-right: 3px;"></div>'; + markup += '<div class="pointer show-remote-process-group-status-history fa fa-area-chart" title="View Status History"></div>'; } if (isClustered) { http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/templates/nf-templates-table.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/templates/nf-templates-table.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/templates/nf-templates-table.js index 89c7cf2..26dea4a 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/templates/nf-templates-table.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/templates/nf-templates-table.js @@ -283,18 +283,18 @@ var markup = ''; if (dataContext.permissions.canRead === true) { - markup += '<div title="Download" class="pointer export-template icon icon-template-save" style="margin-top: 2px; margin-right: 3px;"></div>'; + markup += '<div title="Download" class="pointer export-template icon icon-template-save"></div>'; } // all DFMs to remove templates if (dataContext.permissions.canWrite === true) { - markup += '<div title="Remove Template" class="pointer prompt-to-delete-template fa fa-trash" style="margin-top: 2px; margin-right: 3px;"></div>'; + markup += '<div title="Remove Template" class="pointer prompt-to-delete-template fa fa-trash"></div>'; } // allow policy configuration conditionally if embedded in if (top !== window && nfCommon.canAccessTenants()) { if (nfCommon.isDefinedAndNotNull(parent.nf) && nfCommon.isDefinedAndNotNull(parent.nf.CanvasUtils) && parent.nf.CanvasUtils.isManagedAuthorizer()) { - markup += '<div title="Access Policies" class="pointer edit-access-policies fa fa-key" style="margin-top: 2px;"></div>'; + markup += '<div title="Access Policies" class="pointer edit-access-policies fa fa-key"></div>'; } } http://git-wip-us.apache.org/repos/asf/nifi/blob/568288db/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/users/nf-users-table.js ---------------------------------------------------------------------- diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/users/nf-users-table.js b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/users/nf-users-table.js index 6da6668..2dfaec9 100644 --- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/users/nf-users-table.js +++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-ui/src/main/webapp/js/nf/users/nf-users-table.js @@ -783,7 +783,7 @@ var identityFormatter = function (row, cell, value, columnDef, dataContext) { var markup = ''; if (dataContext.type === 'group') { - markup += '<div class="fa fa-users" style="margin-right: 5px;"></div>'; + markup += '<div class="fa fa-users"></div>'; } markup += nfCommon.escapeHtml(dataContext.component.identity); @@ -810,7 +810,7 @@ // ensure user can modify the user if (configurableUsersAndGroups && dataContext.component.configurable === true && nfCommon.canModifyTenants()) { - markup += '<div title="Edit" class="pointer edit-user fa fa-pencil" style="margin-right: 3px;"></div>'; + markup += '<div title="Edit" class="pointer edit-user fa fa-pencil"></div>'; markup += '<div title="Remove" class="pointer delete-user fa fa-trash"></div>'; } @@ -1127,7 +1127,7 @@ var groupId = $('<span class="group-id hidden"></span>').text(group.id); // icon - var groupIcon = $('<div class="fa fa-users nf-checkbox-label" style="margin-top: 6px;"></div>'); + var groupIcon = $('<div class="fa fa-users nf-checkbox-label"></div>'); // identity var identity = $('<div class="available-identities nf-checkbox-label"></div>').text(group.component.identity);
