NIFI-13364 Removed autorefresh and banner UI properties

This closes #8932

Signed-off-by: David Handermann <exceptionfactory@apache.org>
This commit is contained in:
Matt Gilman 2024-06-05 17:14:31 -04:00 committed by exceptionfactory
parent 8d85aeb34e
commit 5c335cbbec
No known key found for this signature in database
45 changed files with 6 additions and 276 deletions

View File

@ -92,8 +92,6 @@ public class MiNiFiPropertiesGenerator {
Triple.of(NiFiProperties.BORED_YIELD_DURATION, "10 millis",
"# If a component has no work to do (is \"bored\"), how long should we wait before checking again for work"),
Triple.of(NiFiProperties.LOGIN_IDENTITY_PROVIDER_CONFIGURATION_FILE, "./conf/login-identity-providers.xml", EMPTY),
Triple.of(NiFiProperties.UI_BANNER_TEXT, EMPTY, EMPTY),
Triple.of(NiFiProperties.UI_AUTO_REFRESH_INTERVAL, "30 sec", EMPTY),
Triple.of(NiFiProperties.NAR_LIBRARY_DIRECTORY, "./lib", EMPTY),
Triple.of(NiFiProperties.NAR_WORKING_DIRECTORY, "./work/nar/", EMPTY),
Triple.of(NiFiProperties.NAR_LIBRARY_AUTOLOAD_DIRECTORY, "./extensions", EMPTY),

View File

@ -28,8 +28,6 @@ nifi.bored.yield.duration=10 millis
nifi.authority.provider.configuration.file=./conf/authority-providers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.templates.directory=./conf/templates
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.working.directory=./work/nar/
nifi.documentation.working.directory=./work/docs/components

View File

@ -28,8 +28,6 @@ nifi.bored.yield.duration=10 millis
nifi.authority.provider.configuration.file=./conf/authority-providers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.templates.directory=./conf/templates
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.working.directory=./work/nar/
nifi.documentation.working.directory=./work/docs/components

View File

@ -28,8 +28,6 @@ nifi.bored.yield.duration=10 millis
nifi.authority.provider.configuration.file=./conf/authority-providers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.templates.directory=./conf/templates
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.working.directory=./work/nar/
nifi.documentation.working.directory=./work/docs/components

View File

@ -28,8 +28,6 @@ nifi.bored.yield.duration=10 millis
nifi.authority.provider.configuration.file=./conf/authority-providers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.templates.directory=./conf/templates
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.working.directory=./work/nar/
nifi.documentation.working.directory=./work/docs/components

View File

@ -24,8 +24,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.templates.directory=./target/templates
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/resources/NiFiProperties/lib/
nifi.nar.library.directory.alt=./target/resources/NiFiProperties/lib2/
nifi.nar.working.directory=./target/work/nar/

View File

@ -223,10 +223,6 @@ public class NiFiProperties extends ApplicationProperties {
public static final String WEB_REQUEST_LOG_FORMAT = "nifi.web.request.log.format";
public static final String WEB_JMX_METRICS_ALLOWED_FILTER_PATTERN = "nifi.web.jmx.metrics.allowed.filter.pattern";
// ui properties
public static final String UI_BANNER_TEXT = "nifi.ui.banner.text";
public static final String UI_AUTO_REFRESH_INTERVAL = "nifi.ui.autorefresh.interval";
// cluster common properties
public static final String CLUSTER_PROTOCOL_HEARTBEAT_INTERVAL = "nifi.cluster.protocol.heartbeat.interval";
public static final String CLUSTER_PROTOCOL_HEARTBEAT_MISSABLE_MAX = "nifi.cluster.protocol.heartbeat.missable.max";
@ -807,26 +803,6 @@ public class NiFiProperties extends ApplicationProperties {
return new File(getProperty(NAR_LIBRARY_AUTOLOAD_DIRECTORY, DEFAULT_NAR_LIBRARY_AUTOLOAD_DIR));
}
// getters for ui properties //
/**
* Get the banner text.
*
* @return The banner text
*/
public String getBannerText() {
return this.getProperty(UI_BANNER_TEXT, StringUtils.EMPTY);
}
/**
* Returns the auto refresh interval in seconds.
*
* @return the interval over which the properties should auto refresh
*/
public String getAutoRefreshInterval() {
return getProperty(UI_AUTO_REFRESH_INTERVAL);
}
/**
* Returns true if auto reload of the keystore and truststore is enabled.
*

View File

@ -44,8 +44,6 @@ public class NiFiPropertiesTest {
NiFiProperties properties = loadNiFiProperties("/NiFiProperties/conf/nifi.properties", null);
assertEquals("UI Banner Text", properties.getBannerText());
Set<File> expectedDirectories = new HashSet<>();
expectedDirectories.add(new File("./target/resources/NiFiProperties/lib/"));
expectedDirectories.add(new File("./target/resources/NiFiProperties/lib2/"));

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=
nifi.custom.nar.library.directory.alt=
nifi.nar.working.directory=./target/work/nar/

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.working.directory=./target/work/nar/
# H2 Settings

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/resources/NiFiProperties/lib/
nifi.nar.library.directory.alt=./target/resources/NiFiProperties/lib2/
nifi.nar.working.directory=./target/work/nar/

View File

@ -3212,8 +3212,6 @@ This cleanup mechanism takes into account only automatically created archived _f
|`nifi.authorizer.configuration.file`*|This is the location of the file that specifies how authorizers are defined. The default value is `./conf/authorizers.xml`.
|`nifi.login.identity.provider.configuration.file`*|This is the location of the file that specifies how username/password authentication is performed. This file is
only considered if `nifi.security.user.login.identity.provider` is configured with a provider identifier. The default value is `./conf/login-identity-providers.xml`.
|`nifi.ui.banner.text`|This is banner text that may be configured to display at the top of the User Interface. It is blank by default.
|`nifi.ui.autorefresh.interval`|The interval at which the User Interface auto-refreshes. The default value is `30 secs`.
|`nifi.nar.library.directory`|The location of the nar library. The default value is `./lib` and probably should be left as is.
|`nifi.restore.directory`|The location that certain providers (e.g. UserGroupProviders) will look for previous configurations to restore from. There is no default value.
+

View File

@ -1,63 +0,0 @@
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.nifi.web.api.dto;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.xml.bind.annotation.XmlType;
/**
* Banners that should appear on the top and bottom of this NiFi.
*/
@XmlType(name = "banners")
public class BannerDTO {
private String headerText;
private String footerText;
/* getters / setters */
/**
* The banner footer text.
*
* @return The footer text
*/
@Schema(description = "The footer text."
)
public String getFooterText() {
return footerText;
}
public void setFooterText(String footerText) {
this.footerText = footerText;
}
/**
* The banner header text.
*
* @return The header text
*/
@Schema(description = "The header text."
)
public String getHeaderText() {
return headerText;
}
public void setHeaderText(String headerText) {
this.headerText = headerText;
}
}

View File

@ -32,7 +32,6 @@ public class FlowConfigurationDTO {
private Boolean supportsManagedAuthorizer;
private Boolean supportsConfigurableAuthorizer;
private Boolean supportsConfigurableUsersAndGroups;
private Long autoRefreshIntervalSeconds;
private Date currentTime;
private Integer timeOffset;
@ -40,20 +39,6 @@ public class FlowConfigurationDTO {
private Long defaultBackPressureObjectThreshold;
private String defaultBackPressureDataSizeThreshold;
/**
* @return interval in seconds between the automatic NiFi refresh requests. This value is read only
*/
@Schema(description = "The interval in seconds between the automatic NiFi refresh requests.",
accessMode = Schema.AccessMode.READ_ONLY
)
public Long getAutoRefreshIntervalSeconds() {
return autoRefreshIntervalSeconds;
}
public void setAutoRefreshIntervalSeconds(Long autoRefreshIntervalSeconds) {
this.autoRefreshIntervalSeconds = autoRefreshIntervalSeconds;
}
/**
* @return whether this NiFi supports a managed authorizer. Managed authorizers can visualize users, groups,
* and policies in the UI. This value is read only

View File

@ -1,44 +0,0 @@
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.nifi.web.api.entity;
import jakarta.xml.bind.annotation.XmlRootElement;
import org.apache.nifi.web.api.dto.BannerDTO;
/**
* A serialized representation of this class can be placed in the entity body of a request or response to or from the API. This particular entity holds a reference to a BannerDTO.
*/
@XmlRootElement(name = "bannersEntity")
public class BannerEntity extends Entity {
private BannerDTO banners;
/**
* The BannerDTO that is being serialized.
*
* @return The BannerDTO object
*/
public BannerDTO getBanners() {
return banners;
}
public void setBanners(BannerDTO about) {
this.banners = about;
}
}

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/lib
nifi.nar.working.directory=./target/work/nar/

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/lib
nifi.nar.working.directory=./target/work/nar/

View File

@ -32,7 +32,6 @@ public class NiFiPropertiesDiagnosticTask implements DiagnosticTask {
"nifi.cluster.node.read.timeout",
"nifi.zookeeper.connect.timeout",
"nifi.zookeeper.session.timeout",
"nifi.ui.autorefresh.interval",
"nifi.cluster.node.protocol.max.threads",
"nifi.security.allow.anonymous.authentication",
"nifi.security.user.login.identity.provider",

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/lib
nifi.nar.working.directory=./target/work/nar/

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=500 millis
nifi.reporting.task.configuration.file=./target/flowcontrollertest/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/flowcontrollertest/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/flowcontrollertest/lib
nifi.nar.working.directory=./target/flowcontrollertest/work/nar/

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/lib
nifi.nar.working.directory=./target/work/nar/

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=500 millis
nifi.reporting.task.configuration.file=./target/standardflowserializertest/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/standardflowserializertest/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/standardflowserializertest/lib
nifi.nar.working.directory=./target/standardflowserializertest/work/nar/

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=500 millis
nifi.reporting.task.configuration.file=./target/standardflowsynchronizerspec/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/standardflowsynchronizerspec/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/standardflowsynchronizerspec/lib
nifi.nar.working.directory=./target/standardflowsynchronizerspec/work/nar/

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=500 millis
nifi.reporting.task.configuration.file=./target/standardprocessschedulertest/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/standardprocessschedulertest/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/standardprocessschedulertest/lib
nifi.nar.working.directory=./target/standardprocessschedulertest/work/nar/

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./src/test/resources/lib/
nifi.nar.library.autoload.directory=./target/nars_with_native_lib

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./src/test/resources/lib/
nifi.nar.library.autoload.directory=./target/nars_without_native_lib

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./src/test/resources/lib/
nifi.nar.library.autoload.directory=./target/extensions

View File

@ -23,8 +23,6 @@ nifi.administrative.yield.duration=30 sec
nifi.reporting.task.configuration.file=./target/reporting-tasks.xml
nifi.controller.service.configuration.file=./target/controller-services.xml
nifi.ui.banner.text=UI Banner Text
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/NarUnpacker/lib/
nifi.nar.library.directory.alt=./target/NarUnpacker/lib2/

View File

@ -28,8 +28,6 @@ nifi.bored.yield.duration=10 millis
nifi.authorizer.configuration.file=./conf/authorizers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.working.directory=./target/work/nar/
nifi.documentation.working.directory=./target/work/docs/components

View File

@ -28,8 +28,6 @@ nifi.bored.yield.duration=10 millis
nifi.authorizer.configuration.file=./conf/authorizers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.working.directory=./work/nar/
nifi.documentation.working.directory=./work/docs/components

View File

@ -72,8 +72,6 @@
<nifi.content.viewer.url>../nifi-content-viewer/</nifi.content.viewer.url>
<nifi.restore.directory />
<nifi.ui.banner.text />
<nifi.ui.autorefresh.interval>30 sec</nifi.ui.autorefresh.interval>
<nifi.nar.library.directory>./lib</nifi.nar.library.directory>
<nifi.nar.library.autoload.directory>./extensions</nifi.nar.library.autoload.directory>
<nifi.nar.working.directory>./work/nar/</nifi.nar.working.directory>

View File

@ -31,8 +31,6 @@ nifi.queue.backpressure.size=${nifi.queue.backpressure.size}
nifi.authorizer.configuration.file=${nifi.authorizer.configuration.file}
nifi.login.identity.provider.configuration.file=${nifi.login.identity.provider.configuration.file}
nifi.ui.banner.text=${nifi.ui.banner.text}
nifi.ui.autorefresh.interval=${nifi.ui.autorefresh.interval}
nifi.nar.library.directory=${nifi.nar.library.directory}
nifi.nar.library.autoload.directory=${nifi.nar.library.autoload.directory}
nifi.nar.working.directory=${nifi.nar.working.directory}

View File

@ -28,9 +28,6 @@ nifi.bored.yield.duration=10 millis
nifi.authorizer.configuration.file=./target/conf/authorizers.xml
nifi.login.identity.provider.configuration.file=./target/conf/login-identity-providers.xml
nifi.ui.banner.text=dXwnu9mLyPETJrq1||n9e5dk5+HSTBCGOA/Sy6VYzwPw3baeRNvglalA1Pr1PcToyc4/qT6md24YOP4xVz14jd
nifi.ui.banner.text.protected=aes/gcm/256
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/lib
nifi.nar.working.directory=./target/work/nar/
nifi.documentation.working.directory=./target/work/docs/components
@ -131,7 +128,7 @@ nifi.web.jetty.threads=200
nifi.sensitive.props.key=dQU402Mz4J+t+e18||6+ictR0Nssq3/rR/d8fq5CFAKmpakr9jCyPIJYxG7n6D86gxsu2TRp4M48ugUw==
nifi.sensitive.props.key.protected=aes/gcm/256
nifi.sensitive.props.algorithm=NIFI_PBKDF2_AES_GCM_256
nifi.sensitive.props.additional.keys=nifi.ui.banner.text
nifi.sensitive.props.additional.keys=
nifi.security.keystore=/path/to/keystore.jks
nifi.security.keystoreType=JKS

View File

@ -28,8 +28,6 @@ nifi.bored.yield.duration=10 millis
nifi.authorizer.configuration.file=./target/conf/authorizers.xml
nifi.login.identity.provider.configuration.file=./target/conf/login-identity-providers.xml
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./target/lib
nifi.nar.working.directory=./target/work/nar/
nifi.documentation.working.directory=./target/work/docs/components

View File

@ -24,8 +24,6 @@ nifi.flowfile.repository.partitions=4096
nifi.flowfile.repository.checkpoint.millis=120000
nifi.content.repository.directory.default=./content_repository
nifi.provenance.repository.capacity=25000
nifi.ui.banner.text=DEFAULT BANNER
nifi.ui.autorefresh.interval.seconds=30
nifi.flowcontroller.autoStartProcessors=true
nifi.flowcontroller.schedulestrategy=delay
nifi.flowcontroller.minimum.nanoseconds=1000000

View File

@ -78,7 +78,7 @@ public class FrameworkServerConnectorFactory extends StandardServerConnectorFact
includeCipherSuites = properties.getProperty(NiFiProperties.WEB_HTTPS_CIPHERSUITES_INCLUDE);
excludeCipherSuites = properties.getProperty(NiFiProperties.WEB_HTTPS_CIPHERSUITES_EXCLUDE);
headerSize = DataUnit.parseDataSize(properties.getWebMaxHeaderSize(), DataUnit.B).intValue();
idleTimeout = getIdleTimeout(properties);
idleTimeout = getIdleTimeout();
if (properties.isHTTPSConfigured()) {
tlsConfiguration = StandardTlsConfiguration.fromNiFiProperties(properties);
@ -177,8 +177,8 @@ public class FrameworkServerConnectorFactory extends StandardServerConnectorFact
setApplicationLayerProtocols(applicationLayerProtocols);
}
private int getIdleTimeout(final NiFiProperties properties) {
final String autoRefreshInterval = StringUtils.defaultIfBlank(properties.getAutoRefreshInterval(), DEFAULT_AUTO_REFRESH_INTERVAL);
private int getIdleTimeout() {
final String autoRefreshInterval = DEFAULT_AUTO_REFRESH_INTERVAL;
final double autoRefreshMilliseconds = FormatUtils.getPreciseTimeDuration(autoRefreshInterval, TimeUnit.MILLISECONDS);
return Math.multiplyExact((int) autoRefreshMilliseconds, IDLE_TIMEOUT_MULTIPLIER);
}

View File

@ -4419,8 +4419,7 @@ public class StandardNiFiServiceFacade implements NiFiServiceFacade {
@Override
public FlowConfigurationEntity getFlowConfiguration() {
final FlowConfigurationDTO dto = dtoFactory.createFlowConfigurationDto(properties.getAutoRefreshInterval(),
properties.getDefaultBackPressureObjectThreshold(), properties.getDefaultBackPressureDataSizeThreshold());
final FlowConfigurationDTO dto = dtoFactory.createFlowConfigurationDto(properties.getDefaultBackPressureObjectThreshold(), properties.getDefaultBackPressureDataSizeThreshold());
final FlowConfigurationEntity entity = new FlowConfigurationEntity();
entity.setFlowConfiguration(dto);
return entity;

View File

@ -56,7 +56,6 @@ import org.apache.nifi.web.NiFiServiceFacade;
import org.apache.nifi.web.ResourceNotFoundException;
import org.apache.nifi.web.Revision;
import org.apache.nifi.web.api.dto.AboutDTO;
import org.apache.nifi.web.api.dto.BannerDTO;
import org.apache.nifi.web.api.dto.BulletinBoardDTO;
import org.apache.nifi.web.api.dto.BulletinQueryDTO;
import org.apache.nifi.web.api.dto.ClusterDTO;
@ -76,7 +75,6 @@ import org.apache.nifi.web.api.dto.status.ControllerStatusDTO;
import org.apache.nifi.web.api.entity.AboutEntity;
import org.apache.nifi.web.api.entity.ActionEntity;
import org.apache.nifi.web.api.entity.ActivateControllerServicesEntity;
import org.apache.nifi.web.api.entity.BannerEntity;
import org.apache.nifi.web.api.entity.BulletinBoardEntity;
import org.apache.nifi.web.api.entity.ClusterSearchResultsEntity;
import org.apache.nifi.web.api.entity.ClusterSummaryEntity;
@ -1342,50 +1340,6 @@ public class FlowResource extends ApplicationResource {
return generateOkResponse(entity).build();
}
/**
* Retrieves the banners for this NiFi.
*
* @return A bannerEntity.
*/
@GET
@Consumes(MediaType.WILDCARD)
@Produces(MediaType.APPLICATION_JSON)
@Path("banners")
@Operation(
summary = "Retrieves the banners for this NiFi",
responses = @ApiResponse(content = @Content(schema = @Schema(implementation = BannerEntity.class))),
security = {
@SecurityRequirement(name = "Read - /flow")
}
)
@ApiResponses(
value = {
@ApiResponse(responseCode = "400", description = "NiFi was unable to complete the request because it was invalid. The request should not be retried without modification."),
@ApiResponse(responseCode = "401", description = "Client could not be authenticated."),
@ApiResponse(responseCode = "403", description = "Client is not authorized to make this request."),
@ApiResponse(responseCode = "409", description = "The request was valid but NiFi was not in the appropriate state to process it.")
}
)
public Response getBanners() {
authorizeFlow();
// get the banner from the properties - will come from the NCM when clustered
final String bannerText = getProperties().getBannerText();
// create the DTO
final BannerDTO bannerDTO = new BannerDTO();
bannerDTO.setHeaderText(bannerText);
bannerDTO.setFooterText(bannerText);
// create the response entity
final BannerEntity entity = new BannerEntity();
entity.setBanners(bannerDTO);
// generate the response
return generateOkResponse(entity).build();
}
/**
* Retrieves the types of processors that this NiFi supports.
*

View File

@ -300,14 +300,10 @@ public final class DtoFactory {
return dto;
}
public FlowConfigurationDTO createFlowConfigurationDto(final String autoRefreshInterval,
final Long defaultBackPressureObjectThreshold,
public FlowConfigurationDTO createFlowConfigurationDto(final Long defaultBackPressureObjectThreshold,
final String defaultBackPressureDataSizeThreshold) {
final FlowConfigurationDTO dto = new FlowConfigurationDTO();
// get the refresh interval
final long refreshInterval = FormatUtils.getTimeDuration(autoRefreshInterval, TimeUnit.SECONDS);
dto.setAutoRefreshIntervalSeconds(refreshInterval);
dto.setSupportsManagedAuthorizer(AuthorizerCapabilityDetection.isManagedAuthorizer(authorizer));
dto.setSupportsConfigurableUsersAndGroups(AuthorizerCapabilityDetection.isConfigurableUserGroupProvider(authorizer));
dto.setSupportsConfigurableAuthorizer(AuthorizerCapabilityDetection.isConfigurableAccessPolicyProvider(authorizer));

View File

@ -25,8 +25,6 @@ nifi.bored.yield.duration=${nifi.bored.yield.duration}
nifi.authorizer.configuration.file=${nifi.authorizer.configuration.file}
nifi.login.identity.provider.configuration.file=${nifi.login.identity.provider.configuration.file}
nifi.ui.banner.text=${nifi.ui.banner.text}
nifi.ui.autorefresh.interval=${nifi.ui.autorefresh.interval}
nifi.nar.library.directory=${nifi.nar.library.directory}
nifi.nar.working.directory=${nifi.nar.working.directory}
nifi.documentation.working.directory=${nifi.documentation.working.directory}

View File

@ -25,7 +25,6 @@ export interface FlowConfiguration {
supportsManagedAuthorizer: boolean;
supportsConfigurableAuthorizer: boolean;
supportsConfigurableUsersAndGroups: boolean;
autoRefreshIntervalSeconds: number;
currentTime: string;
timeOffset: number;
defaultBackPressureObjectThreshold: number;

View File

@ -31,8 +31,6 @@ nifi.queue.backpressure.size=1 GB
nifi.authorizer.configuration.file=./conf/authorizers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.library.autoload.directory=./extensions
nifi.nar.working.directory=./work/nar/

View File

@ -31,8 +31,6 @@ nifi.queue.backpressure.size=1 GB
nifi.authorizer.configuration.file=./conf/authorizers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.library.autoload.directory=./extensions
nifi.nar.working.directory=./work/nar/

View File

@ -31,8 +31,6 @@ nifi.queue.backpressure.size=1 GB
nifi.authorizer.configuration.file=./conf/authorizers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.library.autoload.directory=./extensions
nifi.nar.working.directory=./work/nar/

View File

@ -35,8 +35,6 @@ nifi.queue.backpressure.size=1 GB
nifi.authorizer.configuration.file=./conf/authorizers.xml
nifi.login.identity.provider.configuration.file=./conf/login-identity-providers.xml
nifi.ui.banner.text=
nifi.ui.autorefresh.interval=30 sec
nifi.nar.library.directory=./lib
nifi.nar.library.autoload.directory=./extensions
nifi.nar.working.directory=./work/nar/