You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nifi.apache.org by sz...@apache.org on 2025/10/18 01:32:40 UTC
(nifi-minifi-cpp) branch main updated (5b750041f -> 612e9f5c3)
This is an automated email from the ASF dual-hosted git repository.
szaszm pushed a change to branch main
in repository https://gitbox.apache.org/repos/asf/nifi-minifi-cpp.git
from 5b750041f MINIFICPP-2651 Add documenation on asset reference syntax
new 8cb945b10 MINIFICPP-2232 Remove option to load SSL context from flow config
new cd4729197 MINIFICPP-2629 Clean up minifi-api includes
new e8c9a7c42 MINIFICPP-2643 Fix clang tidy issues
new 612e9f5c3 MINIFICPP-2652 Remove deprecated bootstrap.sh
The 4 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:
.clang-tidy | 3 +-
C2.md | 3 -
CONFIGURE.md | 11 +-
OPS.md | 8 +-
README.md | 72 ---
ThirdParties.md | 7 -
aptitude.sh | 89 ----
arch.sh | 77 ---
bootstrap.sh | 524 ---------------------
bstrp_functions.sh | 474 -------------------
centos.sh | 99 ----
cmake/Extensions.cmake | 2 +-
conanfile.py | 2 +-
conf/minifi-log.properties.in | 1 -
conf/minifi.properties.in | 2 -
controller/Controller.cpp | 2 +-
controller/MiNiFiController.cpp | 55 +--
controller/tests/ControllerTests.cpp | 76 +--
core-framework/include/Exception.h | 21 -
core-framework/include/SwapManager.h | 21 -
core-framework/include/agent/agent_version.h | 19 -
core-framework/include/core/Annotation.h | 20 -
.../include/core/BufferedContentSession.h | 2 +-
core-framework/include/core/ClassLoader.h | 3 +-
.../include/core/ConfigurableComponentImpl.h | 2 +-
core-framework/include/core/Connectable.h | 2 +-
core-framework/include/core/ContentRepository.h | 2 +-
core-framework/include/core/ContentSession.h | 5 +-
core-framework/include/core/ObjectFactory.h | 32 +-
.../include/core/OutputAttributeDefinition.h | 20 -
core-framework/include/core/ProcessContext.h | 3 +-
.../include/core/ProcessContextBuilder.h | 3 +-
core-framework/include/core/ProcessorImpl.h | 7 +-
core-framework/include/core/Property.h | 25 -
core-framework/include/core/PropertyDefinition.h | 20 -
.../include/core/PropertyDefinitionBuilder.h | 2 +-
.../include/core/RelationshipDefinition.h | 20 -
core-framework/include/core/Repository.h | 8 +-
core-framework/include/core/Resource.h | 1 +
core-framework/include/core/StreamManager.h | 4 +-
core-framework/include/core/TypedValues.h | 6 +-
core-framework/include/core/extension/Extension.h | 14 +-
core-framework/include/core/logging/Logger.h | 20 -
.../include/core/state/MetricsPublisher.h | 2 +-
core-framework/include/http/BaseHTTPClient.h | 33 +-
core-framework/include/http/HTTPClient.h | 2 +-
core-framework/include/io/ArchiveStream.h | 20 -
core-framework/include/io/BufferStream.h | 14 +-
core-framework/include/io/CRCStream.h | 2 +-
core-framework/include/io/StreamPipe.h | 4 +-
core-framework/include/io/ZlibStream.h | 2 +-
core-framework/include/utils/AutoPersistor.h | 2 +-
core-framework/include/utils/ByteArrayCallback.h | 4 +-
core-framework/include/utils/CollectionUtils.h | 12 +-
core-framework/include/utils/Cron.h | 2 +-
core-framework/include/utils/Export.h | 35 --
core-framework/include/utils/FileMutex.h | 2 +-
core-framework/include/utils/GeneralUtils.h | 2 +-
core-framework/include/utils/IntervalSwitch.h | 14 +-
core-framework/include/utils/JsonCallback.h | 12 +-
.../utils/LineByLineInputOutputStreamCallback.h | 6 +-
core-framework/include/utils/Literals.h | 19 -
core-framework/include/utils/MapUtils.h | 14 +-
core-framework/include/utils/OptionalUtils.h | 2 +-
core-framework/include/utils/ParsingUtils.h | 4 +-
core-framework/include/utils/PropertyExceptions.h | 19 -
core-framework/include/utils/StringUtils.h | 8 +-
core-framework/include/utils/ThreadPool.h | 2 +-
core-framework/include/utils/TryMoveCall.h | 12 +-
core-framework/include/utils/ValueParser.h | 2 +-
.../include/utils/crypto/EncryptionManager.h | 2 +-
.../include/utils/crypto/EncryptionProvider.h | 2 +-
.../include/utils/crypto/ciphers/Aes256Ecb.h | 18 +-
core-framework/include/utils/file/FileUtils.h | 2 +-
core-framework/include/utils/gsl.h | 21 -
.../include/utils/net/NetworkInterfaceInfo.h | 2 +-
.../include/utils/requirements/Container.h | 12 +-
.../utils/requirements/EqualityComparable.h | 12 +-
.../utils/requirements/LegacyForwardIterator.h | 12 +-
.../utils/requirements/LegacyInputIterator.h | 12 +-
.../include/utils/requirements/LegacyIterator.h | 12 +-
.../include/utils/requirements/Swappable.h | 12 +-
core-framework/src/core/BufferedContentSession.cpp | 6 +-
core-framework/src/core/ContentSession.cpp | 1 -
core-framework/src/core/ProcessorImpl.cpp | 5 +-
core-framework/src/core/ProcessorMetrics.cpp | 2 +-
core-framework/src/core/Property.cpp | 4 +-
core-framework/src/core/TypedValues.cpp | 2 +-
core-framework/src/http/BaseHTTPClient.cpp | 7 +-
core-framework/src/http/HTTPClient.cpp | 14 +-
core-framework/src/http/HTTPStream.cpp | 2 +-
core-framework/src/io/BufferStream.cpp | 2 +-
core-framework/src/io/FileStream.cpp | 10 +-
core-framework/src/io/InputStream.cpp | 2 +-
core-framework/src/io/OutputStream.cpp | 2 +-
core-framework/src/io/ZlibStream.cpp | 4 +-
core-framework/src/utils/ByteArrayCallback.cpp | 8 +-
.../src/utils/CallBackTimer.cpp | 0
core-framework/src/utils/Environment.cpp | 2 +-
core-framework/src/utils/Error.cpp | 2 +-
core-framework/src/utils/FifoExecutor.cpp | 2 +-
core-framework/src/utils/FileMutex.cpp | 2 +-
core-framework/src/utils/Id.cpp | 6 +-
.../utils/LineByLineInputOutputStreamCallback.cpp | 2 +-
core-framework/src/utils/OsUtils.cpp | 10 +-
core-framework/src/utils/RegexUtils.cpp | 2 +-
core-framework/src/utils/StoppableThread.cpp | 2 +-
core-framework/src/utils/SystemCpuUsageTracker.cpp | 5 +-
.../src/utils/crypto/ciphers/Aes256Ecb.cpp | 4 +-
core-framework/src/utils/file/FileUtils.cpp | 2 +-
core-framework/src/utils/file/PathUtils.cpp | 2 +-
core-framework/src/utils/net/AsioSocketUtils.cpp | 2 +-
core-framework/src/utils/net/DNS.cpp | 2 +-
.../src/utils/net/NetworkInterfaceInfo.cpp | 6 +-
core-framework/src/utils/net/Socket.cpp | 2 +-
darwin.sh | 109 -----
debian.sh | 90 ----
deploy.sh | 28 --
.../cluster/containers/MinifiContainer.py | 1 -
.../integration/features/minifi_c2_server.feature | 8 -
docker/test/integration/features/steps/steps.py | 12 -
encrypt-config/ConfigFile.h | 13 +-
encrypt-config/ConfigFileEncryptor.cpp | 12 +-
encrypt-config/ConfigFileEncryptor.h | 12 +-
encrypt-config/EncryptConfig.cpp | 1 -
encrypt-config/EncryptConfigMain.cpp | 2 +-
encrypt-config/Utils.h | 12 +-
encrypt-config/tests/ConfigFileEncryptorTests.cpp | 2 +-
encrypt-config/tests/ConfigFileTests.cpp | 10 +-
encrypt-config/tests/resources/minifi.properties | 1 -
...th-additional-sensitive-props.minifi.properties | 1 -
extension-framework/include/FlowFileRecord.h | 21 -
extension-framework/include/ResourceClaim.h | 21 -
.../include/controllers/SSLContextService.h | 19 -
.../controllers/SSLContextServiceInterface.h | 19 -
.../controllers/keyvalue/KeyValueStateManager.h | 2 +-
.../include/core/AbstractProcessor.h | 2 +-
extension-framework/include/core/FlowFile.h | 20 -
extension-framework/include/core/FlowFileStore.h | 2 +-
extension-framework/include/core/StateStorage.h | 2 +-
extension-framework/include/properties/Configure.h | 19 -
.../include/properties/Properties.h | 19 -
.../include/serialization/FlowFileSerializer.h | 10 +-
.../include/serialization/FlowFileV3Serializer.h | 10 +-
.../include/serialization/PayloadSerializer.h | 12 +-
.../include/utils/ListingStateManager.h | 4 +-
.../include/utils/ProcessorConfigUtils.h | 2 +-
extension-framework/include/utils/ResourceQueue.h | 2 +-
.../include/utils/file/FileReaderCallback.h | 2 +-
extension-framework/include/utils/net/Server.h | 2 +-
extension-framework/include/utils/net/Ssl.h | 6 +-
extension-framework/include/utils/net/UdpServer.h | 2 +-
.../controllers/keyvalue/KeyValueStateStorage.cpp | 4 +-
extension-framework/src/core/ProcessContext.cpp | 22 -
.../src/serialization/FlowFileV3Serializer.cpp | 6 +-
.../src/utils/ListingStateManager.cpp | 6 +-
extension-framework/src/utils/net/Ssl.cpp | 2 +-
extension-framework/src/utils/net/TcpServer.cpp | 2 +-
extensions/aws/AWSCredentialsProvider.cpp | 2 +-
extensions/aws/AWSCredentialsProvider.h | 14 +-
.../aws/controllerservices/AWSCredentialsService.h | 2 +-
extensions/aws/processors/AwsProcessor.cpp | 4 +-
extensions/aws/processors/AwsProcessor.h | 2 +-
extensions/aws/processors/DeleteS3Object.cpp | 2 +-
extensions/aws/processors/DeleteS3Object.h | 2 +-
extensions/aws/processors/FetchS3Object.cpp | 2 +-
extensions/aws/processors/FetchS3Object.h | 2 +-
extensions/aws/processors/ListS3.cpp | 2 +-
extensions/aws/processors/ListS3.h | 2 +-
extensions/aws/processors/PutKinesisStream.cpp | 2 +-
extensions/aws/processors/PutS3Object.cpp | 8 +-
extensions/aws/processors/PutS3Object.h | 4 +-
extensions/aws/processors/S3Processor.cpp | 3 +-
extensions/aws/processors/S3Processor.h | 6 +-
extensions/aws/s3/MultipartUploadStateStorage.cpp | 2 +-
extensions/aws/s3/MultipartUploadStateStorage.h | 6 +-
extensions/aws/s3/S3RequestSender.h | 2 +-
extensions/aws/s3/S3Wrapper.cpp | 2 +-
extensions/aws/s3/S3Wrapper.h | 10 +-
extensions/aws/tests/AWSCredentialsServiceTest.cpp | 2 +-
.../aws/tests/MultipartUploadStateStorageTest.cpp | 2 +-
extensions/aws/utils/AWSInitializer.h | 14 +-
extensions/aws/utils/AWSSdkLogger.cpp | 2 +-
extensions/aws/utils/AWSSdkLogger.h | 2 +-
.../AzureStorageCredentialsService.h | 4 +-
.../processors/AzureBlobStorageProcessorBase.cpp | 2 +-
.../processors/AzureBlobStorageProcessorBase.h | 6 +-
.../AzureBlobStorageSingleBlobProcessorBase.cpp | 2 +-
.../AzureBlobStorageSingleBlobProcessorBase.h | 2 +-
.../AzureDataLakeStorageFileProcessorBase.h | 2 +-
.../processors/AzureDataLakeStorageProcessorBase.h | 6 +-
.../azure/processors/AzureStorageProcessorBase.cpp | 2 +-
.../azure/processors/AzureStorageProcessorBase.h | 6 +-
.../azure/processors/DeleteAzureBlobStorage.h | 4 +-
.../processors/DeleteAzureDataLakeStorage.cpp | 2 +-
.../azure/processors/FetchAzureBlobStorage.cpp | 5 +-
.../azure/processors/FetchAzureBlobStorage.h | 4 +-
.../azure/processors/FetchAzureDataLakeStorage.cpp | 8 +-
.../azure/processors/FetchAzureDataLakeStorage.h | 2 +-
extensions/azure/processors/ListAzureBlobStorage.h | 4 +-
.../azure/processors/PutAzureBlobStorage.cpp | 2 +-
extensions/azure/processors/PutAzureBlobStorage.h | 6 +-
.../azure/processors/PutAzureDataLakeStorage.cpp | 2 +-
.../azure/processors/PutAzureDataLakeStorage.h | 4 +-
extensions/azure/storage/AzureBlobStorage.h | 6 +-
.../azure/storage/AzureBlobStorageClient.cpp | 1 +
extensions/azure/storage/AzureBlobStorageClient.h | 2 +-
extensions/azure/storage/AzureDataLakeStorage.cpp | 2 +-
extensions/azure/storage/AzureDataLakeStorage.h | 4 +-
.../azure/storage/AzureDataLakeStorageClient.h | 3 +-
extensions/azure/storage/BlobStorageClient.h | 4 +-
extensions/azure/storage/DataLakeStorageClient.h | 4 +-
extensions/azure/utils/AzureSdkLogger.h | 2 +-
extensions/bustache/ApplyTemplate.cpp | 2 +-
extensions/bustache/tests/ApplyTemplateTests.cpp | 2 +-
extensions/civetweb/processors/ListenHTTP.cpp | 5 +-
extensions/civetweb/processors/ListenHTTP.h | 11 +-
.../civetweb/tests/HttpPostIntegrationTest.cpp | 2 +-
extensions/civetweb/tests/ListenHTTPTests.cpp | 124 ++---
.../controllerservices/CouchbaseClusterService.cpp | 1 +
.../controllerservices/CouchbaseClusterService.h | 6 +-
.../couchbase/processors/GetCouchbaseKey.cpp | 2 +-
.../couchbase/processors/PutCouchbaseKey.cpp | 2 +-
.../ElasticsearchCredentialsControllerService.h | 2 +-
extensions/elasticsearch/PostElasticsearch.cpp | 4 +-
extensions/elasticsearch/PostElasticsearch.h | 6 +-
extensions/elasticsearch/tests/MockElastic.h | 2 +-
.../elasticsearch/tests/PostElasticsearchTests.cpp | 2 +-
extensions/execute-process/ExecuteProcess.cpp | 6 +-
extensions/execute-process/ExecuteProcess.h | 6 +-
extensions/expression-language/Driver.h | 12 +-
extensions/expression-language/Expression.cpp | 5 +-
extensions/expression-language/Parser.yy | 12 +-
.../impl/expression/Expression.h | 2 +-
.../tests/ExpressionLanguageTests.cpp | 4 +-
.../tests/ProcessContextExprTests.cpp | 6 +-
extensions/gcp/GCPAttributes.h | 2 +-
.../GCPCredentialsControllerService.h | 4 +-
extensions/gcp/processors/DeleteGCSObject.cpp | 4 +-
extensions/gcp/processors/DeleteGCSObject.h | 4 +-
extensions/gcp/processors/FetchGCSObject.cpp | 4 +-
extensions/gcp/processors/FetchGCSObject.h | 4 +-
extensions/gcp/processors/GCSProcessor.cpp | 2 +-
extensions/gcp/processors/GCSProcessor.h | 4 +-
extensions/gcp/processors/ListGCSBucket.cpp | 4 +-
extensions/gcp/processors/ListGCSBucket.h | 6 +-
extensions/gcp/processors/PutGCSObject.cpp | 4 +-
extensions/gcp/processors/PutGCSObject.h | 4 +-
.../tests/GCPCredentialsControllerServiceTests.cpp | 6 +-
extensions/grafana-loki/PushGrafanaLoki.cpp | 2 +-
extensions/grafana-loki/PushGrafanaLoki.h | 8 +-
extensions/grafana-loki/PushGrafanaLokiGrpc.h | 1 -
extensions/grafana-loki/PushGrafanaLokiREST.cpp | 2 +-
.../grafana-loki/tests/MockGrafanaLokiREST.h | 2 +-
extensions/kafka/ConsumeKafka.cpp | 4 +-
extensions/kafka/ConsumeKafka.h | 4 +-
extensions/kafka/KafkaConnection.cpp | 2 +-
extensions/kafka/KafkaConnection.h | 4 +-
extensions/kafka/KafkaProcessorBase.cpp | 2 +-
extensions/kafka/KafkaProcessorBase.h | 2 +-
extensions/kafka/PublishKafka.cpp | 10 +-
extensions/kafka/PublishKafka.h | 10 +-
extensions/kafka/rdkafka_utils.cpp | 2 +-
extensions/kubernetes/ApiClient.h | 2 +-
.../KubernetesControllerService.cpp | 4 +-
.../KubernetesControllerService.h | 4 +-
.../processors/CollectKubernetesPodMetrics.cpp | 2 +-
.../processors/CollectKubernetesPodMetrics.h | 2 +-
extensions/libarchive/ArchiveMetadata.cpp | 4 +-
extensions/libarchive/BinFiles.cpp | 2 +-
extensions/libarchive/BinFiles.h | 8 +-
extensions/libarchive/CompressContent.cpp | 2 +-
extensions/libarchive/CompressContent.h | 8 +-
extensions/libarchive/FocusArchiveEntry.cpp | 7 +-
extensions/libarchive/FocusArchiveEntry.h | 8 +-
extensions/libarchive/ManipulateArchive.cpp | 6 +-
extensions/libarchive/ManipulateArchive.h | 8 +-
extensions/libarchive/MergeContent.cpp | 2 +-
extensions/libarchive/MergeContent.h | 4 +-
extensions/libarchive/ReadArchiveStream.h | 3 +-
extensions/libarchive/UnfocusArchiveEntry.cpp | 4 +-
extensions/libarchive/UnfocusArchiveEntry.h | 4 +-
extensions/libarchive/WriteArchiveStream.h | 2 +-
.../libarchive/tests/CompressContentTests.cpp | 6 +-
.../libarchive/tests/ManipulateArchiveTests.cpp | 2 +-
extensions/libarchive/tests/MergeFileTests.cpp | 12 +-
extensions/libarchive/tests/util/ArchiveTests.cpp | 4 +-
.../llamacpp/processors/DefaultLlamaContext.cpp | 2 +-
.../llamacpp/processors/RunLlamaCppInference.cpp | 4 +-
.../llamacpp/tests/RunLlamaCppInferenceTests.cpp | 2 +-
extensions/lua/LuaInputStream.h | 2 +-
extensions/lua/LuaLogger.h | 1 -
extensions/lua/LuaOutputStream.h | 2 +-
extensions/lua/LuaScriptFlowFile.cpp | 10 +-
extensions/lua/LuaScriptFlowFile.h | 6 +-
extensions/lua/LuaScriptStateManager.h | 2 +-
.../mqtt/processors/AbstractMQTTProcessor.cpp | 2 +-
extensions/mqtt/processors/AbstractMQTTProcessor.h | 3 +-
extensions/mqtt/processors/ConsumeMQTT.cpp | 2 +-
extensions/mqtt/processors/ConsumeMQTT.h | 8 +-
extensions/mqtt/processors/PublishMQTT.cpp | 2 +-
extensions/mqtt/processors/PublishMQTT.h | 6 +-
extensions/opc/include/fetchopc.h | 10 +-
extensions/opc/include/opc.h | 6 +-
extensions/opc/include/opcbase.h | 4 +-
extensions/opc/include/putopc.h | 6 +-
extensions/opc/src/fetchopc.cpp | 2 +-
extensions/opc/src/opc.cpp | 9 +-
extensions/opc/src/opcbase.cpp | 2 +-
extensions/opc/src/putopc.cpp | 2 +-
extensions/opencv/CaptureRTSPFrame.cpp | 2 +-
extensions/opencv/CaptureRTSPFrame.h | 4 +-
extensions/opencv/MotionDetector.cpp | 2 +-
extensions/opencv/MotionDetector.h | 4 +-
extensions/pdh/MemoryConsumptionCounter.h | 12 +-
extensions/pdh/PDHCounters.cpp | 12 +-
extensions/pdh/PDHCounters.h | 12 +-
extensions/pdh/PerformanceDataCounter.h | 12 +-
extensions/pdh/PerformanceDataMonitor.cpp | 14 +-
extensions/pdh/PerformanceDataMonitor.h | 16 +-
.../pdh/tests/PerformanceDataCounterTests.cpp | 2 +-
extensions/procfs/DiskStat.cpp | 2 +-
extensions/procfs/NetDev.cpp | 2 +-
extensions/procfs/ProcFs.h | 2 +-
extensions/procfs/ProcFsSerialization.h | 2 +-
extensions/procfs/ProcessStat.cpp | 4 +-
extensions/procfs/processors/ProcFsMonitor.cpp | 4 +-
extensions/procfs/processors/ProcFsMonitor.h | 6 +-
extensions/procfs/tests/MemInfoTests.cpp | 2 +-
extensions/prometheus/PrometheusExposerWrapper.h | 4 +-
extensions/prometheus/PrometheusMetricsPublisher.h | 2 +-
.../prometheus/PublishedMetricGaugeCollection.cpp | 2 +-
.../prometheus/PublishedMetricGaugeCollection.h | 4 +-
extensions/python/ExecutePythonProcessor.cpp | 2 +-
extensions/python/ExecutePythonProcessor.h | 6 +-
extensions/python/PythonBindings.cpp | 4 +-
extensions/python/PythonDependencyInstaller.h | 4 +-
extensions/python/PythonProcessor.h | 2 +-
extensions/python/PythonScriptEngine.h | 2 +-
extensions/python/tests/PythonManifestTests.cpp | 4 +-
extensions/python/types/PyInputStream.cpp | 2 +-
extensions/python/types/PyInputStream.h | 2 +-
extensions/python/types/PyLogger.cpp | 2 +-
extensions/python/types/PyLogger.h | 2 +-
extensions/python/types/PyOutputStream.h | 2 +-
extensions/python/types/PyProcessContext.cpp | 4 +-
extensions/python/types/PyProcessContext.h | 2 +-
extensions/python/types/PyProcessSession.cpp | 2 +-
extensions/python/types/PyRecordSetReader.h | 2 +-
extensions/python/types/PyRecordSetWriter.h | 2 +-
extensions/python/types/PySSLContextService.h | 2 +-
extensions/python/types/PyScriptFlowFile.h | 2 +-
extensions/python/types/PyStateManager.h | 2 +-
extensions/python/types/Types.h | 2 +-
.../rocksdb-repos/DatabaseContentRepository.cpp | 4 +-
.../rocksdb-repos/DatabaseContentRepository.h | 4 +-
extensions/rocksdb-repos/FlowFileLoader.cpp | 4 +-
extensions/rocksdb-repos/FlowFileLoader.h | 6 +-
extensions/rocksdb-repos/FlowFileRepository.cpp | 4 +-
extensions/rocksdb-repos/FlowFileRepository.h | 2 +-
extensions/rocksdb-repos/ProvenanceRepository.cpp | 1 -
extensions/rocksdb-repos/ProvenanceRepository.h | 2 +-
extensions/rocksdb-repos/RocksDbStream.cpp | 2 +-
extensions/rocksdb-repos/RocksDbStream.h | 12 +-
.../controllers/RocksDbStateStorage.h | 4 +-
extensions/rocksdb-repos/database/OpenRocksDb.h | 4 +-
extensions/rocksdb-repos/database/RocksDatabase.h | 2 +-
.../rocksdb-repos/database/RocksDbInstance.h | 2 +-
extensions/rocksdb-repos/database/RocksDbUtils.cpp | 4 +-
extensions/rocksdb-repos/database/RocksDbUtils.h | 2 +-
extensions/rocksdb-repos/database/WriteBatch.cpp | 12 +-
extensions/rocksdb-repos/database/WriteBatch.h | 13 +-
.../encryption/RocksDbEncryptionProvider.h | 2 +-
.../rocksdb-repos/tests/ContentSessionTests.cpp | 2 +-
.../tests/DBContentRepositoryTests.cpp | 4 +-
extensions/rocksdb-repos/tests/EncryptionTests.cpp | 1 +
extensions/rocksdb-repos/tests/ProvenanceTests.cpp | 5 +-
extensions/rocksdb-repos/tests/RepoTests.cpp | 8 +-
extensions/rocksdb-repos/tests/SwapTests.cpp | 7 +-
extensions/script/ExecuteScript.h | 4 +-
extensions/script/ScriptExecutor.h | 2 +-
extensions/sftp/client/SFTPClient.cpp | 2 +-
extensions/sftp/client/SFTPClient.h | 4 +-
extensions/sftp/processors/FetchSFTP.cpp | 4 +-
extensions/sftp/processors/FetchSFTP.h | 4 +-
extensions/sftp/processors/ListSFTP.cpp | 10 +-
extensions/sftp/processors/ListSFTP.h | 6 +-
extensions/sftp/processors/PutSFTP.cpp | 7 +-
extensions/sftp/processors/PutSFTP.h | 8 +-
extensions/sftp/processors/SFTPProcessorBase.cpp | 17 +-
extensions/sftp/processors/SFTPProcessorBase.h | 6 +-
extensions/sftp/tests/ListSFTPTests.cpp | 2 +-
extensions/sftp/tests/ListThenFetchSFTPTests.cpp | 4 +-
extensions/sftp/tests/PutSFTPTests.cpp | 4 +-
extensions/sftp/tests/tools/SFTPTestServer.cpp | 4 +-
extensions/sftp/tests/tools/SFTPTestServer.h | 2 +-
extensions/smb/FetchSmb.h | 6 +-
extensions/smb/ListSmb.h | 6 +-
extensions/smb/PutSmb.cpp | 2 +-
extensions/smb/SmbConnectionControllerService.cpp | 1 +
extensions/smb/SmbConnectionControllerService.h | 6 +-
.../tests/SmbConnectionControllerServiceTests.cpp | 1 -
.../utils/MockSmbConnectionControllerService.h | 1 -
extensions/splunk/PutSplunkHTTP.cpp | 2 +-
extensions/splunk/PutSplunkHTTP.h | 6 +-
extensions/splunk/QuerySplunkIndexingStatus.cpp | 2 +-
extensions/splunk/QuerySplunkIndexingStatus.h | 6 +-
extensions/splunk/SplunkHECProcessor.cpp | 4 +-
extensions/splunk/SplunkHECProcessor.h | 4 +-
extensions/splunk/tests/MockSplunkHEC.h | 2 +-
extensions/sql/data/JSONSQLWriter.cpp | 2 +-
extensions/sql/data/SQLRowSubscriber.h | 12 +-
extensions/sql/data/SQLRowsetProcessor.cpp | 21 +-
extensions/sql/data/SociConnectors.h | 4 +-
extensions/sql/processors/ExecuteSQL.cpp | 4 +-
extensions/sql/processors/ExecuteSQL.h | 6 +-
extensions/sql/processors/FlowFileSource.h | 2 +-
extensions/sql/processors/PutSQL.cpp | 4 +-
extensions/sql/processors/PutSQL.h | 4 +-
extensions/sql/processors/QueryDatabaseTable.cpp | 6 +-
extensions/sql/processors/QueryDatabaseTable.h | 4 +-
extensions/sql/processors/SQLProcessor.cpp | 6 +-
extensions/sql/processors/SQLProcessor.h | 2 +-
extensions/sql/services/DatabaseService.cpp | 2 +-
extensions/sql/services/DatabaseService.h | 2 +-
extensions/sql/tests/FlowFileMatcher.h | 2 +-
extensions/sql/tests/SQLTestPlan.h | 2 +
.../controllers/InMemoryKeyValueStorage.h | 2 +-
.../controllers/JsonRecordSetWriter.h | 2 +-
.../controllers/PersistentMapStateStorage.h | 6 +-
.../controllers/VolatileMapStateStorage.h | 6 +-
.../standard-processors/controllers/XMLReader.cpp | 2 +-
.../standard-processors/controllers/XMLReader.h | 2 +-
.../controllers/XMLRecordSetWriter.cpp | 2 +-
.../controllers/XMLRecordSetWriter.h | 2 +-
.../standard-processors/modbus/FetchModbusTcp.cpp | 2 +-
.../standard-processors/modbus/FetchModbusTcp.h | 4 +-
.../processors/AppendHostInfo.cpp | 4 +-
.../processors/AppendHostInfo.h | 6 +-
.../processors/AttributeRollingWindow.cpp | 2 +-
.../processors/AttributeRollingWindow.h | 5 +-
.../processors/AttributesToJSON.cpp | 6 +-
.../processors/AttributesToJSON.h | 8 +-
.../standard-processors/processors/ConvertRecord.h | 2 +-
.../processors/DefragmentText.cpp | 6 +-
.../processors/DefragmentText.h | 4 +-
.../processors/EvaluateJsonPath.h | 4 +-
.../standard-processors/processors/ExtractText.cpp | 6 +-
.../standard-processors/processors/ExtractText.h | 8 +-
.../standard-processors/processors/FetchFile.h | 4 +-
.../processors/GenerateFlowFile.cpp | 2 +-
.../processors/GenerateFlowFile.h | 10 +-
.../standard-processors/processors/GetFile.cpp | 2 +-
.../standard-processors/processors/GetFile.h | 8 +-
.../standard-processors/processors/GetTCP.cpp | 4 +-
extensions/standard-processors/processors/GetTCP.h | 10 +-
.../standard-processors/processors/HashContent.cpp | 4 +-
.../standard-processors/processors/HashContent.h | 6 +-
.../standard-processors/processors/InvokeHTTP.cpp | 8 +-
.../standard-processors/processors/InvokeHTTP.h | 12 +-
.../processors/JoltTransformJSON.h | 4 +-
.../standard-processors/processors/ListFile.cpp | 2 +-
.../standard-processors/processors/ListFile.h | 6 +-
.../processors/ListenSyslog.cpp | 4 +-
.../standard-processors/processors/ListenSyslog.h | 8 +-
.../standard-processors/processors/ListenTCP.cpp | 4 +-
.../standard-processors/processors/ListenTCP.h | 8 +-
.../standard-processors/processors/ListenUDP.cpp | 2 +-
.../standard-processors/processors/ListenUDP.h | 6 +-
.../processors/LogAttribute.cpp | 2 +-
.../standard-processors/processors/LogAttribute.h | 8 +-
.../processors/NetworkListenerProcessor.h | 6 +-
.../standard-processors/processors/PutFile.cpp | 16 +-
.../standard-processors/processors/PutFile.h | 8 +-
.../standard-processors/processors/PutTCP.cpp | 6 +-
extensions/standard-processors/processors/PutTCP.h | 10 +-
.../standard-processors/processors/PutUDP.cpp | 6 +-
extensions/standard-processors/processors/PutUDP.h | 6 +-
.../standard-processors/processors/ReplaceText.h | 12 +-
.../standard-processors/processors/RetryFlowFile.h | 10 +-
.../processors/RouteOnAttribute.h | 4 +-
.../standard-processors/processors/RouteText.cpp | 2 +-
.../standard-processors/processors/RouteText.h | 8 +-
.../processors/SegmentContent.cpp | 4 +-
.../processors/SegmentContent.h | 8 +-
.../processors/SplitContent.cpp | 6 +-
.../standard-processors/processors/SplitContent.h | 8 +-
.../standard-processors/processors/SplitJson.h | 4 +-
.../standard-processors/processors/SplitRecord.h | 14 +-
.../standard-processors/processors/SplitText.cpp | 8 +-
.../standard-processors/processors/SplitText.h | 6 +-
.../standard-processors/processors/TailFile.cpp | 2 +-
.../standard-processors/processors/TailFile.h | 8 +-
.../processors/TextFragmentUtils.h | 2 +-
.../processors/UpdateAttribute.cpp | 2 +-
.../processors/UpdateAttribute.h | 4 +-
.../tests/integration/InvokeHTTPTests.cpp | 4 +-
.../tests/integration/ProcessGroupTest.cpp | 2 +-
.../tests/integration/VerifyInvokeHTTP.h | 2 +-
.../tests/unit/AttributeRollingWindowTests.cpp | 2 +-
.../tests/unit/ControllerServiceTests.cpp | 4 +-
.../tests/unit/ExtractTextTests.cpp | 4 +-
.../tests/unit/FetchFileTests.cpp | 2 +-
.../standard-processors/tests/unit/GetTCPTests.cpp | 2 +-
.../tests/unit/HttpClientStoreTests.cpp | 12 +-
.../tests/unit/ListFileTests.cpp | 2 +-
.../tests/unit/ProcessorTests.cpp | 8 +-
.../tests/unit/PutFileTests.cpp | 4 +-
.../standard-processors/tests/unit/PutUDPTests.cpp | 2 +-
.../tests/unit/ReplaceTextTests.cpp | 1 +
.../tests/unit/RouteTextTests.cpp | 3 +-
.../tests/unit/SegmentContentTests.cpp | 2 +-
.../tests/unit/SplitContentTests.cpp | 2 +-
.../tests/unit/SplitTextTests.cpp | 2 +-
.../tests/unit/TailFileTests.cpp | 3 +-
.../tests/unit/YamlConnectionParserTest.cpp | 2 +-
extensions/standard-processors/utils/JoltUtils.cpp | 23 +-
extensions/standard-processors/utils/JoltUtils.h | 4 +-
extensions/systemd/Common.h | 9 +-
extensions/systemd/ConsumeJournald.cpp | 4 +-
extensions/systemd/ConsumeJournald.h | 8 +-
extensions/systemd/libwrapper/DlopenWrapper.cpp | 4 +-
extensions/systemd/libwrapper/LibWrapper.cpp | 10 +-
extensions/systemd/libwrapper/LibWrapper.h | 12 +-
extensions/systemd/tests/ConsumeJournaldTest.cpp | 4 +-
extensions/test-processors/KamikazeProcessor.cpp | 4 +-
extensions/test-processors/KamikazeProcessor.h | 4 +-
.../windows-event-log/ConsumeWindowsEventLog.cpp | 4 +-
.../windows-event-log/ConsumeWindowsEventLog.h | 10 +-
extensions/windows-event-log/TailEventLog.cpp | 4 +-
extensions/windows-event-log/TailEventLog.h | 18 +-
.../windows-event-log/tests/BookmarkTests.cpp | 2 +-
extensions/windows-event-log/tests/CWELTestUtils.h | 2 +-
extensions/windows-event-log/wel/Bookmark.h | 4 +-
extensions/windows-event-log/wel/EventPath.h | 2 +-
extensions/windows-event-log/wel/JSONUtils.cpp | 2 +-
extensions/windows-event-log/wel/JSONUtils.h | 20 +-
extensions/windows-event-log/wel/MetadataWalker.h | 2 +-
.../windows-event-log/wel/WindowsEventLog.cpp | 2 +-
extensions/windows-event-log/wel/WindowsEventLog.h | 2 +-
extensions/windows-event-log/wel/XMLString.h | 15 +-
fedora.sh | 83 ----
generateVersion.bat | 16 +-
generateVersion.sh | 12 +-
libminifi/include/Connection.h | 7 +-
libminifi/include/CronDrivenSchedulingAgent.h | 6 +-
libminifi/include/EventDrivenSchedulingAgent.h | 6 +-
libminifi/include/FlowController.h | 15 +-
libminifi/include/FlowFileRecord.h | 6 +-
libminifi/include/RemoteProcessGroupPort.h | 7 +-
libminifi/include/ResourceClaim.h | 2 +-
libminifi/include/RootProcessGroupWrapper.h | 5 +-
libminifi/include/SchedulingAgent.h | 8 +-
libminifi/include/ThreadedSchedulingAgent.h | 4 +-
libminifi/include/TimerDrivenSchedulingAgent.h | 6 +-
libminifi/include/agent/build_description.h | 5 +-
libminifi/include/c2/C2Agent.h | 2 +-
libminifi/include/c2/C2MetricsPublisher.h | 6 +-
libminifi/include/c2/C2Payload.h | 2 +-
libminifi/include/c2/C2Protocol.h | 7 +-
libminifi/include/c2/C2Trigger.h | 5 +-
libminifi/include/c2/C2Utils.h | 2 +-
libminifi/include/c2/ControllerSocketProtocol.h | 8 +-
libminifi/include/c2/HeartbeatLogger.h | 2 +-
libminifi/include/c2/HeartbeatReporter.h | 7 +-
libminifi/include/c2/PayloadSerializer.h | 23 +-
libminifi/include/c2/protocols/RESTProtocol.h | 7 +-
.../controllers/NetworkPrioritizerService.h | 5 +-
libminifi/include/controllers/SSLContextService.h | 4 +-
.../include/controllers/ThreadManagementService.h | 5 +-
.../controllers/UpdatePolicyControllerService.h | 4 +-
libminifi/include/core/FlowConfiguration.h | 7 +-
libminifi/include/core/FlowFile.h | 8 +-
libminifi/include/core/ForwardingContentSession.h | 5 +-
libminifi/include/core/ParameterContext.h | 2 +-
libminifi/include/core/ParameterTokenParser.h | 2 +-
libminifi/include/core/ProcessGroup.h | 6 +-
libminifi/include/core/ProcessSession.h | 8 +-
.../include/core/ProcessSessionReadCallback.h | 2 +-
libminifi/include/core/Processor.h | 4 +-
libminifi/include/core/RepositoryFactory.h | 4 +-
libminifi/include/core/SerializableComponent.h | 4 +-
.../core/controller/ControllerServiceLookup.h | 21 -
.../core/controller/ControllerServiceNode.h | 6 +-
.../core/controller/ControllerServiceNodeMap.h | 2 +-
.../core/controller/ControllerServiceProvider.h | 4 +-
.../ForwardingControllerServiceProvider.h | 2 +-
libminifi/include/core/extension/Executable.h | 14 +-
.../include/core/extension/ExtensionManager.h | 2 +-
libminifi/include/core/extension/Module.h | 20 +-
libminifi/include/core/extension/Utils.h | 2 +-
libminifi/include/core/flow/Node.h | 2 +-
.../include/core/flow/StructuredConfiguration.h | 2 +-
.../include/core/flow/StructuredConnectionParser.h | 2 +-
libminifi/include/core/json/JsonNode.h | 2 +-
libminifi/include/core/logging/LoggerBase.h | 2 +-
.../include/core/logging/LoggerConfiguration.h | 2 +-
libminifi/include/core/logging/LoggerFactory.h | 43 --
.../include/core/logging/WindowsEventLogSink.h | 16 +-
libminifi/include/core/logging/alert/AlertSink.h | 5 +-
.../core/logging/internal/ActiveCompressor.h | 18 +-
.../core/logging/internal/CompressionManager.h | 22 +-
.../include/core/logging/internal/LogBuffer.h | 16 +-
.../include/core/logging/internal/LogCompressor.h | 18 +-
.../reporting/SiteToSiteProvenanceReportingTask.h | 1 -
.../include/core/repository/AtomicRepoEntries.h | 2 +-
.../repository/LegacyVolatileContentRepository.h | 3 +-
.../core/repository/VolatileFlowFileRepository.h | 3 +-
.../core/repository/VolatileProvenanceRepository.h | 1 -
.../include/core/repository/VolatileRepository.h | 2 -
libminifi/include/core/state/ConnectionStore.h | 4 +-
libminifi/include/core/state/LogMetricsPublisher.h | 4 +-
.../include/core/state/MetricsPublisherFactory.h | 2 +-
.../include/core/state/MetricsPublisherStore.h | 5 +-
libminifi/include/core/state/UpdateController.h | 19 +-
libminifi/include/core/state/UpdatePolicy.h | 21 +-
.../include/core/state/nodes/AgentInformation.h | 6 +-
.../include/core/state/nodes/AssetInformation.h | 2 +-
.../core/state/nodes/ConfigurationChecksums.h | 2 +-
.../include/core/state/nodes/DeviceInformation.h | 3 +-
.../include/core/state/nodes/FlowInformation.h | 4 +-
libminifi/include/core/state/nodes/MetricsBase.h | 2 -
libminifi/include/core/state/nodes/QueueMetrics.h | 1 -
.../include/core/state/nodes/RepositoryMetrics.h | 2 +-
.../state/nodes/RepositoryMetricsSourceStore.h | 4 +-
.../include/core/state/nodes/ResponseNodeLoader.h | 6 +-
libminifi/include/core/yaml/YamlConfiguration.h | 2 +-
libminifi/include/core/yaml/YamlNode.h | 2 +-
libminifi/include/io/AtomicEntryStream.h | 21 +-
libminifi/include/io/NetworkPrioritizer.h | 17 +-
libminifi/include/properties/Configuration.h | 2 +-
libminifi/include/properties/Decryptor.h | 10 +-
libminifi/include/properties/Properties.h | 2 +-
libminifi/include/provenance/Provenance.h | 9 +-
.../include/sitetosite/HttpSiteToSiteClient.h | 2 +-
libminifi/include/sitetosite/RawSiteToSiteClient.h | 3 +-
libminifi/include/sitetosite/SiteToSiteClient.h | 2 +-
libminifi/include/utils/FlowFileQueue.h | 3 +-
libminifi/include/utils/MinMaxHeap.h | 2 +-
libminifi/include/utils/StagingQueue.h | 12 +-
libminifi/include/utils/file/AssetManager.h | 2 +-
libminifi/include/utils/file/FileSystem.h | 14 +-
libminifi/include/utils/tls/DistinguishedName.h | 14 +-
libminifi/include/utils/tls/ExtendedKeyUsage.h | 2 +-
libminifi/include/utils/tls/TLSUtils.h | 14 +-
libminifi/src/Configuration.cpp | 3 -
libminifi/src/Configure.cpp | 2 +-
libminifi/src/Connection.cpp | 2 +-
libminifi/src/CronDrivenSchedulingAgent.cpp | 4 +-
libminifi/src/DiskSpaceWatchdog.cpp | 4 +-
libminifi/src/EventDrivenSchedulingAgent.cpp | 6 +-
libminifi/src/Exception.cpp | 2 +-
libminifi/src/FlowController.cpp | 9 +-
libminifi/src/FlowFileRecord.cpp | 11 +-
libminifi/src/RemoteProcessGroupPort.cpp | 15 +-
libminifi/src/ResourceClaim.cpp | 3 +-
libminifi/src/SchedulingAgent.cpp | 2 +-
libminifi/src/ThreadedSchedulingAgent.cpp | 7 +-
libminifi/src/agent/JsonSchema.cpp | 4 +-
libminifi/src/c2/C2Agent.cpp | 12 +-
libminifi/src/c2/C2MetricsPublisher.cpp | 5 +-
.../src/c2/ControllerSocketMetricsPublisher.cpp | 2 +-
libminifi/src/c2/ControllerSocketProtocol.cpp | 32 +-
libminifi/src/c2/HeartbeatJsonSerializer.cpp | 3 +-
libminifi/src/c2/PayloadSerializer.cpp | 12 +-
libminifi/src/c2/protocols/RESTProtocol.cpp | 2 +-
libminifi/src/c2/protocols/RESTSender.cpp | 23 +-
.../controllers/UpdatePolicyControllerService.cpp | 2 -
libminifi/src/core/ClassLoader.cpp | 17 +-
libminifi/src/core/FlowConfiguration.cpp | 2 +
libminifi/src/core/FlowFile.cpp | 2 +-
libminifi/src/core/ForwardingContentSession.cpp | 7 +-
libminifi/src/core/ParameterContext.cpp | 2 +-
libminifi/src/core/ProcessGroup.cpp | 2 +-
libminifi/src/core/ProcessSession.cpp | 11 +-
libminifi/src/core/ProcessSessionFactory.cpp | 12 +-
libminifi/src/core/ProcessSessionReadCallback.cpp | 4 +-
libminifi/src/core/Processor.cpp | 6 +-
libminifi/src/core/RepositoryFactory.cpp | 2 -
.../core/controller/ControllerServiceProvider.cpp | 2 +-
libminifi/src/core/extension/DynamicLibrary.cpp | 1 -
libminifi/src/core/extension/ExtensionManager.cpp | 2 +-
libminifi/src/core/extension/Module.cpp | 2 +-
libminifi/src/core/flow/CheckRequiredField.cpp | 4 +-
libminifi/src/core/logging/LoggerConfiguration.cpp | 12 +-
libminifi/src/core/logging/WindowsEventLogSink.cpp | 18 +-
libminifi/src/core/logging/alert/AlertSink.cpp | 27 +-
.../core/logging/internal/CompressionManager.cpp | 4 +-
.../src/core/logging/internal/LogCompressor.cpp | 17 +-
.../SiteToSiteProvenanceReportingTask.cpp | 8 +-
.../src/core/repository/VolatileRepository.cpp | 1 -
.../src/core/repository/VolatileRepositoryData.cpp | 4 +-
libminifi/src/core/state/MetricsPublisherStore.cpp | 1 +
libminifi/src/core/state/UpdateController.cpp | 12 +-
libminifi/src/core/state/Value.cpp | 2 +-
.../src/core/state/nodes/AgentInformation.cpp | 2 +-
.../src/core/state/nodes/BuildInformation.cpp | 2 +-
.../src/core/state/nodes/DeviceInformation.cpp | 3 +-
.../src/core/state/nodes/RepositoryMetrics.cpp | 2 +-
.../src/core/state/nodes/ResponseNodeLoader.cpp | 2 +-
libminifi/src/io/AtomicEntryStream.cpp | 33 --
.../EnvironmentVariableParameterProvider.cpp | 2 +-
libminifi/src/provenance/Provenance.cpp | 8 +-
libminifi/src/sitetosite/HttpSiteToSiteClient.cpp | 14 +-
libminifi/src/sitetosite/RawSiteToSiteClient.cpp | 2 +-
libminifi/src/sitetosite/SiteToSiteClient.cpp | 3 +-
libminifi/src/utils/CallBackTimer.cpp | 92 ----
libminifi/src/utils/tls/DistinguishedName.cpp | 2 +-
libminifi/src/utils/tls/TLSUtils.cpp | 2 +-
libminifi/test/flow-tests/CustomProcessors.h | 4 +-
libminifi/test/flow-tests/FlowControllerTests.cpp | 4 +-
libminifi/test/flow-tests/SessionTests.cpp | 1 +
libminifi/test/integration/AlertTests.cpp | 9 +-
libminifi/test/integration/C2DebugBundleTest.cpp | 2 +-
libminifi/test/integration/C2NullConfiguration.cpp | 2 +-
.../test/integration/C2PropertiesUpdateTests.cpp | 2 +-
libminifi/test/integration/C2UpdateTest.cpp | 2 +-
libminifi/test/integration/HTTPClientTests.cpp | 12 +-
.../integration/OnScheduleErrorHandlingTests.cpp | 4 +-
libminifi/test/integration/SiteToSiteRestTest.cpp | 2 +-
.../keyvalue-tests/PersistentStateStorageTest.cpp | 1 -
libminifi/test/libtest/integration/CivetStream.h | 3 +-
.../integration/ConnectionCountingServer.cpp | 6 +-
.../test/libtest/integration/HTTPHandlers.cpp | 2 +-
libminifi/test/libtest/integration/HTTPHandlers.h | 9 -
.../libtest/integration/HTTPIntegrationBase.cpp | 4 +-
.../test/libtest/integration/IntegrationBase.cpp | 1 +
libminifi/test/libtest/unit/MockClasses.h | 6 +-
libminifi/test/libtest/unit/ProvenanceTestHelper.h | 4 +-
.../libtest/unit/ReadFromFlowFileTestProcessor.cpp | 2 +-
.../libtest/unit/ReadFromFlowFileTestProcessor.h | 6 +-
libminifi/test/libtest/unit/RecordSetTesters.h | 4 +-
.../libtest/unit/SingleProcessorTestController.cpp | 5 +-
.../libtest/unit/SingleProcessorTestController.h | 4 +-
libminifi/test/libtest/unit/SiteToSiteHelper.h | 2 +-
libminifi/test/libtest/unit/StatefulProcessor.cpp | 4 +-
libminifi/test/libtest/unit/StatefulProcessor.h | 2 +-
libminifi/test/libtest/unit/TestBase.cpp | 10 +-
libminifi/test/libtest/unit/TestBase.h | 5 +-
libminifi/test/libtest/unit/TestUtils.cpp | 18 +-
libminifi/test/libtest/unit/TestUtils.h | 3 +-
.../libtest/unit/WriteToFlowFileTestProcessor.cpp | 2 +-
.../libtest/unit/WriteToFlowFileTestProcessor.h | 10 +-
.../test/persistence-tests/PersistenceTests.cpp | 3 +
.../test/resources/encrypted.minifi.properties | 1 -
libminifi/test/schema-tests/SchemaTests.cpp | 2 +-
libminifi/test/unit/ArrayUtilsTests.cpp | 8 +-
libminifi/test/unit/BackTraceTests.cpp | 2 +-
libminifi/test/unit/CRCTests.cpp | 4 +-
libminifi/test/unit/CertificateUtilsTests.cpp | 2 +-
libminifi/test/unit/ComponentManifestTests.cpp | 2 +-
.../unit/ControllerSocketMetricsPublisherTest.cpp | 2 +-
libminifi/test/unit/CronTests.cpp | 2 +
libminifi/test/unit/EnvironmentUtilsTests.cpp | 7 +-
.../EnvironmentVariableParameterProviderTest.cpp | 12 +-
libminifi/test/unit/ExceptionTests.cpp | 2 +-
libminifi/test/unit/ExpectedTest.cpp | 2 +-
libminifi/test/unit/ExtendedKeyUsageTests.cpp | 20 +-
libminifi/test/unit/ExtensionVerificationTests.cpp | 2 +-
libminifi/test/unit/FileSystemRepositoryTests.cpp | 5 +-
libminifi/test/unit/FileUtilsTests.cpp | 2 +-
libminifi/test/unit/FlowFileQueueSwapTests.cpp | 20 +-
libminifi/test/unit/FlowFileQueueTests.cpp | 1 +
libminifi/test/unit/FlowFileSerializationTests.cpp | 2 +-
libminifi/test/unit/FlowStatusBuilderTests.cpp | 2 +
libminifi/test/unit/GeneralUtilsTest.cpp | 60 +--
libminifi/test/unit/HTTPStreamingCallbackTests.cpp | 2 +-
libminifi/test/unit/IdTests.cpp | 1 +
libminifi/test/unit/MapUtilsTests.cpp | 4 +-
libminifi/test/unit/MemoryUsageTest.cpp | 2 +-
libminifi/test/unit/MetricsPublisherStoreTests.cpp | 2 +
libminifi/test/unit/MetricsTests.cpp | 1 +
libminifi/test/unit/MinifiConcurrentQueueTests.cpp | 2 +-
libminifi/test/unit/NetworkInterfaceInfoTests.cpp | 2 +-
.../test/unit/NetworkPrioritizerServiceTests.cpp | 2 +-
libminifi/test/unit/ParameterTokenParserTest.cpp | 16 +-
libminifi/test/unit/ProcessContextTest.cpp | 4 +-
libminifi/test/unit/ProcessorConfigUtilsTests.cpp | 5 +-
libminifi/test/unit/RegexUtilsTests.cpp | 1 -
libminifi/test/unit/ResponseNodeLoaderTests.cpp | 3 +-
libminifi/test/unit/SchedulingAgentTests.cpp | 2 +
libminifi/test/unit/SiteToSiteTests.cpp | 8 +-
libminifi/test/unit/StreamTests.cpp | 2 +-
libminifi/test/unit/StringUtilsTests.cpp | 20 +-
libminifi/test/unit/TimeUtilTests.cpp | 6 +-
libminifi/test/unit/UpdatePolicyTests.cpp | 1 -
libminifi/test/unit/ZlibStreamTests.cpp | 2 +-
linux.sh | 60 ---
minifi-api/include/minifi-cpp/Connection.h | 7 +-
minifi-api/include/minifi-cpp/FlowFileRecord.h | 2 +-
minifi-api/include/minifi-cpp/ResourceClaim.h | 1 -
.../minifi-cpp/controllers/RecordSetReader.h | 6 +-
.../minifi-cpp/core/AgentIdentificationProvider.h | 12 +-
minifi-api/include/minifi-cpp/core/Annotation.h | 14 +-
minifi-api/include/minifi-cpp/core/ClassLoader.h | 4 +-
minifi-api/include/minifi-cpp/core/Connectable.h | 2 +-
.../include/minifi-cpp/core/ContentRepository.h | 2 +-
.../include/minifi-cpp/core/ContentSession.h | 2 +-
minifi-api/include/minifi-cpp/core/FlowFile.h | 4 +-
minifi-api/include/minifi-cpp/core/ObjectFactory.h | 4 +-
.../minifi-cpp/core/ProcessContextBuilder.h | 2 +-
minifi-api/include/minifi-cpp/core/ProcessorApi.h | 5 +-
minifi-api/include/minifi-cpp/core/Property.h | 2 +-
.../include/minifi-cpp/core/PropertyDefinition.h | 2 +-
minifi-api/include/minifi-cpp/core/Repository.h | 2 +-
.../minifi-cpp/core/SerializableComponent.h | 6 +-
minifi-api/include/minifi-cpp/core/StreamManager.h | 4 +-
.../include/minifi-cpp/core/TraceableResource.h | 12 +-
.../core/controller/ControllerServiceNode.h | 2 +-
.../core/controller/ControllerServiceProvider.h | 2 +-
.../include/minifi-cpp/core/logging/Logger.h | 2 +-
minifi-api/include/minifi-cpp/io/ArchiveStream.h | 2 +-
minifi-api/include/minifi-cpp/io/OutputStream.h | 14 +-
minifi-api/include/minifi-cpp/io/Stream.h | 2 +-
.../include/minifi-cpp/properties/Configuration.h | 3 -
.../include/minifi-cpp/properties/Configure.h | 2 +-
.../include/minifi-cpp/provenance/Provenance.h | 2 +-
.../include/minifi-cpp/utils/PropertyExceptions.h | 2 +-
minifi_main/AgentDocs.cpp | 2 +-
minifi_main/Fips.h | 2 +-
minifi_main/MiNiFiMain.cpp | 2 +-
minifi_main/TableFormatter.cpp | 2 +-
rheldistro.sh | 91 ----
suse.sh | 96 ----
824 files changed, 1735 insertions(+), 5092 deletions(-)
delete mode 100644 aptitude.sh
delete mode 100644 arch.sh
delete mode 100755 bootstrap.sh
delete mode 100755 bstrp_functions.sh
delete mode 100644 centos.sh
delete mode 100644 core-framework/include/Exception.h
delete mode 100644 core-framework/include/SwapManager.h
delete mode 100644 core-framework/include/agent/agent_version.h
delete mode 100644 core-framework/include/core/Annotation.h
delete mode 100644 core-framework/include/core/OutputAttributeDefinition.h
delete mode 100644 core-framework/include/core/Property.h
delete mode 100644 core-framework/include/core/PropertyDefinition.h
delete mode 100644 core-framework/include/core/RelationshipDefinition.h
delete mode 100644 core-framework/include/core/logging/Logger.h
delete mode 100644 core-framework/include/io/ArchiveStream.h
delete mode 100644 core-framework/include/utils/Export.h
delete mode 100644 core-framework/include/utils/Literals.h
delete mode 100644 core-framework/include/utils/PropertyExceptions.h
delete mode 100644 core-framework/include/utils/gsl.h
rename {extension-framework => core-framework}/src/utils/CallBackTimer.cpp (100%)
delete mode 100644 darwin.sh
delete mode 100644 debian.sh
delete mode 100755 deploy.sh
delete mode 100644 extension-framework/include/FlowFileRecord.h
delete mode 100644 extension-framework/include/ResourceClaim.h
delete mode 100644 extension-framework/include/controllers/SSLContextService.h
delete mode 100644 extension-framework/include/controllers/SSLContextServiceInterface.h
delete mode 100644 extension-framework/include/core/FlowFile.h
delete mode 100644 extension-framework/include/properties/Configure.h
delete mode 100644 extension-framework/include/properties/Properties.h
delete mode 100644 extension-framework/src/core/ProcessContext.cpp
delete mode 100644 fedora.sh
delete mode 100644 libminifi/include/core/controller/ControllerServiceLookup.h
delete mode 100644 libminifi/include/core/logging/LoggerFactory.h
delete mode 100644 libminifi/src/io/AtomicEntryStream.cpp
delete mode 100644 libminifi/src/utils/CallBackTimer.cpp
delete mode 100644 linux.sh
delete mode 100644 rheldistro.sh
delete mode 100644 suse.sh
(nifi-minifi-cpp) 01/04: MINIFICPP-2232 Remove option to load SSL context from flow config
Posted by sz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
szaszm pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/nifi-minifi-cpp.git
commit 8cb945b10e314f3927d15921265aa0a345fddcea
Author: Gabor Gyimesi <ga...@gmail.com>
AuthorDate: Fri Oct 17 17:01:17 2025 +0200
MINIFICPP-2232 Remove option to load SSL context from flow config
Closes #1986
Signed-off-by: Marton Szasz <sz...@apache.org>
---
C2.md | 3 -
CONFIGURE.md | 11 +-
OPS.md | 8 +-
conf/minifi-log.properties.in | 1 -
conf/minifi.properties.in | 2 -
controller/MiNiFiController.cpp | 49 +-------
controller/tests/ControllerTests.cpp | 75 +------------
core-framework/include/http/BaseHTTPClient.h | 31 +++++-
core-framework/src/http/BaseHTTPClient.cpp | 7 +-
core-framework/src/http/HTTPClient.cpp | 10 +-
.../cluster/containers/MinifiContainer.py | 1 -
.../integration/features/minifi_c2_server.feature | 8 --
docker/test/integration/features/steps/steps.py | 12 --
encrypt-config/tests/ConfigFileEncryptorTests.cpp | 2 +-
encrypt-config/tests/ConfigFileTests.cpp | 8 +-
encrypt-config/tests/resources/minifi.properties | 1 -
...th-additional-sensitive-props.minifi.properties | 1 -
.../aws/tests/MultipartUploadStateStorageTest.cpp | 2 +-
extensions/civetweb/tests/ListenHTTPTests.cpp | 124 ++++++++++-----------
extensions/elasticsearch/PostElasticsearch.cpp | 2 +-
extensions/grafana-loki/PushGrafanaLokiREST.cpp | 2 +-
.../tests/SmbConnectionControllerServiceTests.cpp | 1 -
extensions/splunk/SplunkHECProcessor.cpp | 2 +-
.../standard-processors/processors/InvokeHTTP.cpp | 2 +-
.../standard-processors/processors/InvokeHTTP.h | 2 +-
.../tests/unit/HttpClientStoreTests.cpp | 12 +-
libminifi/include/c2/ControllerSocketProtocol.h | 4 +-
.../include/core/logging/LoggerConfiguration.h | 2 +-
libminifi/include/core/logging/alert/AlertSink.h | 5 +-
libminifi/src/Configuration.cpp | 3 -
libminifi/src/FlowController.cpp | 4 +-
libminifi/src/RemoteProcessGroupPort.cpp | 8 +-
libminifi/src/c2/ControllerSocketProtocol.cpp | 30 ++---
libminifi/src/c2/protocols/RESTSender.cpp | 23 ++--
libminifi/src/core/logging/LoggerConfiguration.cpp | 10 +-
libminifi/src/core/logging/alert/AlertSink.cpp | 27 +----
libminifi/src/sitetosite/HttpSiteToSiteClient.cpp | 12 +-
libminifi/test/integration/AlertTests.cpp | 9 +-
libminifi/test/integration/HTTPClientTests.cpp | 12 +-
libminifi/test/libtest/unit/TestBase.h | 1 +
.../test/resources/encrypted.minifi.properties | 1 -
libminifi/test/unit/ArrayUtilsTests.cpp | 8 +-
.../EnvironmentVariableParameterProviderTest.cpp | 12 +-
libminifi/test/unit/GeneralUtilsTest.cpp | 60 +++++-----
libminifi/test/unit/ParameterTokenParserTest.cpp | 16 +--
.../include/minifi-cpp/properties/Configuration.h | 3 -
46 files changed, 237 insertions(+), 392 deletions(-)
diff --git a/C2.md b/C2.md
index 2b5a8b2cc..8ec0c9562 100644
--- a/C2.md
+++ b/C2.md
@@ -106,9 +106,6 @@ be requested via C2 DESCRIBE manifest command.
# c2 agent class -- must be defined to run agent
nifi.c2.agent.class=<your agent class>
- # configure SSL Context service for REST Protocol
- #nifi.c2.rest.ssl.context.service
-
# specify encoding strategy for c2 requests (gzip, none)
#nifi.c2.rest.request.encoding=none
diff --git a/CONFIGURE.md b/CONFIGURE.md
index 886e47939..5773ee47d 100644
--- a/CONFIGURE.md
+++ b/CONFIGURE.md
@@ -1071,7 +1071,16 @@ Here's an example of an alert appender with its available properties:
appender.alert1.batch.size=100 KB
appender.alert1.buffer.limit=1 MB
appender.alert1.level=TRACE
- appender.alert1.ssl.context.service=<Name of the SSLContextService>
+
+If you want to use SSL connection for the alert appender, you can set up the certificate configuration properties in the minifi.properties file:
+
+ # setup the client certificate and private key PEM files
+ nifi.security.client.certificate=./conf/client.pem
+ nifi.security.client.private.key=./conf/client.pem
+ # setup the client private key passphrase file
+ nifi.security.client.pass.phrase=./conf/password
+ # setup the client CA certificate file
+ nifi.security.client.ca.certificate=./conf/nifi-cert.pem
### Log levels
After the appenders are defined you can set the log level and logging target for each of them. Appenders can be set to log everything on a specific log level, but you can also define some appenders to only write logs from specific namespaces or classes with different log levels. The log level can be set to one of the following values: OFF, TRACE, DEBUG, INFO, WARN, ERROR, CRITICAL. The log levels can be set in the following way:
diff --git a/OPS.md b/OPS.md
index 32c8c1583..c5a780c8f 100644
--- a/OPS.md
+++ b/OPS.md
@@ -69,13 +69,9 @@ The executable is stored in the bin directory and is titled minifi-controller. A
### SSL
-To use secure connection for the C2 commands, both the MiNiFi C++ agent and the controller have to be started with either of the following configurations.
+To use secure connection for the C2 commands, both the MiNiFi C++ agent and the controller have to be started with the following configurations.
-To retrieve the SSL configuration properties from the flow config, set the following property to the name of the SSL context service holding the information:
-
- $ controller.ssl.context.service=SSLContextService
-
-Otherwise if you prefer to retrieve the SSL configuration properties from the minifi.properties file set the nifi.remote.input.secure property value to true and configure the security properties in the minifi.properties file.
+To retrieve the SSL configuration properties from the minifi.properties file set the nifi.remote.input.secure property value to true and configure the security properties in the minifi.properties file.
$ nifi.remote.input.secure=true
$ nifi.security.client.certificate=/path/to/cert/mycert.crt
diff --git a/conf/minifi-log.properties.in b/conf/minifi-log.properties.in
index dc6ac9397..9d9946715 100644
--- a/conf/minifi-log.properties.in
+++ b/conf/minifi-log.properties.in
@@ -47,7 +47,6 @@ appender.rolling.max_file_size=20 MB
#appender.alert1.batch.size=100 KB
#appender.alert1.buffer.limit=1 MB
#appender.alert1.level=TRACE
-#appender.alert1.ssl.context.service=<Name of the SSLContextService>
# Uncomment if you do not want to include the UUID of the component at the end of log lines
#logger.include.uuid=false
diff --git a/conf/minifi.properties.in b/conf/minifi.properties.in
index 01441816c..7eceafc60 100644
--- a/conf/minifi.properties.in
+++ b/conf/minifi.properties.in
@@ -93,7 +93,6 @@ nifi.content.repository.class.name=DatabaseContentRepository
#nifi.c2.rest.path.base=
#nifi.c2.rest.url=
#nifi.c2.rest.url.ack=
-#nifi.c2.rest.ssl.context.service=
nifi.c2.root.classes=DeviceInfoNode,AgentInformation,FlowInformation,AssetInformation
## Minimize heartbeat payload size by excluding agent manifest from the heartbeat
nifi.c2.full.heartbeat=false
@@ -129,7 +128,6 @@ nifi.c2.full.heartbeat=false
#controller.socket.host=localhost
#controller.socket.port=9998
#controller.socket.local.any.interface=false
-#controller.ssl.context.service=SSLContextService
## specify the destination of c2 directed assets
nifi.asset.directory=@MINIFI_PATH_ASSET_DIR@
diff --git a/controller/MiNiFiController.cpp b/controller/MiNiFiController.cpp
index 3b52599be..619415c25 100644
--- a/controller/MiNiFiController.cpp
+++ b/controller/MiNiFiController.cpp
@@ -38,55 +38,14 @@
namespace minifi = org::apache::nifi::minifi;
-std::shared_ptr<minifi::core::controller::ControllerService> getControllerService(const std::shared_ptr<minifi::Configure> &configuration,
- const std::string &service_name) {
- std::string nifi_configuration_class_name = "adaptiveconfiguration";
-
- minifi::core::extension::ExtensionManagerImpl::get().initialize(configuration);
-
- configuration->get(minifi::Configure::nifi_configuration_class_name, nifi_configuration_class_name);
- auto flow_configuration = minifi::core::createFlowConfiguration(
- minifi::core::ConfigurationContext{
- .flow_file_repo = nullptr,
- .content_repo = nullptr,
- .configuration = configuration,
- .path = configuration->get(minifi::Configure::nifi_flow_configuration_file)},
- nifi_configuration_class_name);
-
- auto root = flow_configuration->getRoot();
- if (!root) {
- return nullptr;
- }
- auto controller = root->findControllerService(service_name);
- if (!controller) {
- return nullptr;
- }
- return controller->getControllerServiceImplementation();
-}
-
std::shared_ptr<minifi::controllers::SSLContextServiceInterface> getSSLContextService(const std::shared_ptr<minifi::Configure>& configuration) {
std::shared_ptr<minifi::controllers::SSLContextServiceInterface> secure_context;
- std::string context_name;
- // if the user wishes to use a controller service we need to instantiate the flow
- if (configuration->get(minifi::Configure::controller_ssl_context_service, context_name) && !context_name.empty()) {
- const auto service = getControllerService(configuration, context_name);
- if (nullptr != service) {
- secure_context = std::dynamic_pointer_cast<minifi::controllers::SSLContextServiceInterface>(service);
- }
- if (secure_context == nullptr) {
- throw minifi::Exception(minifi::GENERAL_EXCEPTION, "SSL Context was set, but the context name '" + context_name + "' could not be found");
- }
- }
-
- if (nullptr == secure_context) {
- std::string secureStr;
- if (configuration->get(minifi::Configure::nifi_remote_input_secure, secureStr) && minifi::utils::string::toBool(secureStr).value_or(false)) {
- secure_context = std::make_shared<minifi::controllers::SSLContextService>("ControllerSocketProtocolSSL", configuration);
- secure_context->onEnable();
- }
- } else {
+ std::string secure_str;
+ if (configuration->get(minifi::Configure::nifi_remote_input_secure, secure_str) && minifi::utils::string::toBool(secure_str).value_or(false)) {
+ secure_context = std::make_shared<minifi::controllers::SSLContextService>("ControllerSocketProtocolSSL", configuration);
secure_context->onEnable();
}
+
return secure_context;
}
diff --git a/controller/tests/ControllerTests.cpp b/controller/tests/ControllerTests.cpp
index 38f405f9c..778062d42 100644
--- a/controller/tests/ControllerTests.cpp
+++ b/controller/tests/ControllerTests.cpp
@@ -212,40 +212,10 @@ class TestControllerSocketReporter : public c2::ControllerSocketReporter {
}
};
-class TestControllerServiceProvider : public core::controller::ControllerServiceProviderImpl {
- public:
- explicit TestControllerServiceProvider(std::shared_ptr<controllers::SSLContextServiceInterface> ssl_context_service)
- : core::controller::ControllerServiceProviderImpl("TestControllerServiceProvider"),
- ssl_context_service_(std::move(ssl_context_service)) {
- }
- std::shared_ptr<core::controller::ControllerService> getControllerService(const std::string&) const override {
- return is_ssl_ ? ssl_context_service_ : nullptr;
- }
-
- std::shared_ptr<core::controller::ControllerServiceNode> createControllerService(const std::string&, const std::string&) override {
- return nullptr;
- }
- void clearControllerServices() override {
- }
- void enableAllControllerServices() override {
- }
- void disableAllControllerServices() override {
- }
-
- void setSsl() {
- is_ssl_ = true;
- }
-
- private:
- bool is_ssl_{};
- std::shared_ptr<controllers::SSLContextServiceInterface> ssl_context_service_;
-};
-
class ControllerTestFixture {
public:
enum class ConnectionType {
UNSECURE,
- SSL_FROM_SERVICE_PROVIDER,
SSL_FROM_CONFIGURATION
};
@@ -259,10 +229,8 @@ class ControllerTestFixture {
configuration_->set(minifi::Configure::nifi_security_client_private_key, (minifi::utils::file::FileUtils::get_executable_dir() / "resources" / "minifi-cpp-flow.key").string());
configuration_->set(minifi::Configure::nifi_security_client_pass_phrase, "abcdefgh");
configuration_->set(minifi::Configure::nifi_security_client_ca_certificate, (minifi::utils::file::FileUtils::get_executable_dir() / "resources" / "root-ca.pem").string());
- configuration_->set(minifi::Configure::controller_ssl_context_service, "SSLContextService");
ssl_context_service_ = std::make_shared<controllers::SSLContextService>("SSLContextService", configuration_);
ssl_context_service_->onEnable();
- controller_service_provider_ = std::make_unique<TestControllerServiceProvider>(ssl_context_service_);
controller_socket_data_.host = "localhost";
controller_socket_data_.port = 9997;
}
@@ -271,10 +239,7 @@ class ControllerTestFixture {
if (connection_type_ == ConnectionType::SSL_FROM_CONFIGURATION) {
configuration_->set(minifi::Configure::nifi_remote_input_secure, "true");
}
- controller_socket_protocol_ = std::make_unique<minifi::c2::ControllerSocketProtocol>(*controller_service_provider_, *update_sink_, configuration_, reporter);
- if (connection_type_ == ConnectionType::SSL_FROM_SERVICE_PROVIDER) {
- controller_service_provider_->setSsl();
- }
+ controller_socket_protocol_ = std::make_unique<minifi::c2::ControllerSocketProtocol>(*update_sink_, configuration_, reporter);
controller_socket_protocol_->initialize();
}
@@ -294,15 +259,11 @@ class ControllerTestFixture {
std::unique_ptr<TestUpdateSink> update_sink_;
std::unique_ptr<minifi::c2::ControllerSocketProtocol> controller_socket_protocol_;
std::shared_ptr<controllers::SSLContextServiceInterface> ssl_context_service_;
- std::unique_ptr<TestControllerServiceProvider> controller_service_provider_;
+
minifi::utils::net::SocketData controller_socket_data_;
};
TEST_CASE_METHOD(ControllerTestFixture, "Test listComponents", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
@@ -329,10 +290,6 @@ TEST_CASE_METHOD(ControllerTestFixture, "Test listComponents", "[controllerTests
}
TEST_CASE_METHOD(ControllerTestFixture, "TestClear", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
@@ -356,10 +313,6 @@ TEST_CASE_METHOD(ControllerTestFixture, "TestClear", "[controllerTests]") {
}
TEST_CASE_METHOD(ControllerTestFixture, "TestUpdate", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
@@ -382,10 +335,6 @@ TEST_CASE_METHOD(ControllerTestFixture, "TestUpdate", "[controllerTests]") {
}
TEST_CASE_METHOD(ControllerTestFixture, "Test connection getters on empty flow", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
@@ -422,10 +371,6 @@ TEST_CASE_METHOD(ControllerTestFixture, "Test connection getters on empty flow",
}
TEST_CASE_METHOD(ControllerTestFixture, "Test connection getters", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
@@ -476,10 +421,6 @@ TEST_CASE_METHOD(ControllerTestFixture, "Test connection getters", "[controllerT
}
TEST_CASE_METHOD(ControllerTestFixture, "Test manifest getter", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
@@ -499,10 +440,6 @@ TEST_CASE_METHOD(ControllerTestFixture, "Test manifest getter", "[controllerTest
}
TEST_CASE_METHOD(ControllerTestFixture, "Test jstack getter", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
@@ -527,10 +464,6 @@ TEST_CASE_METHOD(ControllerTestFixture, "Test jstack getter", "[controllerTests]
}
TEST_CASE_METHOD(ControllerTestFixture, "Test debug bundle getter", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
@@ -581,10 +514,6 @@ TEST_CASE_METHOD(ControllerTestFixture, "Debug bundle retrieval fails if target
}
TEST_CASE_METHOD(ControllerTestFixture, "Test flow status getter", "[controllerTests]") {
- SECTION("With SSL from service provider") {
- setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_SERVICE_PROVIDER);
- }
-
SECTION("With SSL from properties") {
setConnectionType(ControllerTestFixture::ConnectionType::SSL_FROM_CONFIGURATION);
}
diff --git a/core-framework/include/http/BaseHTTPClient.h b/core-framework/include/http/BaseHTTPClient.h
index a3389571a..ad22ce950 100644
--- a/core-framework/include/http/BaseHTTPClient.h
+++ b/core-framework/include/http/BaseHTTPClient.h
@@ -29,6 +29,31 @@
#include "utils/ByteArrayCallback.h"
#include "utils/gsl.h"
+namespace org::apache::nifi::minifi::http {
+enum class HttpRequestMethod {
+ Get, Post, Put, Patch, Delete, Connect, Head, Options, Trace
+};
+} // namespace org::apache::nifi::minifi::http
+
+namespace magic_enum::customize {
+using HttpRequestMethod = org::apache::nifi::minifi::http::HttpRequestMethod;
+template<>
+constexpr customize_t enum_name<HttpRequestMethod>(HttpRequestMethod type) noexcept {
+ switch (type) {
+ case HttpRequestMethod::Get: return "GET";
+ case HttpRequestMethod::Post: return "POST";
+ case HttpRequestMethod::Put: return "PUT";
+ case HttpRequestMethod::Patch: return "PATCH";
+ case HttpRequestMethod::Delete: return "DELETE";
+ case HttpRequestMethod::Connect: return "CONNECT";
+ case HttpRequestMethod::Head: return "HEAD";
+ case HttpRequestMethod::Options: return "OPTIONS";
+ case HttpRequestMethod::Trace: return "TRACE";
+ }
+ return invalid_tag;
+}
+} // namespace magic_enum::customize
+
namespace org::apache::nifi::minifi::http {
struct HTTPProxy {
@@ -177,12 +202,6 @@ namespace HTTPRequestResponse {
int seek_callback(void *p, int64_t offset, int);
}
-#undef DELETE // this is a macro in winnt.h
-
-enum class HttpRequestMethod {
- GET, POST, PUT, PATCH, DELETE, CONNECT, HEAD, OPTIONS, TRACE
-};
-
class BaseHTTPClient {
public:
BaseHTTPClient() = default;
diff --git a/core-framework/src/http/BaseHTTPClient.cpp b/core-framework/src/http/BaseHTTPClient.cpp
index 10b55fb50..b0ce9d382 100644
--- a/core-framework/src/http/BaseHTTPClient.cpp
+++ b/core-framework/src/http/BaseHTTPClient.cpp
@@ -66,7 +66,7 @@ std::string get_token(BaseHTTPClient* client, const std::string& username, const
client->setContentType("application/x-www-form-urlencoded");
- client->set_request_method(HttpRequestMethod::POST);
+ client->set_request_method(HttpRequestMethod::Post);
std::string payload = "username=" + username + "&" + "password=" + password;
@@ -110,7 +110,7 @@ URL::URL(const std::string& url_input) {
std::string::const_iterator end_of_port = std::find_first_of(current_pos, url_input.end(), std::begin(PORT_TERMINATORS), std::end(PORT_TERMINATORS));
const auto port_number = parsePortNumber(std::string{current_pos, end_of_port});
if (port_number) {
- port_ = *port_number;
+ port_ = port_number;
} else {
logger_->log_error("Could not parse the port number in URL '{}'", url_input);
return;
@@ -226,8 +226,7 @@ size_t HTTPUploadByteArrayInputCallback::getDataChunk(char *data, size_t size) {
if (ptr == nullptr) {
return 0;
}
- if (len > size)
- len = size;
+ len = std::min(len, size);
memcpy(data, ptr, len);
pos += len;
seek(pos);
diff --git a/core-framework/src/http/HTTPClient.cpp b/core-framework/src/http/HTTPClient.cpp
index a689d8e3d..cc879f58a 100644
--- a/core-framework/src/http/HTTPClient.cpp
+++ b/core-framework/src/http/HTTPClient.cpp
@@ -255,7 +255,7 @@ void HTTPClient::setReadCallback(std::unique_ptr<HTTPReadCallback> callback) {
void HTTPClient::setUploadCallback(std::unique_ptr<HTTPUploadCallback> callback) {
logger_->log_debug("Setting callback for {}", url_);
write_callback_ = std::move(callback);
- if (method_ == http::HttpRequestMethod::PUT) {
+ if (method_ == http::HttpRequestMethod::Put) {
curl_easy_setopt(http_session_.get(), CURLOPT_INFILESIZE_LARGE, (curl_off_t) write_callback_->size());
}
curl_easy_setopt(http_session_.get(), CURLOPT_READFUNCTION, &HTTPRequestResponse::send_write);
@@ -412,19 +412,19 @@ void HTTPClient::set_request_method(http::HttpRequestMethod method) {
return;
method_ = method;
switch (*method_) {
- case http::HttpRequestMethod::POST:
+ case http::HttpRequestMethod::Post:
curl_easy_setopt(http_session_.get(), CURLOPT_POST, 1L);
curl_easy_setopt(http_session_.get(), CURLOPT_CUSTOMREQUEST, nullptr);
break;
- case http::HttpRequestMethod::HEAD:
+ case http::HttpRequestMethod::Head:
curl_easy_setopt(http_session_.get(), CURLOPT_NOBODY, 1L);
curl_easy_setopt(http_session_.get(), CURLOPT_CUSTOMREQUEST, nullptr);
break;
- case http::HttpRequestMethod::GET:
+ case http::HttpRequestMethod::Get:
curl_easy_setopt(http_session_.get(), CURLOPT_HTTPGET, 1L);
curl_easy_setopt(http_session_.get(), CURLOPT_CUSTOMREQUEST, nullptr);
break;
- case http::HttpRequestMethod::PUT:
+ case http::HttpRequestMethod::Put:
curl_easy_setopt(http_session_.get(), CURLOPT_UPLOAD, 1L);
curl_easy_setopt(http_session_.get(), CURLOPT_CUSTOMREQUEST, nullptr);
break;
diff --git a/docker/test/integration/cluster/containers/MinifiContainer.py b/docker/test/integration/cluster/containers/MinifiContainer.py
index dbbdc2143..387a3bd0d 100644
--- a/docker/test/integration/cluster/containers/MinifiContainer.py
+++ b/docker/test/integration/cluster/containers/MinifiContainer.py
@@ -149,7 +149,6 @@ class MinifiContainer(FlowContainer):
f.write("nifi.c2.enable=true\n")
f.write(f"nifi.c2.rest.url=https://minifi-c2-server-{self.feature_context.id}:10090/c2/config/heartbeat\n")
f.write(f"nifi.c2.rest.url.ack=https://minifi-c2-server-{self.feature_context.id}:10090/c2/config/acknowledge\n")
- f.write("nifi.c2.rest.ssl.context.service=SSLContextService\n")
f.write(f"nifi.c2.flow.base.url=https://minifi-c2-server-{self.feature_context.id}:10090/c2/config/\n")
f.write("nifi.c2.root.classes=DeviceInfoNode,AgentInformation,FlowInformation,AssetInformation\n")
f.write("nifi.c2.full.heartbeat=false\n")
diff --git a/docker/test/integration/features/minifi_c2_server.feature b/docker/test/integration/features/minifi_c2_server.feature
index ff6640deb..2bbffc9f4 100644
--- a/docker/test/integration/features/minifi_c2_server.feature
+++ b/docker/test/integration/features/minifi_c2_server.feature
@@ -29,14 +29,6 @@ Feature: MiNiFi can communicate with Apache NiFi MiNiFi C2 server
And a flowfile with the content "test" is placed in the monitored directory in less than 10 seconds
And the Minifi logs do not contain the following message: "Failed to parse json response: The document is empty. at 0" after 0 seconds
- Scenario: MiNiFi flow config is updated from MiNiFi C2 server through SSL with SSL controller service
- Given a file with the content "test" is present in "/tmp/input"
- And a ssl context service is set up for MiNiFi C2 server
- And a MiNiFi C2 server is set up with SSL
- When all instances start up
- Then the MiNiFi C2 SSL server logs contain the following message: "acknowledged with a state of FULLY_APPLIED(DONE)" in less than 60 seconds
- And a flowfile with the content "test" is placed in the monitored directory in less than 10 seconds
-
Scenario: MiNiFi can get flow config from C2 server through flow url when it is not available at start
Given flow configuration path is set up in flow url property
And C2 is enabled in MiNiFi
diff --git a/docker/test/integration/features/steps/steps.py b/docker/test/integration/features/steps/steps.py
index a0b1b532f..129d8df57 100644
--- a/docker/test/integration/features/steps/steps.py
+++ b/docker/test/integration/features/steps/steps.py
@@ -1009,18 +1009,6 @@ def step_impl(context, doc_id, index, value, field):
# MiNiFi C2 Server
-@given("a ssl context service is set up for MiNiFi C2 server")
-def step_impl(context):
- minifi_crt_file = '/tmp/resources/minifi_client.crt'
- minifi_key_file = '/tmp/resources/minifi_client.key'
- root_ca_crt_file = '/tmp/resources/root_ca.crt'
- ssl_context_service = SSLContextService(cert=minifi_crt_file, ca_cert=root_ca_crt_file, key=minifi_key_file)
- ssl_context_service.name = "SSLContextService"
- container = context.test.acquire_container(context=context, name="minifi-cpp-flow")
- container.add_controller(ssl_context_service)
- context.test.enable_c2_with_ssl_in_minifi()
-
-
@given("ssl properties are set up for MiNiFi C2 server")
def step_impl(context):
context.test.enable_c2_with_ssl_in_minifi()
diff --git a/encrypt-config/tests/ConfigFileEncryptorTests.cpp b/encrypt-config/tests/ConfigFileEncryptorTests.cpp
index f0bd32e0b..4cdebb0bb 100644
--- a/encrypt-config/tests/ConfigFileEncryptorTests.cpp
+++ b/encrypt-config/tests/ConfigFileEncryptorTests.cpp
@@ -77,7 +77,7 @@ TEST_CASE("ConfigFileEncryptor can encrypt the sensitive properties", "[encrypt-
uint32_t initial_num_properties_encrypted = encryptSensitivePropertiesInFile(test_file, KEY);
REQUIRE(initial_num_properties_encrypted == 1);
- REQUIRE(test_file.size() == 110);
+ REQUIRE(test_file.size() == 109);
REQUIRE(check_encryption(test_file, Configuration::nifi_rest_api_password, original_password.length()));
SECTION("calling encryptSensitiveValuesInMinifiProperties a second time does nothing") {
diff --git a/encrypt-config/tests/ConfigFileTests.cpp b/encrypt-config/tests/ConfigFileTests.cpp
index 4f1c5f1f2..9df4b5762 100644
--- a/encrypt-config/tests/ConfigFileTests.cpp
+++ b/encrypt-config/tests/ConfigFileTests.cpp
@@ -90,7 +90,7 @@ TEST_CASE("ConfigFile creates an empty object from a nonexistent file", "[encryp
TEST_CASE("ConfigFile can parse a simple config file", "[encrypt-config][constructor]") {
ConfigFile test_file{std::ifstream{"resources/minifi.properties"}};
- REQUIRE(test_file.size() == 109);
+ REQUIRE(test_file.size() == 108);
}
TEST_CASE("ConfigFile can test whether a key is present", "[encrypt-config][hasValue]") {
@@ -102,7 +102,7 @@ TEST_CASE("ConfigFile can test whether a key is present", "[encrypt-config][hasV
TEST_CASE("ConfigFile can read empty properties correctly", "[encrypt-config][constructor]") {
ConfigFile test_file{std::ifstream{"resources/with-additional-sensitive-props.minifi.properties"}};
- REQUIRE(test_file.size() == 105);
+ REQUIRE(test_file.size() == 104);
auto empty_property = test_file.getValue(Configuration::nifi_security_need_ClientAuth);
REQUIRE(empty_property);
@@ -143,7 +143,7 @@ TEST_CASE("ConfigFile can add a new setting after an existing setting", "[encryp
SECTION("valid key") {
test_file.insertAfter(Configuration::nifi_rest_api_password, "nifi.rest.api.password.protected", "my-cipher-name");
- REQUIRE(test_file.size() == 110);
+ REQUIRE(test_file.size() == 109);
REQUIRE(test_file.getValue("nifi.rest.api.password.protected") == "my-cipher-name");
}
@@ -158,7 +158,7 @@ TEST_CASE("ConfigFile can add a new setting at the end", "[encrypt-config][appen
const std::string KEY = "nifi.bootstrap.sensitive.key";
const std::string VALUE = "aa411f289c91685ef9d5a9e5a4fad9393ff4c7a78ab978484323488caed7a9ab";
test_file.append(KEY, VALUE);
- REQUIRE(test_file.size() == 110);
+ REQUIRE(test_file.size() == 109);
REQUIRE(test_file.getValue(KEY) == std::make_optional(VALUE));
}
diff --git a/encrypt-config/tests/resources/minifi.properties b/encrypt-config/tests/resources/minifi.properties
index 898f23435..107aee455 100644
--- a/encrypt-config/tests/resources/minifi.properties
+++ b/encrypt-config/tests/resources/minifi.properties
@@ -81,7 +81,6 @@ nifi.c2.agent.identifier=EncryptConfigTester-001
#controller.socket.host=localhost
#controller.socket.port=9998
#controller.socket.local.any.interface=false
-#controller.ssl.context.service=SSLContextService
## specify the destination of c2 directed assets
#nifi.asset.directory=${MINIFI_HOME}/asset
diff --git a/encrypt-config/tests/resources/with-additional-sensitive-props.minifi.properties b/encrypt-config/tests/resources/with-additional-sensitive-props.minifi.properties
index 8f468b2c8..c270aef68 100644
--- a/encrypt-config/tests/resources/with-additional-sensitive-props.minifi.properties
+++ b/encrypt-config/tests/resources/with-additional-sensitive-props.minifi.properties
@@ -83,7 +83,6 @@ nifi.c2.agent.identifier=EncryptConfigTester-001
#controller.socket.host=localhost
#controller.socket.port=9998
#controller.socket.local.any.interface=false
-#controller.ssl.context.service=SSLContextService
# must be comma separated
nifi.c2.flow.id=
diff --git a/extensions/aws/tests/MultipartUploadStateStorageTest.cpp b/extensions/aws/tests/MultipartUploadStateStorageTest.cpp
index 348e42a59..9e15f63e3 100644
--- a/extensions/aws/tests/MultipartUploadStateStorageTest.cpp
+++ b/extensions/aws/tests/MultipartUploadStateStorageTest.cpp
@@ -32,7 +32,7 @@ class MultipartUploadStateStorageTestFixture {
MultipartUploadStateStorageTestFixture() {
LogTestController::getInstance().setDebug<minifi::aws::s3::MultipartUploadStateStorage>();
state_storage_ = std::make_unique<minifi::controllers::VolatileMapStateStorage>("KeyValueStateStorage");
- state_manager_ = std::make_unique<minifi::controllers::KeyValueStateManager>(utils::IdGenerator::getIdGenerator()->generate(), gsl::make_not_null(state_storage_.get()));
+ state_manager_ = std::make_unique<minifi::controllers::KeyValueStateManager>(minifi::utils::IdGenerator::getIdGenerator()->generate(), gsl::make_not_null(state_storage_.get()));
upload_storage_ = std::make_unique<minifi::aws::s3::MultipartUploadStateStorage>(gsl::make_not_null(state_manager_.get()));
}
diff --git a/extensions/civetweb/tests/ListenHTTPTests.cpp b/extensions/civetweb/tests/ListenHTTPTests.cpp
index 0e0b439d2..0f4f80ec8 100644
--- a/extensions/civetweb/tests/ListenHTTPTests.cpp
+++ b/extensions/civetweb/tests/ListenHTTPTests.cpp
@@ -165,7 +165,7 @@ class ListenHTTPTestsFixture {
}
void check_response_body(minifi::http::HTTPClient& client) {
- if (client.getMethod() != HttpRequestMethod::GET && client.getMethod() != HttpRequestMethod::POST) {
+ if (client.getMethod() != HttpRequestMethod::Get && client.getMethod() != HttpRequestMethod::Post) {
return;
}
@@ -230,7 +230,7 @@ class ListenHTTPTestsFixture {
thread.join();
}
- if (expected_committed_requests > 0 && (method == HttpRequestMethod::GET || method == HttpRequestMethod::POST)) {
+ if (expected_committed_requests > 0 && (method == HttpRequestMethod::Get || method == HttpRequestMethod::Post)) {
REQUIRE(LogTestController::getInstance().contains("Size:" + std::to_string(payload.size()) + " Offset:0"));
}
REQUIRE(LogTestController::getInstance().contains("Logged " + std::to_string(expected_committed_requests) + " flow files"));
@@ -243,7 +243,7 @@ class ListenHTTPTestsFixture {
for (const auto &header : headers) {
client->setRequestHeader(header.first, header.second);
}
- if (method == HttpRequestMethod::POST) {
+ if (method == HttpRequestMethod::Post) {
client->setPostFields(payload);
}
return client;
@@ -259,7 +259,7 @@ class ListenHTTPTestsFixture {
core::Processor* log_attribute = nullptr;
std::shared_ptr<minifi::controllers::SSLContextServiceInterface> ssl_context_service;
- HttpRequestMethod method = HttpRequestMethod::GET;
+ HttpRequestMethod method = HttpRequestMethod::Get;
std::map<std::string, std::string> headers;
std::string payload;
std::string endpoint = "test";
@@ -283,7 +283,7 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP GET", "[basic]") {
TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP POST", "[basic]") {
run_server();
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
test_connect();
@@ -292,7 +292,7 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP POST", "[basic]") {
TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP PUT", "[basic]") {
run_server();
- method = HttpRequestMethod::PUT;
+ method = HttpRequestMethod::Put;
test_connect({HttpResponseExpectations{true, 405}}, 0);
}
@@ -300,7 +300,7 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP PUT", "[basic]") {
TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP DELETE", "[basic]") {
run_server();
- method = HttpRequestMethod::DELETE;
+ method = HttpRequestMethod::Delete;
test_connect({HttpResponseExpectations{true, 405}}, 0);
}
@@ -308,7 +308,7 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP DELETE", "[basic]") {
TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP HEAD", "[basic]") {
run_server();
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
test_connect({HttpResponseExpectations{}}, 0);
}
@@ -318,18 +318,18 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP no body", "[basic]") {
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
run_server();
- const std::size_t expected_committed_requests = (method == HttpRequestMethod::POST || method == HttpRequestMethod::GET) ? 1 : 0;
+ const std::size_t expected_committed_requests = (method == HttpRequestMethod::Post || method == HttpRequestMethod::Get) ? 1 : 0;
test_connect({HttpResponseExpectations{}}, expected_committed_requests);
}
@@ -337,18 +337,18 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP body with different mime type", "
plan->setDynamicProperty(update_attribute, "mime.type", "text/plain");
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
run_server();
- const std::size_t expected_committed_requests = (method == HttpRequestMethod::POST || method == HttpRequestMethod::GET) ? 1 : 0;
+ const std::size_t expected_committed_requests = (method == HttpRequestMethod::Post || method == HttpRequestMethod::Get) ? 1 : 0;
test_connect({HttpResponseExpectations{}}, expected_committed_requests);
}
@@ -359,10 +359,10 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP all headers", "[basic][headers]")
{"bar", "2"}};
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
@@ -380,10 +380,10 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP filtered headers", "[headers]") {
{"bar", "2"}};
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
@@ -412,10 +412,10 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP Batch tests", "[batch]") {
expected_processed_request_count = 5;
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
}
@@ -426,10 +426,10 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP Batch tests", "[batch]") {
expected_processed_request_count = 4;
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
}
@@ -441,10 +441,10 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTP Batch tests", "[batch]") {
expected_processed_request_count = 3;
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
}
@@ -459,18 +459,18 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS without CA", "[basic][https]") {
create_ssl_context_service("goodCA.crt", nullptr);
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
run_server();
- const std::size_t expected_committed_requests = (method == HttpRequestMethod::POST || method == HttpRequestMethod::GET) ? 1 : 0;
+ const std::size_t expected_committed_requests = (method == HttpRequestMethod::Post || method == HttpRequestMethod::Get) ? 1 : 0;
test_connect({HttpResponseExpectations{}}, expected_committed_requests);
}
@@ -482,18 +482,18 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS without client cert", "[basic][h
create_ssl_context_service("goodCA.crt", nullptr);
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
run_server();
- const std::size_t expected_committed_requests = (method == HttpRequestMethod::POST || method == HttpRequestMethod::GET) ? 1 : 0;
+ const std::size_t expected_committed_requests = (method == HttpRequestMethod::Post || method == HttpRequestMethod::Get) ? 1 : 0;
test_connect({HttpResponseExpectations{}}, expected_committed_requests);
}
@@ -506,18 +506,18 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS with client cert from good CA",
create_ssl_context_service("goodCA.crt", "goodCA_goodClient.pem");
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
run_server();
- const std::size_t expected_committed_requests = (method == HttpRequestMethod::POST || method == HttpRequestMethod::GET) ? 1 : 0;
+ const std::size_t expected_committed_requests = (method == HttpRequestMethod::Post || method == HttpRequestMethod::Get) ? 1 : 0;
test_connect({HttpResponseExpectations{}}, expected_committed_requests);
}
@@ -530,18 +530,18 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS with PKCS12 client cert from goo
create_ssl_context_service("goodCA.crt", "goodCA_goodClient.p12");
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
run_server();
- const std::size_t expected_committed_requests = (method == HttpRequestMethod::POST || method == HttpRequestMethod::GET) ? 1 : 0;
+ const std::size_t expected_committed_requests = (method == HttpRequestMethod::Post || method == HttpRequestMethod::Get) ? 1 : 0;
test_connect({HttpResponseExpectations{}}, expected_committed_requests);
}
@@ -558,14 +558,14 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS with client cert from bad CA", "
plan->setProperty(listen_http, minifi::processors::ListenHTTP::SSLVerifyPeer, "yes");
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
}
SECTION("do not verify peer") {
@@ -573,16 +573,16 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS with client cert from bad CA", "
response_code = 200;
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
expected_committed_requests = 1;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
expected_committed_requests = 1;
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
}
@@ -602,18 +602,18 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS with client cert with matching D
create_ssl_context_service("goodCA.crt", "goodCA_goodClient.pem");
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
run_server();
- const std::size_t expected_committed_requests = (method == HttpRequestMethod::POST || method == HttpRequestMethod::GET) ? 1 : 0;
+ const std::size_t expected_committed_requests = (method == HttpRequestMethod::Post || method == HttpRequestMethod::Get) ? 1 : 0;
test_connect({HttpResponseExpectations{}}, expected_committed_requests);
}
@@ -630,30 +630,30 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS with client cert with non-matchi
response_code = 403;
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
}
SECTION("do not verify peer") {
response_code = 200;
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
expected_committed_requests = 1;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
expected_committed_requests = 1;
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
}
@@ -669,14 +669,14 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS minimum SSL version", "[https]")
plan->setProperty(listen_http, minifi::processors::ListenHTTP::SSLCertificateAuthority, (executable_dir / "resources" / "goodCA.crt").string());
SECTION("GET") {
- method = HttpRequestMethod::GET;
+ method = HttpRequestMethod::Get;
}
SECTION("POST") {
- method = HttpRequestMethod::POST;
+ method = HttpRequestMethod::Post;
payload = "Test payload";
}
SECTION("HEAD") {
- method = HttpRequestMethod::HEAD;
+ method = HttpRequestMethod::Head;
}
create_ssl_context_service("goodCA.crt", "goodCA_goodClient.pem");
@@ -686,7 +686,7 @@ TEST_CASE_METHOD(ListenHTTPTestsFixture, "HTTPS minimum SSL version", "[https]")
auto client = std::make_unique<minifi::http::HTTPClient>();
client->setVerbose(false);
client->initialize(method, url, ssl_context_service);
- if (method == HttpRequestMethod::POST) {
+ if (method == HttpRequestMethod::Post) {
client->setPostFields(payload);
}
REQUIRE(client->setSpecificSSLVersion(minifi::http::SSLVersion::TLSv1_1));
diff --git a/extensions/elasticsearch/PostElasticsearch.cpp b/extensions/elasticsearch/PostElasticsearch.cpp
index ca6e1c747..8424ba35a 100644
--- a/extensions/elasticsearch/PostElasticsearch.cpp
+++ b/extensions/elasticsearch/PostElasticsearch.cpp
@@ -56,7 +56,7 @@ void PostElasticsearch::onSchedule(core::ProcessContext& context, core::ProcessS
throw Exception(PROCESS_SCHEDULE_EXCEPTION, "Missing Elasticsearch credentials service");
auto ssl_context_service = utils::parseOptionalControllerService<minifi::controllers::SSLContextServiceInterface>(context, PostElasticsearch::SSLContext, getUUID());
- client_.initialize(http::HttpRequestMethod::POST, host_url_ + "/_bulk", ssl_context_service);
+ client_.initialize(http::HttpRequestMethod::Post, host_url_ + "/_bulk", ssl_context_service);
client_.setContentType("application/json");
credentials_service_->authenticateClient(client_);
}
diff --git a/extensions/grafana-loki/PushGrafanaLokiREST.cpp b/extensions/grafana-loki/PushGrafanaLokiREST.cpp
index 1feb11d9c..8b421dbb7 100644
--- a/extensions/grafana-loki/PushGrafanaLokiREST.cpp
+++ b/extensions/grafana-loki/PushGrafanaLokiREST.cpp
@@ -83,7 +83,7 @@ void PushGrafanaLokiREST::initializeHttpClient(core::ProcessContext& context) {
}
logger_->log_debug("PushGrafanaLokiREST push url is set to: {}", url);
auto ssl_context_service = utils::parseOptionalControllerService<minifi::controllers::SSLContextServiceInterface>(context, PushGrafanaLoki::SSLContextService, getUUID());
- client_.initialize(http::HttpRequestMethod::POST, url, ssl_context_service);
+ client_.initialize(http::HttpRequestMethod::Post, url, ssl_context_service);
}
void PushGrafanaLokiREST::onSchedule(core::ProcessContext& context, core::ProcessSessionFactory& session_factory) {
diff --git a/extensions/smb/tests/SmbConnectionControllerServiceTests.cpp b/extensions/smb/tests/SmbConnectionControllerServiceTests.cpp
index 217122fa3..557810e6c 100644
--- a/extensions/smb/tests/SmbConnectionControllerServiceTests.cpp
+++ b/extensions/smb/tests/SmbConnectionControllerServiceTests.cpp
@@ -15,7 +15,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-
#include "unit/TestBase.h"
#include "unit/Catch.h"
#include "SmbConnectionControllerService.h"
diff --git a/extensions/splunk/SplunkHECProcessor.cpp b/extensions/splunk/SplunkHECProcessor.cpp
index eae24f31b..4427668aa 100644
--- a/extensions/splunk/SplunkHECProcessor.cpp
+++ b/extensions/splunk/SplunkHECProcessor.cpp
@@ -41,7 +41,7 @@ std::string SplunkHECProcessor::getNetworkLocation() const {
}
void SplunkHECProcessor::initializeClient(http::HTTPClient& client, const std::string &url, std::shared_ptr<minifi::controllers::SSLContextServiceInterface> ssl_context_service) const {
- client.initialize(http::HttpRequestMethod::POST, url, std::move(ssl_context_service));
+ client.initialize(http::HttpRequestMethod::Post, url, std::move(ssl_context_service));
client.setRequestHeader("Authorization", token_);
client.setRequestHeader("X-Splunk-Request-Channel", request_channel_);
}
diff --git a/extensions/standard-processors/processors/InvokeHTTP.cpp b/extensions/standard-processors/processors/InvokeHTTP.cpp
index 7ca018fd4..1e037730d 100644
--- a/extensions/standard-processors/processors/InvokeHTTP.cpp
+++ b/extensions/standard-processors/processors/InvokeHTTP.cpp
@@ -200,7 +200,7 @@ void InvokeHTTP::onSchedule(core::ProcessContext& context, core::ProcessSessionF
}
bool InvokeHTTP::shouldEmitFlowFile() const {
- return (http::HttpRequestMethod::POST == method_ || http::HttpRequestMethod::PUT == method_ || http::HttpRequestMethod::PATCH == method_);
+ return (http::HttpRequestMethod::Post == method_ || http::HttpRequestMethod::Put == method_ || http::HttpRequestMethod::Patch == method_);
}
/**
diff --git a/extensions/standard-processors/processors/InvokeHTTP.h b/extensions/standard-processors/processors/InvokeHTTP.h
index 744f9781f..cec9a2fd3 100644
--- a/extensions/standard-processors/processors/InvokeHTTP.h
+++ b/extensions/standard-processors/processors/InvokeHTTP.h
@@ -139,7 +139,7 @@ class InvokeHTTP : public core::ProcessorImpl {
EXTENSIONAPI static constexpr auto Method = core::PropertyDefinitionBuilder<magic_enum::enum_count<http::HttpRequestMethod>()>::createProperty("HTTP Method")
.withDescription("HTTP request method. Methods other than POST, PUT and PATCH will be sent without a message body.")
.withAllowedValues(magic_enum::enum_names<http::HttpRequestMethod>())
- .withDefaultValue(magic_enum::enum_name(http::HttpRequestMethod::GET))
+ .withDefaultValue(magic_enum::enum_name(http::HttpRequestMethod::Get))
.build();
EXTENSIONAPI static constexpr auto URL = core::PropertyDefinitionBuilder<>::createProperty("Remote URL")
.withDescription("Remote URL which will be connected to, including scheme, host, port, path.")
diff --git a/extensions/standard-processors/tests/unit/HttpClientStoreTests.cpp b/extensions/standard-processors/tests/unit/HttpClientStoreTests.cpp
index c3bc7f985..7ecb0433c 100644
--- a/extensions/standard-processors/tests/unit/HttpClientStoreTests.cpp
+++ b/extensions/standard-processors/tests/unit/HttpClientStoreTests.cpp
@@ -44,7 +44,7 @@ class HttpClientStoreTestAccessor {
TEST_CASE("HttpClientStore can create new client for a url and is returned after it's not used anymore") {
minifi::processors::invoke_http::HttpClientStore store(2, [](const std::string& url) {
auto client = std::make_unique<minifi::http::HTTPClient>();
- client->initialize(minifi::http::HttpRequestMethod::GET, url, nullptr);
+ client->initialize(minifi::http::HttpRequestMethod::Get, url, nullptr);
return gsl::make_not_null(std::move(client));
});
REQUIRE(HttpClientStoreTestAccessor::getMaxSize(store) == 2);
@@ -65,7 +65,7 @@ TEST_CASE("HttpClientStore can create new client for a url and is returned after
TEST_CASE("A http client can be reused") {
minifi::processors::invoke_http::HttpClientStore store(2, [](const std::string& url) {
auto client = std::make_unique<minifi::http::HTTPClient>();
- client->initialize(minifi::http::HttpRequestMethod::GET, url, nullptr);
+ client->initialize(minifi::http::HttpRequestMethod::Get, url, nullptr);
return gsl::make_not_null(std::move(client));
});
minifi::http::HTTPClient* client_ptr = nullptr;
@@ -89,7 +89,7 @@ TEST_CASE("A http client can be reused") {
TEST_CASE("A new url always creates a new client") {
minifi::processors::invoke_http::HttpClientStore store(3, [](const std::string& url) {
auto client = std::make_unique<minifi::http::HTTPClient>();
- client->initialize(minifi::http::HttpRequestMethod::GET, url, nullptr);
+ client->initialize(minifi::http::HttpRequestMethod::Get, url, nullptr);
return gsl::make_not_null(std::move(client));
});
const auto& used_clients = HttpClientStoreTestAccessor::getUsedClients(store);
@@ -114,7 +114,7 @@ TEST_CASE("A new url always creates a new client") {
TEST_CASE("If a store is full, the first unused client is replaced by the newly requested one") {
minifi::processors::invoke_http::HttpClientStore store(3, [](const std::string& url) {
auto client = std::make_unique<minifi::http::HTTPClient>();
- client->initialize(minifi::http::HttpRequestMethod::GET, url, nullptr);
+ client->initialize(minifi::http::HttpRequestMethod::Get, url, nullptr);
return gsl::make_not_null(std::move(client));
});
const auto& used_clients = HttpClientStoreTestAccessor::getUsedClients(store);
@@ -148,7 +148,7 @@ TEST_CASE("If a store is full, the first unused client is replaced by the newly
TEST_CASE("Multiple unused clients are present the oldest one is replaced") {
minifi::processors::invoke_http::HttpClientStore store(4, [](const std::string& url) {
auto client = std::make_unique<minifi::http::HTTPClient>();
- client->initialize(minifi::http::HttpRequestMethod::GET, url, nullptr);
+ client->initialize(minifi::http::HttpRequestMethod::Get, url, nullptr);
return gsl::make_not_null(std::move(client));
});
const auto& used_clients = HttpClientStoreTestAccessor::getUsedClients(store);
@@ -185,7 +185,7 @@ TEST_CASE("Multiple unused clients are present the oldest one is replaced") {
TEST_CASE("If all clients are in use, the call will block until a client is returned") {
minifi::processors::invoke_http::HttpClientStore store(2, [](const std::string& url) {
auto client = std::make_unique<minifi::http::HTTPClient>();
- client->initialize(minifi::http::HttpRequestMethod::GET, url, nullptr);
+ client->initialize(minifi::http::HttpRequestMethod::Get, url, nullptr);
return gsl::make_not_null(std::move(client));
});
bool client2_created{false};
diff --git a/libminifi/include/c2/ControllerSocketProtocol.h b/libminifi/include/c2/ControllerSocketProtocol.h
index a1644d380..abb15cb31 100644
--- a/libminifi/include/c2/ControllerSocketProtocol.h
+++ b/libminifi/include/c2/ControllerSocketProtocol.h
@@ -42,8 +42,7 @@ namespace org::apache::nifi::minifi::c2 {
*/
class ControllerSocketProtocol {
public:
- ControllerSocketProtocol(core::controller::ControllerServiceProvider& controller, state::StateMonitor& update_sink,
- std::shared_ptr<Configure> configuration, const std::shared_ptr<ControllerSocketReporter>& controller_socket_reporter);
+ ControllerSocketProtocol(state::StateMonitor& update_sink, std::shared_ptr<Configure> configuration, const std::shared_ptr<ControllerSocketReporter>& controller_socket_reporter);
~ControllerSocketProtocol();
void initialize();
void setRoot(core::ProcessGroup* root);
@@ -70,7 +69,6 @@ class ControllerSocketProtocol {
asio::awaitable<void> startAcceptSsl(std::shared_ptr<minifi::controllers::SSLContextServiceInterface> ssl_context_service);
void stopListener();
- core::controller::ControllerServiceProvider& controller_;
state::StateMonitor& update_sink_;
asio::io_context io_context_;
diff --git a/libminifi/include/core/logging/LoggerConfiguration.h b/libminifi/include/core/logging/LoggerConfiguration.h
index ffe5b64ea..4b4d6eb63 100644
--- a/libminifi/include/core/logging/LoggerConfiguration.h
+++ b/libminifi/include/core/logging/LoggerConfiguration.h
@@ -100,7 +100,7 @@ class LoggerConfiguration {
return getCompressedLogs(std::chrono::milliseconds{0});
}
- void initializeAlertSinks(core::controller::ControllerServiceProvider* controller, const std::shared_ptr<AgentIdentificationProvider>& agent_id);
+ void initializeAlertSinks(const std::shared_ptr<Configure>& config);
template<class Rep, class Period>
static std::vector<std::unique_ptr<io::InputStream>> getCompressedLogs(const std::chrono::duration<Rep, Period>& time) {
diff --git a/libminifi/include/core/logging/alert/AlertSink.h b/libminifi/include/core/logging/alert/AlertSink.h
index 909574089..9487a61e3 100644
--- a/libminifi/include/core/logging/alert/AlertSink.h
+++ b/libminifi/include/core/logging/alert/AlertSink.h
@@ -25,13 +25,13 @@
#include <string>
#include <memory>
-#include "core/controller/ControllerServiceProvider.h"
#include "core/logging/LoggerProperties.h"
#include "utils/ThreadPool.h"
#include "utils/StagingQueue.h"
#include "utils/RegexUtils.h"
#include "properties/Configure.h"
#include "spdlog/sinks/base_sink.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
namespace org::apache::nifi::minifi::controllers {
class SSLContextServiceInterface;
@@ -48,14 +48,13 @@ class AlertSink : public spdlog::sinks::base_sink<std::mutex> {
static std::shared_ptr<AlertSink> create(const std::string& prop_name_prefix, const std::shared_ptr<LoggerProperties>& logger_properties, std::shared_ptr<Logger> logger);
- void initialize(core::controller::ControllerServiceProvider* controller, std::shared_ptr<AgentIdentificationProvider> agent_id);
+ void initialize(std::shared_ptr<AgentIdentificationProvider> agent_id, std::shared_ptr<controllers::SSLContextServiceInterface> ssl_service);
~AlertSink() override;
private:
struct Config {
std::string url;
- std::optional<std::string> ssl_service_name;
int batch_size;
std::chrono::milliseconds flush_period;
std::chrono::milliseconds rate_limit;
diff --git a/libminifi/src/Configuration.cpp b/libminifi/src/Configuration.cpp
index d16401719..b8881c0b0 100644
--- a/libminifi/src/Configuration.cpp
+++ b/libminifi/src/Configuration.cpp
@@ -96,7 +96,6 @@ const std::unordered_map<std::string_view, gsl::not_null<const core::PropertyVal
{Configuration::nifi_c2_rest_path_base, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_c2_rest_url, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_c2_rest_url_ack, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
- {Configuration::nifi_c2_rest_ssl_context_service, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_c2_rest_request_encoding, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_c2_rest_heartbeat_minimize_updates, gsl::make_not_null(&core::StandardPropertyValidators::BOOLEAN_VALIDATOR)},
{Configuration::nifi_c2_flow_info_processor_bulletin_limit, gsl::make_not_null(&core::StandardPropertyValidators::UNSIGNED_INTEGER_VALIDATOR)},
@@ -130,7 +129,6 @@ const std::unordered_map<std::string_view, gsl::not_null<const core::PropertyVal
{Configuration::nifi_log_compression_compressed_log_max_size, gsl::make_not_null(&core::StandardPropertyValidators::DATA_SIZE_VALIDATOR)},
{Configuration::nifi_log_max_log_entry_length, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_log_alert_url, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
- {Configuration::nifi_log_alert_ssl_context_service, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_log_alert_batch_size, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_log_alert_flush_period, gsl::make_not_null(&core::StandardPropertyValidators::TIME_PERIOD_VALIDATOR)},
{Configuration::nifi_log_alert_filter, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
@@ -152,7 +150,6 @@ const std::unordered_map<std::string_view, gsl::not_null<const core::PropertyVal
{Configuration::controller_socket_local_any_interface, gsl::make_not_null(&core::StandardPropertyValidators::BOOLEAN_VALIDATOR)},
{Configuration::controller_socket_host, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::controller_socket_port, gsl::make_not_null(&core::StandardPropertyValidators::PORT_VALIDATOR)},
- {Configuration::controller_ssl_context_service, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_flow_file_repository_check_health, gsl::make_not_null(&core::StandardPropertyValidators::BOOLEAN_VALIDATOR)},
{Configuration::nifi_python_virtualenv_directory, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
{Configuration::nifi_python_env_setup_binary, gsl::make_not_null(&core::StandardPropertyValidators::ALWAYS_VALID_VALIDATOR)},
diff --git a/libminifi/src/FlowController.cpp b/libminifi/src/FlowController.cpp
index 7bb67caf1..ac875ff19 100644
--- a/libminifi/src/FlowController.cpp
+++ b/libminifi/src/FlowController.cpp
@@ -92,7 +92,7 @@ FlowController::FlowController(std::shared_ptr<core::Repository> provenance_repo
controller_socket_metrics_publisher = std::dynamic_pointer_cast<c2::ControllerSocketMetricsPublisher>(publisher);
controller_socket_metrics_publisher->setFlowStatusDependencies(bulletin_store, flow_file_repo_->getDirectory(), content_repo_->getStoragePath());
}
- controller_socket_protocol_ = std::make_unique<c2::ControllerSocketProtocol>(*this, *this, configuration_, controller_socket_metrics_publisher);
+ controller_socket_protocol_ = std::make_unique<c2::ControllerSocketProtocol>(*this, configuration_, controller_socket_metrics_publisher);
root_wrapper_.setControllerSocketProtocol(controller_socket_protocol_.get());
}
}
@@ -345,7 +345,7 @@ int16_t FlowController::start() {
start_time_ = std::chrono::steady_clock::now();
}
- core::logging::LoggerConfiguration::getConfiguration().initializeAlertSinks(this, configuration_);
+ core::logging::LoggerConfiguration::getConfiguration().initializeAlertSinks(configuration_);
running_ = true;
content_repo_->start();
provenance_repo_->start();
diff --git a/libminifi/src/RemoteProcessGroupPort.cpp b/libminifi/src/RemoteProcessGroupPort.cpp
index 98fdc08cd..73443412d 100644
--- a/libminifi/src/RemoteProcessGroupPort.cpp
+++ b/libminifi/src/RemoteProcessGroupPort.cpp
@@ -94,7 +94,7 @@ std::unique_ptr<sitetosite::SiteToSiteClient> RemoteProcessGroupPort::getNextPro
auto& peer_status = peers_[peer_index_];
sitetosite::SiteToSiteClientConfiguration config(peer_status.getPortId(), peer_status.getHost(), peer_status.getPort(), local_network_interface_, client_type_);
peer_index_++;
- if (peer_index_ >= static_cast<int>(peers_.size())) {
+ if (peer_index_ >= gsl::narrow<int>(peers_.size())) {
peer_index_ = 0;
}
next_protocol = initializeProtocol(config);
@@ -161,7 +161,7 @@ void RemoteProcessGroupPort::onSchedule(core::ProcessContext& context, core::Pro
auto peer_status = peers_[peer_index_];
sitetosite::SiteToSiteClientConfiguration config(peer_status.getPortId(), peer_status.getHost(), peer_status.getPort(), local_network_interface_, client_type_);
peer_index_++;
- if (peer_index_ >= static_cast<int>(peers_.size())) {
+ if (peer_index_ >= gsl::narrow<int>(peers_.size())) {
peer_index_ = 0;
}
logger_->log_trace("Creating client");
@@ -235,7 +235,7 @@ std::optional<std::string> RemoteProcessGroupPort::getRestApiToken(const RPG& ni
return std::nullopt;
}
auto client = std::unique_ptr<http::BaseHTTPClient>(dynamic_cast<http::BaseHTTPClient*>(client_ptr));
- client->initialize(http::HttpRequestMethod::GET, login_url.str(), ssl_service_);
+ client->initialize(http::HttpRequestMethod::Get, login_url.str(), ssl_service_);
// use a connection timeout. if this times out we will simply attempt re-connection
// so no need for configuration parameter that isn't already defined in Processor
client->setConnectionTimeout(10s);
@@ -296,7 +296,7 @@ std::optional<std::pair<std::string, uint16_t>> RemoteProcessGroupPort::tryRefre
auto client = std::unique_ptr<http::BaseHTTPClient>(dynamic_cast<http::BaseHTTPClient*>(client_ptr));
auto full_url = buildFullSiteToSiteUrl(nifi);
- client->initialize(http::HttpRequestMethod::GET, full_url, ssl_service_);
+ client->initialize(http::HttpRequestMethod::Get, full_url, ssl_service_);
// use a connection timeout. if this times out we will simply attempt re-connection
// so no need for configuration parameter that isn't already defined in Processor
client->setConnectionTimeout(10s);
diff --git a/libminifi/src/c2/ControllerSocketProtocol.cpp b/libminifi/src/c2/ControllerSocketProtocol.cpp
index 7068af38e..d5bb7074d 100644
--- a/libminifi/src/c2/ControllerSocketProtocol.cpp
+++ b/libminifi/src/c2/ControllerSocketProtocol.cpp
@@ -69,13 +69,12 @@ ControllerSocketProtocol::SocketRestartCommandProcessor::~SocketRestartCommandPr
}
}
-ControllerSocketProtocol::ControllerSocketProtocol(core::controller::ControllerServiceProvider& controller, state::StateMonitor& update_sink,
- std::shared_ptr<Configure> configuration, const std::shared_ptr<ControllerSocketReporter>& controller_socket_reporter)
- : controller_(controller),
- update_sink_(update_sink),
- controller_socket_reporter_(controller_socket_reporter),
- configuration_(std::move(configuration)),
- socket_restart_processor_(update_sink_, logger_) {
+ControllerSocketProtocol::ControllerSocketProtocol(state::StateMonitor& update_sink, std::shared_ptr<Configure> configuration,
+ const std::shared_ptr<ControllerSocketReporter>& controller_socket_reporter)
+ : update_sink_(update_sink),
+ controller_socket_reporter_(controller_socket_reporter),
+ configuration_(std::move(configuration)),
+ socket_restart_processor_(update_sink_, logger_) {
gsl_Expects(configuration_);
}
@@ -145,19 +144,10 @@ asio::awaitable<void> ControllerSocketProtocol::startAcceptSsl(std::shared_ptr<m
void ControllerSocketProtocol::initialize() {
std::unique_lock<std::mutex> lock(initialization_mutex_);
std::shared_ptr<minifi::controllers::SSLContextServiceInterface> secure_context;
- std::string context_name;
- if (configuration_->get(Configure::controller_ssl_context_service, context_name)) {
- std::shared_ptr<core::controller::ControllerService> service = controller_.getControllerService(context_name);
- if (nullptr != service) {
- secure_context = std::dynamic_pointer_cast<minifi::controllers::SSLContextServiceInterface>(service);
- }
- }
- if (nullptr == secure_context) {
- std::string secure_str;
- if (configuration_->get(Configure::nifi_remote_input_secure, secure_str) && org::apache::nifi::minifi::utils::string::toBool(secure_str).value_or(false)) {
- secure_context = std::make_shared<minifi::controllers::SSLContextService>("ControllerSocketProtocolSSL", configuration_);
- secure_context->onEnable();
- }
+ std::string secure_str;
+ if (configuration_->get(Configure::nifi_remote_input_secure, secure_str) && org::apache::nifi::minifi::utils::string::toBool(secure_str).value_or(false)) {
+ secure_context = std::make_shared<minifi::controllers::SSLContextService>("ControllerSocketProtocolSSL", configuration_);
+ secure_context->onEnable();
}
std::string limit_str;
diff --git a/libminifi/src/c2/protocols/RESTSender.cpp b/libminifi/src/c2/protocols/RESTSender.cpp
index 56da8b607..a9835663e 100644
--- a/libminifi/src/c2/protocols/RESTSender.cpp
+++ b/libminifi/src/c2/protocols/RESTSender.cpp
@@ -44,8 +44,6 @@ void RESTSender::initialize(core::controller::ControllerServiceProvider* control
// base URL when one is not specified.
if (nullptr != configure) {
std::optional<std::string> rest_base_path = configure->get(Configuration::nifi_c2_rest_path_base);
- std::string update_str;
- std::string ssl_context_service_str;
configure->get(Configuration::nifi_c2_rest_url, "c2.rest.url", rest_uri_);
configure->get(Configuration::nifi_c2_rest_url_ack, "c2.rest.url.ack", ack_uri_);
if (rest_uri_.starts_with("/")) {
@@ -60,17 +58,10 @@ void RESTSender::initialize(core::controller::ControllerServiceProvider* control
}
ack_uri_ = rest_base_path.value() + ack_uri_;
}
- if (controller && configure->get(Configuration::nifi_c2_rest_ssl_context_service, "c2.rest.ssl.context.service", ssl_context_service_str)) {
- if (auto service = controller->getControllerService(ssl_context_service_str)) {
- ssl_context_service_ = std::dynamic_pointer_cast<minifi::controllers::SSLContextServiceInterface>(service);
- }
- }
- if (nullptr == ssl_context_service_) {
- std::string ssl_context_str;
- if (configure->get(Configure::nifi_remote_input_secure, ssl_context_str) && org::apache::nifi::minifi::utils::string::toBool(ssl_context_str).value_or(false)) {
- ssl_context_service_ = std::make_shared<minifi::controllers::SSLContextService>("RESTSenderSSL", configure);
- ssl_context_service_->onEnable();
- }
+ std::string ssl_context_str;
+ if (configure->get(Configure::nifi_remote_input_secure, ssl_context_str) && org::apache::nifi::minifi::utils::string::toBool(ssl_context_str).value_or(false)) {
+ ssl_context_service_ = std::make_shared<minifi::controllers::SSLContextService>("RESTSenderSSL", configure);
+ ssl_context_service_->onEnable();
}
if (auto req_encoding_str = configure->get(Configuration::nifi_c2_rest_request_encoding)) {
if (auto req_encoding = magic_enum::enum_cast<RequestEncoding>(*req_encoding_str, magic_enum::case_insensitive)) {
@@ -128,7 +119,7 @@ C2Payload RESTSender::sendPayload(const std::string& url, const Direction direct
auto setUpHttpRequest = [&](http::HttpRequestMethod http_method) {
client.set_request_method(http_method);
- if (url.find("https://") == 0) {
+ if (url.starts_with("https://")) {
if (!ssl_context_service_) {
setSecurityContext(client, http_method, url);
} else {
@@ -137,7 +128,7 @@ C2Payload RESTSender::sendPayload(const std::string& url, const Direction direct
}
};
if (direction == Direction::TRANSMIT) {
- setUpHttpRequest(http::HttpRequestMethod::POST);
+ setUpHttpRequest(http::HttpRequestMethod::Post);
if (payload.getOperation() == Operation::transfer) {
// treat nested payloads as files
for (const auto& file : payload.getNestedPayloads()) {
@@ -178,7 +169,7 @@ C2Payload RESTSender::sendPayload(const std::string& url, const Direction direct
} else {
// we do not need to set the upload callback
// since we are not uploading anything on a get
- setUpHttpRequest(http::HttpRequestMethod::GET);
+ setUpHttpRequest(http::HttpRequestMethod::Get);
}
if (payload.getOperation() == Operation::transfer) {
diff --git a/libminifi/src/core/logging/LoggerConfiguration.cpp b/libminifi/src/core/logging/LoggerConfiguration.cpp
index 6a9e7428a..cb3a74c0a 100644
--- a/libminifi/src/core/logging/LoggerConfiguration.cpp
+++ b/libminifi/src/core/logging/LoggerConfiguration.cpp
@@ -38,6 +38,7 @@
#include "utils/Literals.h"
#include "core/TypedValues.h"
#include "core/logging/Utils.h"
+#include "controllers/SSLContextService.h"
#include "spdlog/spdlog.h"
#include "spdlog/sinks/stdout_sinks.h"
@@ -346,10 +347,15 @@ void LoggerConfiguration::initializeCompression(const std::lock_guard<std::mutex
}
}
-void LoggerConfiguration::initializeAlertSinks(core::controller::ControllerServiceProvider* controller, const std::shared_ptr<AgentIdentificationProvider>& agent_id) {
+void LoggerConfiguration::initializeAlertSinks(const std::shared_ptr<Configure>& config) {
+ auto ssl_service = std::make_shared<controllers::SSLContextService>("AlertSinkSSLContextService", config);
+ ssl_service->onEnable();
+ if (ssl_service->getCertificateFile().empty()) {
+ ssl_service.reset();
+ }
std::lock_guard guard(mutex_);
for (auto& sink : alert_sinks_) {
- sink->initialize(controller, agent_id);
+ sink->initialize(config, ssl_service);
}
}
diff --git a/libminifi/src/core/logging/alert/AlertSink.cpp b/libminifi/src/core/logging/alert/AlertSink.cpp
index 86745e88e..e728ff970 100644
--- a/libminifi/src/core/logging/alert/AlertSink.cpp
+++ b/libminifi/src/core/logging/alert/AlertSink.cpp
@@ -21,7 +21,6 @@
#include "http/BaseHTTPClient.h"
#include "utils/Hash.h"
#include "core/logging/Utils.h"
-#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "rapidjson/rapidjson.h"
#include "rapidjson/document.h"
@@ -87,33 +86,15 @@ std::shared_ptr<AlertSink> AlertSink::create(const std::string& prop_name_prefix
config.rate_limit = readPropertyOr(".rate.limit", TimePeriodValue::fromString, "10 min").getMilliseconds();
config.buffer_limit = readPropertyOr(".buffer.limit", datasize_parser, "1 MB");
config.level = readPropertyOr(".level", utils::parse_log_level, "trace");
- config.ssl_service_name = logger_properties->getString(prop_name_prefix + ".ssl.context.service");
return std::shared_ptr<AlertSink>(new AlertSink(std::move(config), std::move(logger)));
}
-void AlertSink::initialize(core::controller::ControllerServiceProvider* controller, std::shared_ptr<AgentIdentificationProvider> agent_id) {
+void AlertSink::initialize(std::shared_ptr<AgentIdentificationProvider> agent_id, std::shared_ptr<controllers::SSLContextServiceInterface> ssl_service) {
auto services = std::make_unique<Services>();
services->agent_id = std::move(agent_id);
-
- if (config_.ssl_service_name) {
- if (!controller) {
- logger_->log_error("Could not find service '{}': no service provider", config_.ssl_service_name.value());
- return;
- }
- if (auto service = controller->getControllerService(config_.ssl_service_name.value())) {
- if (auto ssl_service = std::dynamic_pointer_cast<controllers::SSLContextServiceInterface>(service)) {
- services->ssl_service = ssl_service;
- } else {
- logger_->log_error("Service '{}' is not an SSLContextService", config_.ssl_service_name.value());
- return;
- }
- } else {
- logger_->log_error("Could not find service '{}'", config_.ssl_service_name.value());
- return;
- }
- }
+ services->ssl_service = std::move(ssl_service);
services.reset(services_.exchange(services.release()));
}
@@ -170,7 +151,7 @@ void AlertSink::run() {
Services* expected{nullptr};
// only restore the services pointer if no initialize set it to something else meanwhile
if (services_.compare_exchange_strong(expected, services.get())) {
- (void)services.release();
+ std::ignore = services.release();
}
}
}
@@ -199,7 +180,7 @@ void AlertSink::send(Services& services) {
logger_->log_error("Could not instantiate a HTTPClient object");
return;
}
- client->initialize(http::HttpRequestMethod::PUT, config_.url, services.ssl_service);
+ client->initialize(http::HttpRequestMethod::Put, config_.url, services.ssl_service);
rapidjson::Document doc(rapidjson::kObjectType);
std::string agent_id = services.agent_id->getAgentIdentifier();
diff --git a/libminifi/src/sitetosite/HttpSiteToSiteClient.cpp b/libminifi/src/sitetosite/HttpSiteToSiteClient.cpp
index b8fcbaf86..9cdbd8b08 100644
--- a/libminifi/src/sitetosite/HttpSiteToSiteClient.cpp
+++ b/libminifi/src/sitetosite/HttpSiteToSiteClient.cpp
@@ -35,8 +35,6 @@
#include "rapidjson/document.h"
#include "rapidjson/error/en.h"
-#undef DELETE // macro on windows
-
namespace org::apache::nifi::minifi::sitetosite {
namespace {
@@ -97,7 +95,7 @@ std::shared_ptr<Transaction> HttpSiteToSiteClient::createTransaction(TransferDir
std::string dir_str = direction == TransferDirection::SEND ? "input-ports" : "output-ports";
std::stringstream uri;
uri << getBaseURI() << "data-transfer/" << dir_str << "/" << getPortId().to_string() << "/transactions";
- auto client = createHttpClient(uri.str(), http::HttpRequestMethod::POST);
+ auto client = createHttpClient(uri.str(), http::HttpRequestMethod::Post);
setSiteToSiteHeaders(*client);
client->setConnectionTimeout(std::chrono::milliseconds(5000));
client->setContentType("application/json");
@@ -241,7 +239,7 @@ std::optional<std::vector<PeerStatus>> HttpSiteToSiteClient::getPeerList() {
std::stringstream uri;
uri << getBaseURI() << "site-to-site/peers";
- auto client = createHttpClient(uri.str(), http::HttpRequestMethod::GET);
+ auto client = createHttpClient(uri.str(), http::HttpRequestMethod::Get);
setSiteToSiteHeaders(*client);
@@ -256,7 +254,7 @@ std::optional<std::vector<PeerStatus>> HttpSiteToSiteClient::getPeerList() {
std::shared_ptr<minifi::http::HTTPClient> HttpSiteToSiteClient::openConnectionForSending(const std::shared_ptr<HttpTransaction> &transaction) {
std::stringstream uri;
uri << transaction->getTransactionUrl() << "/flow-files";
- std::shared_ptr<minifi::http::HTTPClient> client = createHttpClient(uri.str(), http::HttpRequestMethod::POST);
+ std::shared_ptr<minifi::http::HTTPClient> client = createHttpClient(uri.str(), http::HttpRequestMethod::Post);
client->setContentType("application/octet-stream");
client->setRequestHeader("Accept", "text/plain");
client->setRequestHeader("Transfer-Encoding", "chunked");
@@ -266,7 +264,7 @@ std::shared_ptr<minifi::http::HTTPClient> HttpSiteToSiteClient::openConnectionFo
std::shared_ptr<minifi::http::HTTPClient> HttpSiteToSiteClient::openConnectionForReceive(const std::shared_ptr<HttpTransaction> &transaction) {
std::stringstream uri;
uri << transaction->getTransactionUrl() << "/flow-files";
- return createHttpClient(uri.str(), http::HttpRequestMethod::GET);
+ return createHttpClient(uri.str(), http::HttpRequestMethod::Get);
}
std::string HttpSiteToSiteClient::getBaseURI() {
@@ -346,7 +344,7 @@ void HttpSiteToSiteClient::closeTransaction(const utils::Identifier &transaction
uri << "&checksum=" << transaction->getCRC();
}
- auto client = createHttpClient(uri.str(), http::HttpRequestMethod::DELETE);
+ auto client = createHttpClient(uri.str(), http::HttpRequestMethod::Delete);
setSiteToSiteHeaders(*client);
client->setConnectionTimeout(std::chrono::milliseconds(5000));
client->setRequestHeader("Accept", "application/json");
diff --git a/libminifi/test/integration/AlertTests.cpp b/libminifi/test/integration/AlertTests.cpp
index 73fa202d1..49d59dacc 100644
--- a/libminifi/test/integration/AlertTests.cpp
+++ b/libminifi/test/integration/AlertTests.cpp
@@ -79,7 +79,14 @@ TEST_CASE("Alert system forwards logs") {
std::string agent_id = "test-agent-1";
VerifyAlerts harness(flow_config_file.string(), dir.getPath());
AlertHandler handler(agent_id);
- harness.setUrl("http://localhost:0/api/alerts", &handler);
+
+ SECTION("Secure") {
+ harness.setKeyDir(TEST_RESOURCES);
+ harness.setUrl("https://localhost:0/api/alerts", &handler);
+ }
+ SECTION("Unsecure") {
+ harness.setUrl("http://localhost:0/api/alerts", &handler);
+ }
harness.getConfiguration()->set(minifi::Configuration::nifi_c2_agent_identifier, agent_id);
auto log_props = std::make_shared<logging::LoggerProperties>(dir.getPath() / "logs");
diff --git a/libminifi/test/integration/HTTPClientTests.cpp b/libminifi/test/integration/HTTPClientTests.cpp
index 688beb734..05d309e6a 100644
--- a/libminifi/test/integration/HTTPClientTests.cpp
+++ b/libminifi/test/integration/HTTPClientTests.cpp
@@ -82,7 +82,7 @@ TEST_CASE("HTTPClientTestChunkedResponse", "[basic]") {
const std::string port = std::to_string(vec.at(0));
HTTPClient client;
- client.initialize(http::HttpRequestMethod::GET, "http://localhost:" + port + "/testytesttest", nullptr);
+ client.initialize(http::HttpRequestMethod::Get, "http://localhost:" + port + "/testytesttest", nullptr);
REQUIRE(client.submit());
@@ -126,15 +126,15 @@ TEST_CASE("HTTPClient should be reusable", "[basic]") {
HTTPClient client;
client.setKeepAliveProbe(KeepAliveProbeData{2s, 2s});
- client.initialize(http::HttpRequestMethod::GET, "http://localhost:" + keep_alive_server_.getPort() + "/method", nullptr);
+ client.initialize(http::HttpRequestMethod::Get, "http://localhost:" + keep_alive_server_.getPort() + "/method", nullptr);
std::vector<http::HttpRequestMethod> methods = {
- http::HttpRequestMethod::GET, http::HttpRequestMethod::GET, http::HttpRequestMethod::PUT, http::HttpRequestMethod::GET,
- http::HttpRequestMethod::GET, http::HttpRequestMethod::POST, http::HttpRequestMethod::POST, http::HttpRequestMethod::PUT };
+ http::HttpRequestMethod::Get, http::HttpRequestMethod::Get, http::HttpRequestMethod::Put, http::HttpRequestMethod::Get,
+ http::HttpRequestMethod::Get, http::HttpRequestMethod::Post, http::HttpRequestMethod::Post, http::HttpRequestMethod::Put };
uint64_t request_number = 0;
for (const auto& method: methods) {
client.set_request_method(method);
- if (method != http::HttpRequestMethod::GET) {
+ if (method != http::HttpRequestMethod::Get) {
auto callback = std::make_unique<org::apache::nifi::minifi::http::HTTPUploadByteArrayInputCallback>();
std::string content = R"({ "content": "a" })";
callback->write(content);
@@ -162,7 +162,7 @@ TEST_CASE("HTTPClient should be reusable", "[basic]") {
#ifdef __linux__
TEST_CASE("SSL without SSLContextService", "[HTTPClient]") {
HTTPClient client;
- client.initialize(http::HttpRequestMethod::GET, "https://apache.org", nullptr);
+ client.initialize(http::HttpRequestMethod::Get, "https://apache.org", nullptr);
REQUIRE(client.submit());
}
#endif
diff --git a/libminifi/test/libtest/unit/TestBase.h b/libminifi/test/libtest/unit/TestBase.h
index b410f9fae..d87178ec0 100644
--- a/libminifi/test/libtest/unit/TestBase.h
+++ b/libminifi/test/libtest/unit/TestBase.h
@@ -41,6 +41,7 @@
#include "utils/file/FileUtils.h"
#include "properties/Configuration.h"
#include "core/Processor.h"
+#include "core/ProcessGroup.h"
namespace minifi = org::apache::nifi::minifi;
namespace utils = minifi::utils;
diff --git a/libminifi/test/resources/encrypted.minifi.properties b/libminifi/test/resources/encrypted.minifi.properties
index dc1bf5272..79d5a550a 100644
--- a/libminifi/test/resources/encrypted.minifi.properties
+++ b/libminifi/test/resources/encrypted.minifi.properties
@@ -84,7 +84,6 @@ c2.agent.identifier.protected=xsalsa20poly1305
#controller.socket.host=localhost
#controller.socket.port=9998
#controller.socket.local.any.interface=false
-#controller.ssl.context.service=SSLContextService
# must be comma separated
diff --git a/libminifi/test/unit/ArrayUtilsTests.cpp b/libminifi/test/unit/ArrayUtilsTests.cpp
index 481e1d945..e56fb58f4 100644
--- a/libminifi/test/unit/ArrayUtilsTests.cpp
+++ b/libminifi/test/unit/ArrayUtilsTests.cpp
@@ -45,8 +45,8 @@ TEST_CASE("getKeys() works correctly and is constexpr") {
inline constexpr std::array<std::pair<int, int>, 3> global_mapping{{ {1, 1}, {2, 4}, {3, 27} }};
template<int> struct is_usable_as_constant_expression {};
-template<int key> concept does_compile = requires { is_usable_as_constant_expression<utils::at(global_mapping, key)>(); };
-template<int key> concept does_not_compile = !does_compile<key>;
+template<int key> concept compiles_as_a_constant_expression = requires { is_usable_as_constant_expression<utils::at(global_mapping, key)>(); };
+template<int key> concept does_not_compile_as_a_constant_expression = !compiles_as_a_constant_expression<key>;
TEST_CASE("at() works correctly and is constexpr") {
static constexpr std::array<std::pair<int, std::string_view>, 3> mapping{{ {1, "one"}, {2, "two"}, {3, "three"} }};
@@ -56,8 +56,8 @@ TEST_CASE("at() works correctly and is constexpr") {
int one = 1;
CHECK(utils::at(mapping, one) == "one"); // non-constexpr argument is OK, but the result is not constexpr
- static_assert(does_compile<3>);
- static_assert(does_not_compile<4>);
+ static_assert(compiles_as_a_constant_expression<3>);
+ static_assert(does_not_compile_as_a_constant_expression<4>);
CHECK_THROWS(utils::at(mapping, 4));
}
diff --git a/libminifi/test/unit/EnvironmentVariableParameterProviderTest.cpp b/libminifi/test/unit/EnvironmentVariableParameterProviderTest.cpp
index 39036f5ff..45f5a70a6 100644
--- a/libminifi/test/unit/EnvironmentVariableParameterProviderTest.cpp
+++ b/libminifi/test/unit/EnvironmentVariableParameterProviderTest.cpp
@@ -23,7 +23,7 @@
namespace org::apache::nifi::minifi::test {
TEST_CASE("Parameter Group Name is required", "[parameterProviders]") {
- utils::Environment::setEnvironmentVariable("MINIFI_DATA", "minifi_data_value");
+ minifi::utils::Environment::setEnvironmentVariable("MINIFI_DATA", "minifi_data_value");
parameter_providers::EnvironmentVariableParameterProvider provider("EnvironmentVariableParameterProvider");
provider.initialize();
REQUIRE(provider.setProperty(parameter_providers::EnvironmentVariableParameterProvider::ParameterGroupName.name, ""));
@@ -31,7 +31,7 @@ TEST_CASE("Parameter Group Name is required", "[parameterProviders]") {
}
TEST_CASE("Test EnvironmentVariableParameterProvider with default options", "[parameterProviders]") {
- utils::Environment::setEnvironmentVariable("MINIFI_DATA", "minifi_data_value");
+ minifi::utils::Environment::setEnvironmentVariable("MINIFI_DATA", "minifi_data_value");
parameter_providers::EnvironmentVariableParameterProvider provider("EnvironmentVariableParameterProvider");
provider.initialize();
REQUIRE(provider.setProperty(parameter_providers::EnvironmentVariableParameterProvider::ParameterGroupName.name, "environment-variable-parameter-context"));
@@ -45,8 +45,8 @@ TEST_CASE("Test EnvironmentVariableParameterProvider with default options", "[pa
}
TEST_CASE("Create parameter context with selected environment variables", "[parameterProviders]") {
- utils::Environment::setEnvironmentVariable("MINIFI_DATA", "minifi_data_value");
- utils::Environment::setEnvironmentVariable("MINIFI_NEW_DATA", "minifi_new_data_value");
+ minifi::utils::Environment::setEnvironmentVariable("MINIFI_DATA", "minifi_data_value");
+ minifi::utils::Environment::setEnvironmentVariable("MINIFI_NEW_DATA", "minifi_new_data_value");
parameter_providers::EnvironmentVariableParameterProvider provider("EnvironmentVariableParameterProvider");
provider.initialize();
REQUIRE(provider.setProperty(parameter_providers::EnvironmentVariableParameterProvider::ParameterGroupName.name, "environment-variable-parameter-context"));
@@ -73,8 +73,8 @@ TEST_CASE("Environment variable list must be defined if Comma-Separated inclusio
}
TEST_CASE("Create parameter context with regex matching environment variables", "[parameterProviders]") {
- utils::Environment::setEnvironmentVariable("MINIFI_DATA_1", "minifi_data_value");
- utils::Environment::setEnvironmentVariable("MINIFI_NEW_DATA", "minifi_new_data_value");
+ minifi::utils::Environment::setEnvironmentVariable("MINIFI_DATA_1", "minifi_data_value");
+ minifi::utils::Environment::setEnvironmentVariable("MINIFI_NEW_DATA", "minifi_new_data_value");
parameter_providers::EnvironmentVariableParameterProvider provider("EnvironmentVariableParameterProvider");
provider.initialize();
REQUIRE(provider.setProperty(parameter_providers::EnvironmentVariableParameterProvider::ParameterGroupName.name, "environment-variable-parameter-context"));
diff --git a/libminifi/test/unit/GeneralUtilsTest.cpp b/libminifi/test/unit/GeneralUtilsTest.cpp
index 3adf57d82..e1ac2f544 100644
--- a/libminifi/test/unit/GeneralUtilsTest.cpp
+++ b/libminifi/test/unit/GeneralUtilsTest.cpp
@@ -27,55 +27,55 @@
namespace org::apache::nifi::minifi::test {
// intdiv_ceil
-static_assert(0 == utils::intdiv_ceil(0, 1));
-static_assert(0 == utils::intdiv_ceil(0, 2));
-static_assert(1 == utils::intdiv_ceil(1, 2));
-static_assert(1 == utils::intdiv_ceil(1, 3));
-static_assert(1 == utils::intdiv_ceil(3, 3));
-static_assert(2 == utils::intdiv_ceil(4, 3));
-static_assert(2 == utils::intdiv_ceil(5, 3));
-static_assert(0 == utils::intdiv_ceil(-1, 3));
-static_assert(-1 == utils::intdiv_ceil(-3, 3));
-static_assert(-1 == utils::intdiv_ceil(-4, 3));
-static_assert(2 == utils::intdiv_ceil(-4, -3));
-static_assert(2 == utils::intdiv_ceil(-5, -3));
-static_assert(0 == utils::intdiv_ceil(1, -3));
-static_assert(-1 == utils::intdiv_ceil(5, -3));
-static_assert(3 == utils::intdiv_ceil(6, 2));
-static_assert(-3 == utils::intdiv_ceil(-6, 2));
-static_assert(-3 == utils::intdiv_ceil(6, -2));
-static_assert(3 == utils::intdiv_ceil(-6, -2));
-static_assert(0 == utils::intdiv_ceil(0, -10));
+static_assert(0 == minifi::utils::intdiv_ceil(0, 1));
+static_assert(0 == minifi::utils::intdiv_ceil(0, 2));
+static_assert(1 == minifi::utils::intdiv_ceil(1, 2));
+static_assert(1 == minifi::utils::intdiv_ceil(1, 3));
+static_assert(1 == minifi::utils::intdiv_ceil(3, 3));
+static_assert(2 == minifi::utils::intdiv_ceil(4, 3));
+static_assert(2 == minifi::utils::intdiv_ceil(5, 3));
+static_assert(0 == minifi::utils::intdiv_ceil(-1, 3));
+static_assert(-1 == minifi::utils::intdiv_ceil(-3, 3));
+static_assert(-1 == minifi::utils::intdiv_ceil(-4, 3));
+static_assert(2 == minifi::utils::intdiv_ceil(-4, -3));
+static_assert(2 == minifi::utils::intdiv_ceil(-5, -3));
+static_assert(0 == minifi::utils::intdiv_ceil(1, -3));
+static_assert(-1 == minifi::utils::intdiv_ceil(5, -3));
+static_assert(3 == minifi::utils::intdiv_ceil(6, 2));
+static_assert(-3 == minifi::utils::intdiv_ceil(-6, 2));
+static_assert(-3 == minifi::utils::intdiv_ceil(6, -2));
+static_assert(3 == minifi::utils::intdiv_ceil(-6, -2));
+static_assert(0 == minifi::utils::intdiv_ceil(0, -10));
template<int N, int D, typename = void>
-struct does_compile : std::false_type {};
+struct compiles_as_a_constant_expression : std::false_type {};
template<int N, int D>
-struct does_compile<N, D,
+struct compiles_as_a_constant_expression<N, D,
// we must force evaluation so decltype won't do
- typename std::enable_if<(utils::intdiv_ceil(N, D), true)>::type> : std::true_type {};
+ std::enable_if_t<(minifi::utils::intdiv_ceil(N, D), true)>> : std::true_type {};
-static_assert(does_compile<2, 3>::value, "does_compile should work");
-static_assert(!does_compile<1, 0>::value, "constexpr division by zero shouldn't compile");
+static_assert(compiles_as_a_constant_expression<2, 3>::value, "compiles_as_a_constant_expression should work");
+static_assert(!compiles_as_a_constant_expression<1, 0>::value, "constexpr division by zero shouldn't compile");
TEST_CASE("GeneralUtils::dereference", "[dereference]") {
const int a = 42;
const auto pa = gsl::make_not_null(&a);
- REQUIRE(42 == utils::dereference(pa));
- REQUIRE(&a == &utils::dereference(pa));
+ REQUIRE(42 == minifi::utils::dereference(pa));
+ REQUIRE(&a == &minifi::utils::dereference(pa));
const auto uniq_a = gsl::make_not_null(std::make_unique<int>(99));
- REQUIRE(99 == utils::dereference(uniq_a));
+ REQUIRE(99 == minifi::utils::dereference(uniq_a));
}
TEST_CASE("GeneralUtils::unsafe_dereference", "[unsafe_dereference]") {
const int a = 42;
const int* const pa = &a;
- REQUIRE(42 == utils::unsafe_dereference(pa));
- REQUIRE(&a == &utils::unsafe_dereference(pa));
+ REQUIRE(42 == minifi::utils::unsafe_dereference(pa));
+ REQUIRE(&a == &minifi::utils::unsafe_dereference(pa));
const auto uniq_a = std::make_unique<int>(99);
- REQUIRE(99 == utils::unsafe_dereference(uniq_a));
+ REQUIRE(99 == minifi::utils::unsafe_dereference(uniq_a));
}
} // namespace org::apache::nifi::minifi::test
diff --git a/libminifi/test/unit/ParameterTokenParserTest.cpp b/libminifi/test/unit/ParameterTokenParserTest.cpp
index 8f21a2cb2..92dd87821 100644
--- a/libminifi/test/unit/ParameterTokenParserTest.cpp
+++ b/libminifi/test/unit/ParameterTokenParserTest.cpp
@@ -124,8 +124,8 @@ TEST_CASE("Test replacement with missing token in context") {
}
TEST_CASE("Sensitive property parameter replacement is not supported") {
- utils::crypto::Bytes secret_key = utils::string::from_hex("cb76fe6fe4cbfdc3770c0cb0afc910f81ced4d436b11f691395fc2a9dbea27ca");
- utils::crypto::EncryptionProvider encryption_provider{secret_key};
+ minifi::utils::crypto::Bytes secret_key = minifi::utils::string::from_hex("cb76fe6fe4cbfdc3770c0cb0afc910f81ced4d436b11f691395fc2a9dbea27ca");
+ minifi::utils::crypto::EncryptionProvider encryption_provider{secret_key};
core::SensitiveParameterTokenParser parser("What is #{what}, baby don't hurt #{who}, don't hurt #{who}, no more", encryption_provider);
core::ParameterContext context("test_context");
context.addParameter(core::Parameter{"what", "", false, false, "love"});
@@ -141,19 +141,19 @@ TEST_CASE("Parameter context is not provided when parameter is referenced") {
TEST_CASE("Replace only escaped tokens") {
core::NonSensitiveParameterTokenParser non_sensitive_parser("No ##{parameters} are ####{present}");
REQUIRE(non_sensitive_parser.replaceParameters(nullptr) == "No #{parameters} are ##{present}");
- utils::crypto::Bytes secret_key = utils::string::from_hex("cb76fe6fe4cbfdc3770c0cb0afc910f81ced4d436b11f691395fc2a9dbea27ca");
- utils::crypto::EncryptionProvider encryption_provider{secret_key};
+ minifi::utils::crypto::Bytes secret_key = minifi::utils::string::from_hex("cb76fe6fe4cbfdc3770c0cb0afc910f81ced4d436b11f691395fc2a9dbea27ca");
+ minifi::utils::crypto::EncryptionProvider encryption_provider{secret_key};
core::SensitiveParameterTokenParser sensitive_parser("No ##{parameters} are ####{present}", encryption_provider);
REQUIRE(sensitive_parser.replaceParameters(nullptr) == "No #{parameters} are ##{present}");
}
TEST_CASE("Test sensitive token replacement") {
core::ParameterContext context("test_context");
- utils::crypto::Bytes secret_key = utils::string::from_hex("cb76fe6fe4cbfdc3770c0cb0afc910f81ced4d436b11f691395fc2a9dbea27ca");
- utils::crypto::EncryptionProvider encryption_provider{secret_key};
+ minifi::utils::crypto::Bytes secret_key = minifi::utils::string::from_hex("cb76fe6fe4cbfdc3770c0cb0afc910f81ced4d436b11f691395fc2a9dbea27ca");
+ minifi::utils::crypto::EncryptionProvider encryption_provider{secret_key};
core::SensitiveParameterTokenParser parser("What is #{what}, baby don't hurt #{who}, don't hurt #{who}, no more", encryption_provider);
- auto value1 = utils::crypto::property_encryption::encrypt("love", encryption_provider);
- auto value2 = utils::crypto::property_encryption::encrypt("me", encryption_provider);
+ auto value1 = minifi::utils::crypto::property_encryption::encrypt("love", encryption_provider);
+ auto value2 = minifi::utils::crypto::property_encryption::encrypt("me", encryption_provider);
context.addParameter(core::Parameter{"what", "", true, false, value1});
context.addParameter(core::Parameter{"who", "", true, false, value2});
REQUIRE(parser.replaceParameters(&context) == "What is love, baby don't hurt me, don't hurt me, no more");
diff --git a/minifi-api/include/minifi-cpp/properties/Configuration.h b/minifi-api/include/minifi-cpp/properties/Configuration.h
index 373ea9772..a5872be6f 100644
--- a/minifi-api/include/minifi-cpp/properties/Configuration.h
+++ b/minifi-api/include/minifi-cpp/properties/Configuration.h
@@ -124,7 +124,6 @@ class Configuration : public virtual Properties {
static constexpr const char *nifi_c2_rest_path_base = "nifi.c2.rest.path.base";
static constexpr const char *nifi_c2_rest_url = "nifi.c2.rest.url";
static constexpr const char *nifi_c2_rest_url_ack = "nifi.c2.rest.url.ack";
- static constexpr const char *nifi_c2_rest_ssl_context_service = "nifi.c2.rest.ssl.context.service";
static constexpr const char *nifi_c2_rest_heartbeat_minimize_updates = "nifi.c2.rest.heartbeat.minimize.updates";
static constexpr const char *nifi_c2_rest_request_encoding = "nifi.c2.rest.request.encoding";
static constexpr const char *nifi_c2_flow_info_processor_bulletin_limit = "nifi.c2.flow.info.processor.bulletin.limit";
@@ -166,7 +165,6 @@ class Configuration : public virtual Properties {
// alert options
static constexpr const char *nifi_log_alert_url = "nifi.log.alert.url";
- static constexpr const char *nifi_log_alert_ssl_context_service = "nifi.log.alert.ssl.context.service";
static constexpr const char *nifi_log_alert_batch_size = "nifi.log.alert.batch.size";
static constexpr const char *nifi_log_alert_flush_period = "nifi.log.alert.flush.period";
static constexpr const char *nifi_log_alert_filter = "nifi.log.alert.filter";
@@ -193,7 +191,6 @@ class Configuration : public virtual Properties {
static constexpr const char *controller_socket_local_any_interface = "controller.socket.local.any.interface";
static constexpr const char *controller_socket_host = "controller.socket.host";
static constexpr const char *controller_socket_port = "controller.socket.port";
- static constexpr const char *controller_ssl_context_service = "controller.ssl.context.service";
static constexpr const char *nifi_flow_file_repository_check_health = "nifi.flowfile.repository.check.health";
static constexpr const char *nifi_python_virtualenv_directory = "nifi.python.virtualenv.directory";
(nifi-minifi-cpp) 04/04: MINIFICPP-2652 Remove deprecated bootstrap.sh
Posted by sz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
szaszm pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/nifi-minifi-cpp.git
commit 612e9f5c3d390a93a3a055fb1ba4f8a354fe3614
Author: Martin Zink <ma...@apache.org>
AuthorDate: Fri Oct 17 17:17:04 2025 +0200
MINIFICPP-2652 Remove deprecated bootstrap.sh
Closes #2049
Signed-off-by: Marton Szasz <sz...@apache.org>
---
README.md | 72 --------
ThirdParties.md | 7 -
aptitude.sh | 89 ---------
arch.sh | 77 --------
bootstrap.sh | 524 -----------------------------------------------------
bstrp_functions.sh | 474 ------------------------------------------------
centos.sh | 99 ----------
conanfile.py | 2 +-
darwin.sh | 109 -----------
debian.sh | 90 ---------
deploy.sh | 28 ---
fedora.sh | 83 ---------
linux.sh | 60 ------
rheldistro.sh | 91 ----------
suse.sh | 96 ----------
15 files changed, 1 insertion(+), 1900 deletions(-)
diff --git a/README.md b/README.md
index 8e1603b63..c4da64624 100644
--- a/README.md
+++ b/README.md
@@ -304,68 +304,6 @@ Prerequisites:
This will set up a virtual environment in the bootstrap folder, and guide you through the build process.
-#### Shell based bootstrapping (linux and macOS)
-- Please run the command `bootstrap.sh` from the root of the MiNiFi C++ source tree.
-
-- Per the table, below, you will be presented with a menu guided bootstrap process. You may enable and disable extensions ( further defined below ). Once you are finished selecting the features
- you wish to build, enter P to continue with the process. CMAKE dependencies will be resolved for your distro. You may enter command line options -n to force yes to all prompts
- (including the package installation prompts ) and -b to automatically run make once the cmake process is complete. Alternatively, you may include the package argument to bootstrap, -p,
- which will run make package.
-
-- If you provide -b or -p to bootstrap.sh, you do not need to follow the Building section, below. If you do not provide these arguments you may skip the cmake .. section from Building.
-
-- Using the Release build profile is recommended to reduce binary size. (~200 MB vs ~30 MB)
-
- ```
- # ~/Development/code/apache/nifi-minifi-cpp on git:master
- $ ./bootstrap.sh
- # CMAKE Build dir exists, should we overwrite your build directory before we begin?
- If you have already bootstrapped, bootstrapping again isn't necessary to run make [ Y/N ] Y
- ****************************************
- Select MiNiFi C++ Features to toggle.
- ****************************************
- A. Persistent Repositories .....Enabled
- C. libarchive features .........Enabled
- D. Python Scripting support ....Enabled
- E. Expression Language support .Enabled
- F. Kafka support ...............Enabled
- K. Bustache Support ............Disabled
- L. Lua Scripting Support .......Enabled
- M. MQTT Support ................Enabled
- O. SFTP Support ................Disabled
- S. AWS Support .................Enabled
- T. OpenCV Support ..............Disabled
- U. OPC-UA Support...............Enabled
- V. SQL Support..................Enabled
- X. Azure Support ...............Enabled
- Y. Systemd Support .............Enabled
- AA. Splunk Support .............Enabled
- AB. Kubernetes Support .........Enabled
- AC. Google Cloud Support .......Enabled
- AD. ProcFs Support .............Enabled
- AE. Prometheus Support .........Enabled
- AF. Elasticsearch Support ......Enabled
- ****************************************
- Build Options.
- ****************************************
- 1. Enable Tests ................Enabled
- 2. Enable all extensions
- 4. Use Shared Dependency Links .Enabled
- 5. Build Profile ...............RelWithDebInfo Debug MinSizeRel Release
- 6. Create ASAN build ...........Disabled
- 7. Treat warnings as errors.....Disabled
- P. Continue with these options
- Q. Quit
- * Extension cannot be installed due to
- version of cmake or other software, or
- incompatibility with other extensions
-
- Enter choice [A-Z or AA-AF or 1-7]
- ```
-
-- Bootstrap now saves state between runs. State will automatically be saved. Provide -c or --clear to clear this state. The -i option provides a guided menu install with the ability to change
-advanced features.
-
### Building
#### Build MiNiFi using Standalone CMake
@@ -545,16 +483,6 @@ The container can be run with a specific configuration by mounting the locally e
$ docker run -v ~/Development/apache/nifi-minifi-cpp/conf/config.yml:/opt/minifi/minifi-current/conf/config.yml -v ~/Development/apache/nifi-minifi-cpp/conf/minifi.properties:/opt/minifi/minifi-current/conf/minifi.properties apache/nifi-minifi-cpp
```
-### Deploying
-MiNiFi C++ comes with a deployment script. This will build and package minifi. Additionally, a file named build_output will be
-created within the build directory that contains a manifest of build artifacts.
-
- $ deploy.sh <build identifier>
-
-The build identifier will be carried with the deployed binary for the configuration you specify. By default all extensions will be built.
-
-On Windows it is suggested that MSI be used for installation.
-
### Cleaning
Remove the build directory created above.
```
diff --git a/ThirdParties.md b/ThirdParties.md
index a2aca323d..19dd6afad 100644
--- a/ThirdParties.md
+++ b/ThirdParties.md
@@ -25,7 +25,6 @@ This document describes the way we build and use third parties and provides a gu
+ [License](#license)
* [Built-in or system dependency](#built-in-or-system-dependency)
* [System dependency](#system-dependency)
- + [bootstrap.sh](#bootstrapsh)
+ [Find\<Package\>.cmake](#find--package--cmake)
+ [find_package](#find-package)
* [Built-in dependency](#built-in-dependency)
@@ -98,12 +97,6 @@ Both a system and a built-in version can be supported, in which case the choice
To add a new system dependency, you have to follow the following steps:
-### bootstrap.sh
-
-If you are using a system dependency, you have to ensure that the development packages are installed on the build system if the extension is selected.
-
-To ensure this, edit `bootstrap.sh` and all the platform-specific scripts (`centos.sh`, `fedora.sh`, `debian.sh`, `suse.sh`, `rheldistro.sh`, `darwin.sh`).
-
### Find\<Package\>.cmake
If a `Find<Package>.cmake` is provided for your third party by not unreasonably new (not later than 3.2) CMake versions out of the box, then you have nothing further to do, unless they don't create imported library targets.
diff --git a/aptitude.sh b/aptitude.sh
deleted file mode 100644
index 9528fed32..000000000
--- a/aptitude.sh
+++ /dev/null
@@ -1,89 +0,0 @@
-#!/bin/bash
-# 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.
-
-verify_enable_platform(){
- feature="$1"
- verify_gcc_enable "$feature"
-}
-add_os_flags() {
- CC=${CC:-gcc}
- CXX=${CXX:-g++}
- export CC
- export CXX
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DCMAKE_C_COMPILER=$CC -DCMAKE_CXX_COMPILER=$CXX"
-}
-bootstrap_cmake(){
- ## on Ubuntu install the latest CMake
- echo "Adding KitWare CMake apt repository..."
- sudo apt-get update && sudo apt-get install -y apt-transport-https ca-certificates gnupg software-properties-common wget
- wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | sudo apt-key add -
- sudo apt-add-repository "deb https://apt.kitware.com/ubuntu/ $(lsb_release -c --short) main" && sudo apt-get update
- sudo apt-get -y install cmake
-}
-bootstrap_compiler() {
- compiler_pkgs="gcc g++"
- # shellcheck disable=SC2086
- sudo apt-get -y install $compiler_pkgs
-}
-build_deps(){
- COMMAND="sudo apt-get -y install zlib1g-dev libssl-dev uuid uuid-dev perl libbz2-dev libcurl4-openssl-dev"
-
- export DEBIAN_FRONTEND=noninteractive
- INSTALLED=()
- sudo apt-get -y update
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "$option_value" = "${TRUE}" ]; then
- # option is enabled
- FOUND_VALUE=""
- for cmake_opt in "${DEPENDENCIES[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND_VALUE="$VALUE"
- if [ "$FOUND_VALUE" = "openssl" ]; then
- INSTALLED+=("openssl")
- elif [ "$FOUND_VALUE" = "bison" ]; then
- INSTALLED+=("bison")
- elif [ "$FOUND_VALUE" = "flex" ]; then
- INSTALLED+=("flex")
- elif [ "$FOUND_VALUE" = "automake" ]; then
- INSTALLED+=("automake")
- elif [ "$FOUND_VALUE" = "autoconf" ]; then
- INSTALLED+=("autoconf")
- elif [ "$FOUND_VALUE" = "libtool" ]; then
- INSTALLED+=("libtool")
- elif [ "$FOUND_VALUE" = "python" ]; then
- INSTALLED+=("libpython3-dev")
- elif [ "$FOUND_VALUE" = "libarchive" ]; then
- INSTALLED+=("liblzma-dev")
- fi
- fi
- done
-
- fi
- done
-
- for option in "${INSTALLED[@]}" ; do
- COMMAND="${COMMAND} $option"
- done
-
- echo "Ensuring you have all dependencies installed..."
- ${COMMAND}
-
-}
diff --git a/arch.sh b/arch.sh
deleted file mode 100644
index 47cb53313..000000000
--- a/arch.sh
+++ /dev/null
@@ -1,77 +0,0 @@
-#!/bin/bash
-# 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.
-
-verify_enable_platform(){
- feature="$1"
- verify_gcc_enable "${feature}"
-}
-add_os_flags() {
- #CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND}"
- :
-}
-bootstrap_cmake(){
- sudo pacman -S --noconfirm cmake
-}
-bootstrap_compiler(){
- sudo pacman -S --noconfirm gcc
-}
-build_deps(){
- COMMAND="sudo pacman -S --noconfirm --needed cmake zlib openssl util-linux make patch which pkgconf perl bzip2 curl"
-
- INSTALLED=()
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "$option_value" = "${TRUE}" ]; then
- # option is enabled
- FOUND_VALUE=""
- for cmake_opt in "${DEPENDENCIES[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND_VALUE="$VALUE"
- if [ "$FOUND_VALUE" = "openssl" ]; then
- INSTALLED+=("openssl")
- elif [ "$FOUND_VALUE" = "bison" ]; then
- INSTALLED+=("bison")
- elif [ "$FOUND_VALUE" = "flex" ]; then
- INSTALLED+=("flex")
- elif [ "$FOUND_VALUE" = "automake" ]; then
- INSTALLED+=("automake")
- elif [ "$FOUND_VALUE" = "autoconf" ]; then
- INSTALLED+=("autoconf")
- elif [ "$FOUND_VALUE" = "libtool" ]; then
- INSTALLED+=("libtool")
- elif [ "$FOUND_VALUE" = "python" ]; then
- INSTALLED+=("python")
- elif [ "$FOUND_VALUE" = "libarchive" ]; then
- INSTALLED+=("libarchive")
- fi
- fi
- done
-
- fi
- done
-
- for option in "${INSTALLED[@]}" ; do
- COMMAND="${COMMAND} $option"
- done
-
- echo "Ensuring you have all dependencies installed..."
- ${COMMAND}
-
-}
diff --git a/bootstrap.sh b/bootstrap.sh
deleted file mode 100755
index 08de26be8..000000000
--- a/bootstrap.sh
+++ /dev/null
@@ -1,524 +0,0 @@
-#!/usr/bin/env bash
-# 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.
-
-script_directory="$(cd "$(dirname "$0")" && pwd)"
-
-CMAKE_GLOBAL_MIN_VERSION_MAJOR=3
-CMAKE_GLOBAL_MIN_VERSION_MINOR=24
-CMAKE_GLOBAL_MIN_VERSION_REVISION=0
-
-export RED='\033[0;101m'
-export NO_COLOR='\033[0;0;39m'
-export TRUE="Enabled"
-export FALSE="Disabled"
-export DEPLOY="false"
-export NO_PROMPT="false"
-export FEATURES_SELECTED="false"
-export ALL_FEATURES_ENABLED=${FALSE}
-export BUILD_DIR="build"
-export BUILD_IDENTIFIER=""
-export OPTIONS=()
-export CMAKE_OPTIONS=()
-export CMAKE_MIN_VERSION=()
-export INCOMPATIBLE_WITH=()
-export DEPLOY_LIMITS=()
-export DEPENDENCIES=()
-export DEPENDS_ON=()
-
-CORES=1
-BUILD="false"
-PACKAGE="false"
-USER_DISABLE_TESTS="${FALSE}"
-USE_NINJA="false"
-
-. "${script_directory}/bstrp_functions.sh"
-SKIP_CMAKE=${FALSE}
-MENU="features"
-GUIDED_INSTALL=${FALSE}
-while :; do
- case $1 in
- -n|--noprompt)
- NO_PROMPT="true"
- ;;
- -s|--skiptests)
- USER_DISABLE_TESTS="${TRUE}"
- ;;
- -g|--useninja)
- USE_NINJA="${TRUE}"
- ;;
- -e|--enableall)
- NO_PROMPT="true"
- FEATURES_SELECTED="true"
- EnableAllFeatures
- ;;
- -c|--clear)
- rm "${script_directory}/bt_state" > /dev/null 2>&1
- ;;
- -d|--deploy)
- NO_PROMPT="true"
- DEPLOY="true"
- FEATURES_SELECTED="true"
- EnableAllFeatures
- ;;
- "--build_dir="* )
- BUILD_DIR="${1#*=}"
- ;;
- -t|--continous-integration)
- NO_PROMPT="true"
- FEATURES_SELECTED="true"
- SKIP_CMAKE="${TRUE}"
- ;;
- -p|--package)
- CORES=$(grep -c ^processor /proc/cpuinfo 2>/dev/null || sysctl -n hw.ncpu)
- BUILD="true"
- PACKAGE="true"
- ;;
- -i|--install)
- GUIDED_INSTALL="Enabled"
- EnableAllFeatures
- MENU="main"
- ALL_FEATURES_ENABLED=${TRUE}
- ;;
- -b|--build)
- CORES=$(grep -c ^processor /proc/cpuinfo 2>/dev/null || sysctl -n hw.ncpu)
- BUILD="true"
- ;;
- "--build_identifier="* )
- BUILD_IDENTIFIER="${1#*=}"
- ;;
- *) break
- esac
- shift
-done
-
-if [ -x "$(command -v hostname)" ]; then
- HOSTNAME=$(hostname)
- PING_RESULT=$(ping -c 1 "${HOSTNAME}" 2>&1)
- if [[ "$PING_RESULT" = *unknown* ]]; then
- cntinu="N"
- read -r -p "Cannot resolve your host name -- ${HOSTNAME} -- tests may fail, Continue? [ Y/N ] " cntinu
- if [ "$cntinu" = "Y" ] || [ "$cntinu" = "y" ]; then
- echo "Continuing..."
- else
- exit
- fi
- fi
-fi
-
-
-if [ "$NO_PROMPT" = "true" ]; then
- echo "****************************************"
- echo "Welcome, this bootstrap script will update your system to install MiNiFi C++"
- echo "You have opted to skip prompts. "
-fi
-
-
-
-if [ -f /etc/os-release ]; then
- . /etc/os-release
- OS=$NAME
- VER=$VERSION_ID
-elif type lsb_release >/dev/null 2>&1; then
- OS=$(lsb_release -si)
- VER=$(lsb_release -sr)
-elif [ -f /etc/lsb-release ]; then
- . /etc/lsb-release
- OS=$DISTRIB_ID
- VER=$DISTRIB_RELEASE
-elif [ -f /etc/debian_version ]; then
- OS=Debian
- VER=$(cat /etc/debian_version)
-elif [ -f /etc/SUSE-brand ]; then
- VER=$(tr '\n' ' ' < /etc/SUSE-brand | sed s/.*=\ //)
- OS=$(tr '\n' ' ' < /etc/SUSE-brand | sed s/VERSION.*//)
-elif [ -f /etc/SUSE-release ]; then
- VER=$(tr '\n' ' ' < /etc/SUSE-release | sed s/.*=\ //)
- OS=$(tr '\n' ' ' < /etc/SUSE-release | sed s/VERSION.*//)
-elif [ -f /etc/redhat-release ]; then
- # Older Red Hat, CentOS, etc.
- echo "Unsupported old release!"
-else
- OS=$(uname -s)
- VER=$(uname -r)
-fi
-OS_MAJOR=$(echo "$VER" | cut -d. -f1)
-export OS_MAJOR
-OS_MINOR=$(echo "$VER" | cut -d. -f2)
-export OS_MINOR
-OS_REVISION=$(echo "$EVR" | cut -d. -f3)
-export OS_REVISION
-
-if [[ "$OSTYPE" =~ .*linux.* ]]; then
- LINUX=true
-else
- LINUX=false
-fi
-
-if [[ "$OS" = "Darwin" ]]; then
- . "${script_directory}/darwin.sh"
-else
- . "${script_directory}/linux.sh"
- if [[ "$OS" = Deb* ]]; then
- . "${script_directory}/debian.sh"
- elif [[ "$OS" = Ubuntu* || "$OS" = Rasp* || "$OS" = Pop* ]]; then
- . "${script_directory}/aptitude.sh"
- elif [[ "$OS" = *SUSE* ]]; then
- . "${script_directory}/suse.sh"
- elif [[ "$OS" = *SLE* ]]; then
- if [[ "$VER" = 11* ]]; then
- echo "Please install SLES11 manually...exiting"
- exit
- else
- . "${script_directory}/suse.sh"
- fi
- elif [[ "$OS" = Red* ]]; then
- . "${script_directory}/rheldistro.sh"
- elif [[ "$OS" = Amazon* || "$OS" = Alma* || "$OS" = Rocky* || "$OS" = CentOS* ]]; then
- . "${script_directory}/centos.sh"
- elif [[ "$OS" = Fedora* ]]; then
- . "${script_directory}/fedora.sh"
- elif [[ "$OS" = Arch* || "$OS" = Manjaro* ]]; then
- . "${script_directory}/arch.sh"
- fi
-fi
-
-### Verify the compiler version
-COMPILER_VERSION="0.0.0"
-COMPILER_COMMAND="${CXX:-g++}"
-
-if [ -z "$(command -v "$COMPILER_COMMAND")" ]; then
- echo "Couldn't find compiler, attempting to install GCC"
- bootstrap_compiler
-fi
-if [ -x "$(command -v "${COMPILER_COMMAND}")" ]; then
- COMPILER_VERSION=$(${COMPILER_COMMAND} -dumpversion)
-else
- echo "Couldn't find compiler, please install one, or set CXX appropriately" 1>&2
- exit 1
-fi
-
-COMPILER_MAJOR=$(echo "$COMPILER_VERSION" | cut -d. -f1)
-export COMPILER_MAJOR
-COMPILER_MINOR=$(echo "$COMPILER_VERSION" | cut -d. -f2)
-export COMPILER_MINOR
-COMPILER_REVISION=$(echo "$COMPILER_VERSION" | cut -d. -f3)
-export COMPILER_REVISION
-
-### verify the cmake version
-CMAKE_COMMAND=""
-if [ -x "$(command -v cmake3)" ]; then
- CMAKE_COMMAND="cmake3"
-elif [ -x "$(command -v cmake)" ]; then
- CMAKE_COMMAND="cmake"
-fi
-
-if [ -n "${CMAKE_COMMAND}" ]; then
- get_cmake_version
-fi
-
-if [ -z "${CMAKE_COMMAND}" ] ||
- version_is_less_than "$CMAKE_MAJOR" "$CMAKE_MINOR" "$CMAKE_REVISION" "$CMAKE_GLOBAL_MIN_VERSION_MAJOR" "$CMAKE_GLOBAL_MIN_VERSION_MINOR" "$CMAKE_GLOBAL_MIN_VERSION_REVISION"; then
- echo "CMake is not installed or too old, attempting to install it..."
- bootstrap_cmake
- if [ -x "$(command -v cmake3)" ]; then
- CMAKE_COMMAND="cmake3"
- elif [ -x "$(command -v cmake)" ]; then
- CMAKE_COMMAND="cmake"
- fi
-
- get_cmake_version
-fi
-
-# RHEL8: If cmake3 is too old, try cmake
-if [ "$CMAKE_COMMAND" = "cmake3" ] &&
- version_is_less_than "$CMAKE_MAJOR" "$CMAKE_MINOR" "$CMAKE_REVISION" "$CMAKE_GLOBAL_MIN_VERSION_MAJOR" "$CMAKE_GLOBAL_MIN_VERSION_MINOR" "$CMAKE_GLOBAL_MIN_VERSION_REVISION" &&
- [ -x "$(command -v cmake)" ]; then
- CMAKE_COMMAND="cmake"
- get_cmake_version
-fi
-
-if version_is_less_than "$CMAKE_MAJOR" "$CMAKE_MINOR" "$CMAKE_REVISION" "$CMAKE_GLOBAL_MIN_VERSION_MAJOR" "$CMAKE_GLOBAL_MIN_VERSION_MINOR" "$CMAKE_GLOBAL_MIN_VERSION_REVISION"; then
- echo "Failed to install or update CMake, exiting..."
- exit
-fi
-
-
-add_cmake_option PORTABLE_BUILD ${TRUE}
-add_cmake_option DEBUG_SYMBOLS ${FALSE}
-add_cmake_option BUILD_ROCKSDB ${TRUE}
-## uses the source from the third party directory
-add_option ROCKSDB_ENABLED ${TRUE} "ENABLE_ROCKSDB"
-
-# third party directory
-add_option LIBARCHIVE_ENABLED ${TRUE} "ENABLE_LIBARCHIVE"
-add_dependency LIBARCHIVE_ENABLED "libarchive"
-
-add_option PYTHON_SCRIPTING_ENABLED ${TRUE} "ENABLE_PYTHON_SCRIPTING"
-add_dependency PYTHON_SCRIPTING_ENABLED "python"
-add_option LUA_SCRIPTING_ENABLED ${TRUE} "ENABLE_LUA_SCRIPTING"
-add_dependency LUA_SCRIPTING_ENABLED "lua"
-
-add_option EXPRESSION_LANGUAGE_ENABLED ${TRUE} "ENABLE_EXPRESSION_LANGUAGE"
-add_dependency EXPRESSION_LANGUAGE_ENABLED "bison"
-add_dependency EXPRESSION_LANGUAGE_ENABLED "flex"
-
-add_option AWS_ENABLED ${TRUE} "ENABLE_AWS"
-
-add_option KAFKA_ENABLED ${TRUE} "ENABLE_KAFKA"
-
-add_option KUBERNETES_ENABLED ${TRUE} "ENABLE_KUBERNETES"
-
-add_option MQTT_ENABLED ${TRUE} "ENABLE_MQTT"
-
-add_option OPENCV_ENABLED ${FALSE} "ENABLE_OPENCV"
-
-add_option SFTP_ENABLED ${FALSE} "ENABLE_SFTP"
-add_dependency SFTP_ENABLED "libssh2"
-
-add_option SQL_ENABLED ${TRUE} "ENABLE_SQL"
-
-# Since the following extensions have limitations on
-add_option BUSTACHE_ENABLED ${FALSE} "ENABLE_BUSTACHE" "2.6" ${TRUE}
-
-add_option OPC_ENABLED ${TRUE} "ENABLE_OPC"
-add_dependency OPC_ENABLED "mbedtls"
-
-add_option AZURE_ENABLED ${TRUE} "ENABLE_AZURE"
-
-if $LINUX; then
- add_option SYSTEMD_ENABLED ${TRUE} "ENABLE_SYSTEMD"
-fi
-
-add_option SPLUNK_ENABLED ${TRUE} "ENABLE_SPLUNK"
-
-add_option GCP_ENABLED ${TRUE} "ENABLE_GCP"
-
-add_option ELASTIC_ENABLED ${TRUE} "ENABLE_ELASTICSEARCH"
-
-add_option GRAFANA_LOKI_ENABLED ${FALSE} "ENABLE_GRAFANA_LOKI"
-
-add_option PROCFS_ENABLED ${TRUE} "ENABLE_PROCFS"
-
-add_option PROMETHEUS_ENABLED ${TRUE} "ENABLE_PROMETHEUS"
-
-add_option COUCHBASE_ENABLED ${FALSE} "ENABLE_COUCHBASE"
-
-add_option LLAMACPP_ENABLED ${FALSE} "ENABLE_LLAMACPP"
-
-USE_SHARED_LIBS=${TRUE}
-ASAN_ENABLED=${FALSE}
-MINIFI_FAIL_ON_WARNINGS=${FALSE}
-TESTS_ENABLED=${TRUE}
-LTO_ENABLED=${FALSE}
-
-## name, default, values
-add_multi_option BUILD_PROFILE "RelWithDebInfo" "RelWithDebInfo" "Debug" "MinSizeRel" "Release"
-
-if [ "$GUIDED_INSTALL" == "${TRUE}" ]; then
- EnableAllFeatures
- ALL_FEATURES_ENABLED=${TRUE}
-fi
-
-BUILD_DIR_D=${BUILD_DIR}
-OVERRIDE_BUILD_IDENTIFIER=${BUILD_IDENTIFIER}
-
-load_state
-
-if [ "$USER_DISABLE_TESTS" == "${TRUE}" ]; then
- ToggleFeature TESTS_ENABLED
-fi
-
-
-if [ "${OVERRIDE_BUILD_IDENTIFIER}" != "${BUILD_IDENTIFIER}" ]; then
- BUILD_IDENTIFIER=${OVERRIDE_BUILD_IDENTIFIER}
-fi
-
-if [ "$BUILD_DIR_D" != "build" ] && [ "$BUILD_DIR_D" != "$BUILD_DIR" ]; then
- echo -n "Build dir will override stored state, $BUILD_DIR. Press any key to continue "
- read -r overwrite
- BUILD_DIR=$BUILD_DIR_D
-
-fi
-
-if [ ! -d "${BUILD_DIR}" ]; then
- mkdir "${BUILD_DIR}/"
-else
-
- overwrite="Y"
- if [ "$NO_PROMPT" = "false" ] && [ "$FEATURES_SELECTED" = "false" ]; then
- echo "CMAKE Build dir (${BUILD_DIR}) exists, should we overwrite your build directory before we begin?"
- echo -n "If you have already bootstrapped, bootstrapping again isn't necessary to run make [ Y/N ] "
- read -r overwrite
- fi
- if [ "$overwrite" = "N" ] || [ "$overwrite" = "n" ]; then
- echo "Exiting ...."
- exit
- else
- rm "${BUILD_DIR}/CMakeCache.txt" > /dev/null 2>&1
- fi
-fi
-
-## change to the directory
-pushd "${BUILD_DIR}" || exit 1
-
-while [ ! "$FEATURES_SELECTED" == "true" ]
-do
- if [ "$MENU" == "main" ]; then
- show_main_menu
- read_main_menu_options
- elif [ "$MENU" == "advanced" ]; then
- show_advanced_features_menu
- read_advanced_menu_options
- else
- show_supported_features
- read_feature_options
- fi
-done
-
-### ensure we have all dependencies
-save_state
-build_deps
-
-
-## just in case
-CMAKE_VERSION=$(${CMAKE_COMMAND} --version | head -n 1 | awk '{print $3}')
-
-CMAKE_MAJOR=$(echo "$CMAKE_VERSION" | cut -d. -f1)
-CMAKE_MINOR=$(echo "$CMAKE_VERSION" | cut -d. -f2)
-CMAKE_REVISION=$(echo "$CMAKE_VERSION" | cut -d. -f3)
-
-
-CMAKE_BUILD_COMMAND="${CMAKE_COMMAND} "
-
-if [ "${USE_NINJA}" = "${TRUE}" ]; then
- echo "use ninja"
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DFORCE_COLORED_OUTPUT=ON -GNinja "
-fi
-
-build_cmake_command(){
- for option in "${OPTIONS[@]}" ; do
- for cmake_opt in "${CMAKE_OPTIONS[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND="1"
- FOUND_VALUE="$VALUE"
- fi
- done
- if [ "$FOUND" = "1" ]; then
- set_value=OFF
- option_value="${!option}"
- if { [[ "$option_value" = "${FALSE}" ]] && [[ "$FOUND_VALUE" == "DISABLE"* ]]; } || \
- { [[ "$option_value" = "${TRUE}" ]] && [[ "$FOUND_VALUE" == "ENABLE"* ]]; } || \
- { [[ "$option_value" = "${TRUE}" ]] && [[ "$FOUND_VALUE" != "ENABLE"* ]] && [[ "$FOUND_VALUE" != "DISABLE"* ]]; }; then
- set_value=ON
- fi
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -D${FOUND_VALUE}=${set_value}"
- fi
- done
-
- if [ "${DEBUG_SYMBOLS}" = "${TRUE}" ]; then
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DCMAKE_BUILD_TYPE=RelWithDebInfo"
- fi
-
- if [ "${TESTS_ENABLED}" = "${TRUE}" ]; then
- # user may have disabled tests previously, so let's force them to be re-enabled
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DSKIP_TESTS= "
- else
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DSKIP_TESTS=true "
- fi
-
- if [ "${ASAN_ENABLED}" = "${TRUE}" ]; then
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DMINIFI_ADVANCED_ASAN_BUILD=ON "
- else
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DMINIFI_ADVANCED_ASAN_BUILD=OFF"
- fi
-
- if [ "${USE_SHARED_LIBS}" = "${TRUE}" ]; then
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DUSE_SHARED_LIBS=ON "
- else
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DUSE_SHARED_LIBS= "
- fi
-
-
-
- if [ "${PORTABLE_BUILD}" = "${TRUE}" ]; then
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DPORTABLE=ON "
- else
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DPORTABLE=OFF "
- fi
-
- if [ "${BUILD_ROCKSDB}" = "${TRUE}" ]; then
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DBUILD_ROCKSDB=ON "
- else
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DBUILD_ROCKSDB= "
- fi
-
- if [ "${MINIFI_FAIL_ON_WARNINGS}" = "${TRUE}" ]; then
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DMINIFI_FAIL_ON_WARNINGS=ON "
- else
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DMINIFI_FAIL_ON_WARNINGS=OFF"
- fi
-
- if [ "${LTO_ENABLED}" = "${TRUE}" ]; then
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DMINIFI_ADVANCED_LINK_TIME_OPTIMIZATION=ON "
- else
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DMINIFI_ADVANCED_LINK_TIME_OPTIMIZATION=OFF"
- fi
-
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DBUILD_IDENTIFIER=${BUILD_IDENTIFIER}"
-
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} -DCMAKE_BUILD_TYPE=${BUILD_PROFILE}"
-
- add_os_flags
-
- CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND} .."
-
- continue_with_plan="Y"
- if [ ! "$NO_PROMPT" = "true" ]; then
- echo -n "Command will be '${CMAKE_BUILD_COMMAND}', run this? [ Y/N ] "
- read -r continue_with_plan
- fi
- if [ "$continue_with_plan" = "N" ] || [ "$continue_with_plan" = "n" ]; then
- echo "Exiting ...."
- exit
- fi
-}
-
-
-build_cmake_command
-
-### run the cmake command
-if [ "${SKIP_CMAKE}" = "${TRUE}" ]; then
- echo "Not running ${CMAKE_BUILD_COMMAND} "
-else
- ${CMAKE_BUILD_COMMAND}
-fi
-
-if [ "$BUILD" = "true" ]; then
- make -j"${CORES}"
-fi
-
-if [ "$PACKAGE" = "true" ]; then
- make package
-fi
-
-
-popd || exit 2
-
-# vim: shiftwidth=2 tabstop=2 expandtab
diff --git a/bstrp_functions.sh b/bstrp_functions.sh
deleted file mode 100755
index 4783a8d27..000000000
--- a/bstrp_functions.sh
+++ /dev/null
@@ -1,474 +0,0 @@
-#!/usr/bin/env bash
-# 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.
-
-script_directory="$(cd "$(dirname "$0")" && pwd)"
-
-get_cmake_version(){
- CMAKE_VERSION=$(${CMAKE_COMMAND} --version | head -n 1 | awk '{print $3}')
-
- CMAKE_MAJOR=$(echo "$CMAKE_VERSION" | cut -d. -f1)
- CMAKE_MINOR=$(echo "$CMAKE_VERSION" | cut -d. -f2)
- CMAKE_REVISION=$(echo "$CMAKE_VERSION" | cut -d. -f3)
-}
-
-# Checks if a version is smaller than another
-version_is_less_than() {
- # Parameters:
- local lhs_major=$1
- local lhs_minor=$2
- local lhs_patch=$3
- local rhs_major=$4
- local rhs_minor=$5
- local rhs_patch=$6
- # Return: true (0) if left hand side (lhs) is smaller than right hand side (rhs), otherwise return false
- if [ "$lhs_major" -lt "$rhs_major" ]; then return 0; fi
- if [ "$lhs_minor" -lt "$rhs_minor" ]; then return 0; fi
- if [ "$lhs_patch" -lt "$rhs_patch" ]; then return 0; fi
-
- # otherwise return
- false
-}
-
-add_cmake_option(){
- eval "$1=$2"
-}
-
-add_option(){
- BOOTSTRAP_OPTION_NAME="$1"
- DEFAULT_VALUE="$2"
- CMAKE_OPTION_NAME="$3"
- eval "$BOOTSTRAP_OPTION_NAME=$DEFAULT_VALUE"
- OPTIONS+=("$BOOTSTRAP_OPTION_NAME")
- CMAKE_OPTIONS+=("$BOOTSTRAP_OPTION_NAME:$CMAKE_OPTION_NAME")
- if [ -n "$4" ]; then
- CMAKE_MIN_VERSION+=("$BOOTSTRAP_OPTION_NAME:$4")
- fi
-
- if [ -n "$5" ]; then
- if [ "$5" = "true" ]; then
- DEPLOY_LIMITS+=("$BOOTSTRAP_OPTION_NAME")
- fi
- fi
-}
-
-add_multi_option(){
- eval "$1=$2"
- ARRAY=()
- eval "export $1_OPTIONS=()"
- for i in "${@:3}"; do
- ARRAY+=("$i")
- done
- for i in "${!ARRAY[@]}"; do
- eval "$1_OPTIONS[$i]=${ARRAY[$i]}"
- done
-}
-
-set_dependency(){
- DEPENDS_ON+=("$1:$2")
-}
-
-set_incompatible_with(){
- INCOMPATIBLE_WITH+=("$1:$2")
- INCOMPATIBLE_WITH+=("$2:$1")
-}
-
-print_multi_option_status(){
- feature_status=${!1}
- declare -a VAR_OPTS=()
-
- declare VAR_OPTS=("$1_OPTIONS[@]")
- VAR_OPTS=("$1_OPTIONS[@]")
-
- for option in "${!VAR_OPTS}" ; do
- if [ "${option}" = "$feature_status" ]; then
- printf "%b%s%b " "${RED}" "${option}" "${NO_COLOR}"
- else
- printf "%s " "${option}"
- fi
- done
-}
-
-ToggleMultiOption(){
- feature_status=${!1}
- declare -a VAR_OPTS=()
-
- declare VAR_OPTS=("$1_OPTIONS[@]")
- #echo -e "${RED}${feature_status}${NO_COLOR} (${VAR_OPTS_VAL})"
- VAR_OPTS=("$1_OPTIONS[@]")
- invariant=""
- first=""
- # the alternative is to loop through an array but since we're an indirected
- # copy, we'll treat this as a manual circular buffer
- for option in "${!VAR_OPTS}" ; do
- if [ -z "${first}" ]; then
- first=${option}
- fi
- if [ "${invariant}" = "next" ]; then
- eval "$1=${option}"
- invariant=""
- break
- fi
- if [ "${option}" = "$feature_status" ]; then
- invariant="next"
- fi
- done
- if [ "${invariant}" = "next" ]; then
- eval "$1=${first}"
- fi
-}
-
-
-
-add_dependency(){
- DEPENDENCIES+=("$1:$2")
-}
-
-### parse the command line arguments
-
-
-EnableAllFeatures(){
- for option in "${OPTIONS[@]}" ; do
- feature_status=${!option}
- if [ "$feature_status" = "${FALSE}" ]; then
- ToggleFeature "${option}"
- fi
- # eval "$option=${TRUE}"
- done
-}
-
-pause(){
- echo -n "Press [Enter] key to continue..."
- read -r _
-}
-
-
-load_state(){
- if [ -f "${script_directory}/bt_state" ]; then
- . "${script_directory}/bt_state"
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "${option_value}" = "${FALSE}" ]; then
- ALL_FEATURES_ENABLED=${FALSE}
- fi
- done
- fi
-}
-
-echo_state_variable(){
- VARIABLE_VALUE=${!1}
- echo "$1=\"${VARIABLE_VALUE}\"" >> "${script_directory}/bt_state"
-}
-
-save_state(){
- echo "VERSION=1" > "${script_directory}/bt_state"
- echo_state_variable BUILD_IDENTIFIER
- echo_state_variable BUILD_DIR
- echo_state_variable TESTS_ENABLED
- echo_state_variable BUILD_PROFILE
- echo_state_variable USE_SHARED_LIBS
- echo_state_variable ASAN_ENABLED
- echo_state_variable MINIFI_FAIL_ON_WARNINGS
- echo_state_variable LTO_ENABLED
- for option in "${OPTIONS[@]}" ; do
- echo_state_variable "${option}"
- done
-}
-
-check_compatibility(){
- for option in "${INCOMPATIBLE_WITH[@]}" ; do
- OPT=${option%%:*}
- if [ "$OPT" = "$1" ]; then
- OTHER_FEATURE=${option#*:}
- OTHER_FEATURE_VALUE=${!OTHER_FEATURE}
- if [ "${OTHER_FEATURE_VALUE}" = "Enabled" ]; then
- echo "false"
- return
- fi
- fi
- done
- for option in "${DEPENDS_ON[@]}" ; do
- OPT=${option%%:*}
- if [ "$OPT" = "$1" ]; then
- OTHER_FEATURE=${option#*:}
- OTHER_FEATURE_VALUE=${!OTHER_FEATURE}
- if [ "${OTHER_FEATURE_VALUE}" != "Enabled" ]; then
- echo "false"
- return
- fi
- fi
- done
- echo "true"
-}
-
-verify_enable(){
- COMPATIBLE=$(check_compatibility "$1")
- if [ "$COMPATIBLE" = "true" ]; then
- verify_enable_platform "$1"
- else
- echo "false"
- fi
-}
-
-can_deploy(){
- for option in "${DEPLOY_LIMITS[@]}" ; do
- OPT=${option%%:*}
- if [ "${OPT}" = "$1" ]; then
- echo "false"
- fi
- done
- echo "true"
-}
-
-ToggleFeature(){
- VARIABLE_VALUE=${!1}
- ALL_FEATURES_ENABLED="Disabled"
- if [ "${VARIABLE_VALUE}" = "Enabled" ]; then
- eval "$1=${FALSE}"
- for option in "${DEPENDS_ON[@]}" ; do
- DEPENDENT_FEATURE=${option%%:*}
- FEATURE=${option#*:}
- if [ "$FEATURE" = "$1" ]; then
- eval "$DEPENDENT_FEATURE=${FALSE}"
- fi
- done
- else
- for option in "${CMAKE_MIN_VERSION[@]}" ; do
- OPT=${option%%:*}
- if [ "$OPT" = "$1" ]; then
- NEEDED_VER=${option#*:}
- NEEDED_MAJOR=$(echo "$NEEDED_VER" | cut -d. -f1)
- NEEDED_MINOR=$(echo "$NEEDED_VER" | cut -d. -f2)
- NEEDED_REVISION=$(echo "$NEEDED_VERSION" | cut -d. -f3)
- if (( NEEDED_MAJOR > CMAKE_MAJOR )); then
- return 1
- fi
-
- if (( NEEDED_MINOR > CMAKE_MINOR )); then
- return 1
- fi
-
- if (( NEEDED_REVISION > CMAKE_REVISION )); then
- return 1
- fi
- fi
- done
- CAN_ENABLE=$(verify_enable "$1")
- CAN_DEPLOY=$(can_deploy "$1")
- if [ "$CAN_ENABLE" = "true" ]; then
- if [[ "$DEPLOY" = "true" && "$CAN_DEPLOY" = "true" ]] || [[ "$DEPLOY" = "false" ]]; then
- eval "$1=${TRUE}"
- fi
- fi
- fi
-}
-
-
-print_feature_status(){
- feature_status=${!1}
- if [ "$feature_status" = "Enabled" ]; then
- echo "Enabled"
- else
- for option in "${CMAKE_MIN_VERSION[@]}" ; do
- OPT=${option%%:*}
- if [ "${OPT}" = "$1" ]; then
- NEEDED_VER=${option#*:}
- NEEDED_MAJOR=$(echo "$NEEDED_VER" | cut -d. -f1)
- NEEDED_MINOR=$(echo "$NEEDED_VER" | cut -d. -f2)
- NEEDED_REVISION=$(echo "$NEEDED_VERSION" | cut -d. -f3)
- if (( NEEDED_MAJOR > CMAKE_MAJOR )); then
- echo -e "${RED}Disabled*${NO_COLOR}"
- return 1
- fi
-
- if (( NEEDED_MINOR > CMAKE_MINOR )); then
- echo -e "${RED}Disabled*${NO_COLOR}"
- return 1
- fi
-
- if (( NEEDED_REVISION > CMAKE_REVISION )); then
- echo -e "${RED}Disabled*${NO_COLOR}"
- return 1
- fi
- fi
- done
- CAN_ENABLE=$(verify_enable "$1")
- if [ "$CAN_ENABLE" = "true" ]; then
- echo -e "${RED}Disabled${NO_COLOR}"
- else
- echo -e "${RED}Disabled*${NO_COLOR}"
- fi
-
- fi
-}
-
-
-
-show_main_menu() {
- clear
- echo "****************************************"
- echo " MiNiFi C++ Main Menu."
- echo "****************************************"
- echo "A. Select MiNiFi C++ Features "
- if [ "$ALL_FEATURES_ENABLED" = "${TRUE}" ]; then
- echo " All features enabled ........$(print_feature_status ALL_FEATURES_ENABLED)"
- fi
- echo "B. Select Advanced Features "
- echo "C. Continue with selected options "
- echo -e "Q. Exit\r\n"
-}
-
-read_main_menu_options(){
- local choice
- echo -n "Enter choice [ A-C ] "
- read -r choice
- choice=$(echo "${choice}" | tr '[:upper:]' '[:lower:]')
- case $choice in
- a) MENU="features" ;;
- b) MENU="advanced" ;;
- c) FEATURES_SELECTED="true" ;;
- q) exit 0;;
- *) echo -e "${RED}Please enter a valid option...${NO_COLOR}" && sleep 1
- esac
-}
-
-show_advanced_features_menu() {
- clear
- echo "****************************************"
- echo " MiNiFi C++ Advanced Features."
- echo "****************************************"
- echo "A. Portable Build ..............$(print_feature_status PORTABLE_BUILD)"
- echo "B. Build with Debug symbols ....$(print_feature_status DEBUG_SYMBOLS)"
- echo "C. Build RocksDB from source ...$(print_feature_status BUILD_ROCKSDB)"
- echo -e "R. Return to Main Menu\r\n"
-}
-
-read_advanced_menu_options(){
- local choice
- echo -n "Enter choice [ A-C ] "
- read -r choice
- choice=$(echo "${choice}" | tr '[:upper:]' '[:lower:]')
- case $choice in
- a) ToggleFeature PORTABLE_BUILD ;;
- b) ToggleFeature DEBUG_SYMBOLS ;;
- c) ToggleFeature BUILD_ROCKSDB ;;
- r) MENU="main" ;;
- *) echo -e "${RED}Please enter a valid option...${NO_COLOR}" && sleep 1
- esac
-}
-
-
-
-show_supported_features() {
- clear
- echo "****************************************"
- echo " Select MiNiFi C++ Features to toggle."
- echo "****************************************"
- echo "A. Persistent Repositories .....$(print_feature_status ROCKSDB_ENABLED)"
- echo "C. libarchive features .........$(print_feature_status LIBARCHIVE_ENABLED)"
- echo "D. Python Scripting support ....$(print_feature_status PYTHON_SCRIPTING_ENABLED)"
- echo "E. Expression Language support .$(print_feature_status EXPRESSION_LANGUAGE_ENABLED)"
- echo "F. Kafka support ...............$(print_feature_status KAFKA_ENABLED)"
- echo "K. Bustache Support ............$(print_feature_status BUSTACHE_ENABLED)"
- echo "L. Lua Scripting Support .......$(print_feature_status LUA_SCRIPTING_ENABLED)"
- echo "M. MQTT Support ................$(print_feature_status MQTT_ENABLED)"
- echo "O. SFTP Support ................$(print_feature_status SFTP_ENABLED)"
- echo "S. AWS Support .................$(print_feature_status AWS_ENABLED)"
- echo "T. OpenCV Support ..............$(print_feature_status OPENCV_ENABLED)"
- echo "U. OPC-UA Support...............$(print_feature_status OPC_ENABLED)"
- echo "V. SQL Support..................$(print_feature_status SQL_ENABLED)"
- echo "X. Azure Support ...............$(print_feature_status AZURE_ENABLED)"
- if $LINUX; then
- echo "Y. Systemd Support .............$(print_feature_status SYSTEMD_ENABLED)"
- fi
- echo "AA. Splunk Support .............$(print_feature_status SPLUNK_ENABLED)"
- echo "AB. Kubernetes Support .........$(print_feature_status KUBERNETES_ENABLED)"
- echo "AC. Google Cloud Support .......$(print_feature_status GCP_ENABLED)"
- echo "AD. ProcFs Support .............$(print_feature_status PROCFS_ENABLED)"
- echo "AE. Prometheus Support .........$(print_feature_status PROMETHEUS_ENABLED)"
- echo "AF. Elasticsearch Support ......$(print_feature_status ELASTIC_ENABLED)"
- echo "AG. Grafana Loki Support .......$(print_feature_status GRAFANA_LOKI_ENABLED)"
- echo "AH. Couchbase Support ..........$(print_feature_status COUCHBASE_ENABLED)"
- echo "AI. llama.cpp Support ..........$(print_feature_status LLAMACPP_ENABLED)"
- echo "****************************************"
- echo " Build Options."
- echo "****************************************"
- echo "1. Enable Tests ................$(print_feature_status TESTS_ENABLED)"
- echo "2. Enable all extensions"
- echo "4. Use Shared Dependency Links ...$(print_feature_status USE_SHARED_LIBS)"
- echo "5. Build Profile .................$(print_multi_option_status BUILD_PROFILE)"
- echo "6. Create ASAN build .............$(print_feature_status ASAN_ENABLED)"
- echo "7. Treat warnings as errors.......$(print_feature_status MINIFI_FAIL_ON_WARNINGS)"
- echo "8. Enable link time optimization .$(print_feature_status LTO_ENABLED)"
- echo "P. Continue with these options"
- if [ "$GUIDED_INSTALL" = "${TRUE}" ]; then
- echo "R. Return to Main Menu"
- fi
- echo "Q. Quit"
- echo "* Extension cannot be installed due to"
- echo " version of cmake or other software, or"
- echo -e " incompatibility with other extensions\r\n"
-}
-
-read_feature_options(){
- local choice
- echo -n "Enter choice [A-Z or AA-AF or 1-7] "
- read -r choice
- choice=$(echo "${choice}" | tr '[:upper:]' '[:lower:]')
- case $choice in
- a) ToggleFeature ROCKSDB_ENABLED ;;
- c) ToggleFeature LIBARCHIVE_ENABLED ;;
- d) ToggleFeature PYTHON_SCRIPTING_ENABLED ;;
- e) ToggleFeature EXPRESSION_LANGUAGE_ENABLED ;;
- f) ToggleFeature KAFKA_ENABLED ;;
- k) ToggleFeature BUSTACHE_ENABLED ;;
- l) ToggleFeature LUA_SCRIPTING_ENABLED ;;
- m) ToggleFeature MQTT_ENABLED ;;
- o) ToggleFeature SFTP_ENABLED ;;
- s) ToggleFeature AWS_ENABLED ;;
- t) ToggleFeature OPENCV_ENABLED ;;
- u) ToggleFeature OPC_ENABLED ;;
- v) ToggleFeature SQL_ENABLED ;;
- x) ToggleFeature AZURE_ENABLED ;;
- y) if $LINUX; then ToggleFeature SYSTEMD_ENABLED; fi ;;
- aa) ToggleFeature SPLUNK_ENABLED ;;
- ab) ToggleFeature KUBERNETES_ENABLED ;;
- ac) ToggleFeature GCP_ENABLED ;;
- ad) ToggleFeature PROCFS_ENABLED ;;
- ae) ToggleFeature PROMETHEUS_ENABLED ;;
- af) ToggleFeature ELASTIC_ENABLED ;;
- ag) ToggleFeature GRAFANA_LOKI_ENABLED ;;
- ah) ToggleFeature COUCHBASE_ENABLED ;;
- ai) ToggleFeature LLAMACPP_ENABLED ;;
- 1) ToggleFeature TESTS_ENABLED ;;
- 2) EnableAllFeatures ;;
- 4) ToggleFeature USE_SHARED_LIBS;;
- 5) ToggleMultiOption BUILD_PROFILE;;
- 6) ToggleFeature ASAN_ENABLED;;
- 7) ToggleFeature MINIFI_FAIL_ON_WARNINGS;;
- 8) ToggleFeature LTO_ENABLED;;
- p) export FEATURES_SELECTED="true" ;;
- r) if [ "$GUIDED_INSTALL" = "${TRUE}" ]; then
- export MENU="main"
- fi
- ;;
- q) exit 0;;
- *) echo -e "${RED}Please enter an option A-Z or AA-AF or 1-7...${NO_COLOR}" && sleep 2
- esac
-}
-
-# vim: shiftwidth=2 tabstop=2 expandtab
diff --git a/centos.sh b/centos.sh
deleted file mode 100644
index e7610881b..000000000
--- a/centos.sh
+++ /dev/null
@@ -1,99 +0,0 @@
-#!/bin/bash
-# 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.
-
-get_toolset_name() {
- case "$OS_MAJOR" in
- 7) TOOLSET_NAME=devtoolset-11 ;;
- 8) TOOLSET_NAME=gcc-toolset-12 ;;
- 9) TOOLSET_NAME=gcc-toolset-12 ;;
- esac
-}
-
-install_pkgs() {
- if [ "$OS_MAJOR" -gt 7 ]; then
- sudo dnf -y install "$@"
- else
- ulimit -n 1024000 && sudo yum -y install "$@"
- fi
-}
-
-verify_enable_platform() {
- feature="$1"
- verify_gcc_enable "$feature"
-}
-
-add_os_flags() {
- get_toolset_name
- source "/opt/rh/$TOOLSET_NAME/enable"
-}
-install_bison() {
- INSTALLED+=("bison")
-}
-
-bootstrap_cmake(){
- install_cmake_from_binary
-}
-
-bootstrap_compiler() {
- get_toolset_name
- if [ -n "$TOOLSET_NAME" ]; then
- install_pkgs centos-release-scl
- install_pkgs "$TOOLSET_NAME"
- fi
- source "/opt/rh/$TOOLSET_NAME/enable"
-}
-
-build_deps() {
- COMMAND="install_pkgs libuuid libuuid-devel libtool patch epel-release perl"
- INSTALLED=()
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "$option_value" = "${TRUE}" ]; then
- # option is enabled
- FOUND_VALUE=""
- for cmake_opt in "${DEPENDENCIES[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND_VALUE="$VALUE"
- if [ "$FOUND_VALUE" = "bison" ]; then
- install_bison
- elif [ "$FOUND_VALUE" = "flex" ]; then
- INSTALLED+=("flex")
- elif [ "$FOUND_VALUE" = "automake" ]; then
- INSTALLED+=("automake")
- elif [ "$FOUND_VALUE" = "python" ]; then
- INSTALLED+=("python36-devel")
- elif [ "$FOUND_VALUE" = "libarchive" ]; then
- INSTALLED+=("xz-devel")
- INSTALLED+=("bzip2-devel")
- elif [ "$FOUND_VALUE" = "libssh2" ]; then
- INSTALLED+=("libssh2-devel")
- fi
- fi
- done
-
- fi
- done
- INSTALLED+=("autoconf")
- for option in "${INSTALLED[@]}" ; do
- COMMAND="${COMMAND} $option"
- done
-
- ${COMMAND}
-}
diff --git a/conanfile.py b/conanfile.py
index 6939c6eb5..318a9f941 100644
--- a/conanfile.py
+++ b/conanfile.py
@@ -9,7 +9,7 @@ required_conan_version = ">=2.0"
shared_requires = ("openssl/3.2.1", "libcurl/8.4.0", "civetweb/1.16", "libxml2/2.12.6", "fmt/10.2.1", "spdlog/1.14.0", "catch2/3.5.4", "zlib/1.2.11", "zstd/1.5.2", "bzip2/1.0.8", "rocksdb/8.10.2@minifi/develop")
-shared_sources = ("CMakeLists.txt", "libminifi/*", "extensions/*", "minifi_main/*", "nanofi/*", "bin/*", "bootstrap/*", "cmake/*", "conf/*", "controller/*", "encrypt-config/*", "etc/*", "examples/*", "packaging/msi/*", "thirdparty/*", "docker/*", "LICENSE", "NOTICE", "README.md", "C2.md", "CONFIGURE.md", "CONTRIBUTING.md", "CONTROLLERS.md", "EXPRESSIONS.md", "Extensions.md", "JNI.md", "METRICS.md", "OPS.md", "PROCESSORS.md", "ThirdParties.md", "Windows.md", "aptitude.sh", "arch.sh", "boo [...]
+shared_sources = ("CMakeLists.txt", "libminifi/*", "extensions/*", "minifi_main/*", "nanofi/*", "bin/*", "bootstrap/*", "cmake/*", "conf/*", "controller/*", "encrypt-config/*", "etc/*", "examples/*", "packaging/msi/*", "thirdparty/*", "docker/*", "LICENSE", "NOTICE", "README.md", "C2.md", "CONFIGURE.md", "CONTRIBUTING.md", "CONTROLLERS.md", "EXPRESSIONS.md", "Extensions.md", "JNI.md", "METRICS.md", "OPS.md", "PROCESSORS.md", "ThirdParties.md", "Windows.md", "CPPLINT.cfg", "generateVersio [...]
class MiNiFiCppMain(ConanFile):
diff --git a/darwin.sh b/darwin.sh
deleted file mode 100644
index 946a2e260..000000000
--- a/darwin.sh
+++ /dev/null
@@ -1,109 +0,0 @@
-#!/bin/bash
-# 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.
-
-verify_enable_platform() {
- feature="$1"
- if [ "$feature" = "BUSTACHE_ENABLED" ]; then
- BUSTACHE_MAX="9"
- ## we should check the xcode version
- CLANG_VERSION=$(clang --version | head -n 1 | awk '{print $4}')
- CLANG_MAJOR=$(echo "$CLANG_VERSION" | cut -d. -f1)
- if [ "$CLANG_MAJOR" -ge "$BUSTACHE_MAX" ]; then
- echo "false"
- else
- echo "true"
- fi
- else
- echo "true"
- fi
-}
-
-add_os_flags(){
- :
-}
-
-install_bison() {
- BISON_INSTALLED="false"
- if [ -x "$(command -v bison)" ]; then
- BISON_VERSION=$(bison --version | head -n 1 | awk '{print $4}')
- BISON_MAJOR=$(echo "$BISON_VERSION" | cut -d. -f1)
- if (( BISON_MAJOR >= 3 )); then
- BISON_INSTALLED="true"
- fi
- fi
- if [ "$BISON_INSTALLED" = "false" ]; then
- wget https://ftp.gnu.org/gnu/bison/bison-3.0.5.tar.xz
- tar xvf bison-3.0.5.tar.xz
- pushd bison-3.0.5 || exit 1
- ./configure
- make
- sudo make install
- popd || exit 2
- fi
-
-}
-
-bootstrap_cmake(){
- brew install cmake
-}
-bootstrap_compiler() {
- :
-}
-build_deps(){
-
- COMMAND="brew install cmake perl bzip2"
- INSTALLED=()
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "$option_value" = "${TRUE}" ]; then
- # option is enabled
- FOUND_VALUE=""
- for cmake_opt in "${DEPENDENCIES[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND_VALUE="$VALUE"
- if [ "$FOUND_VALUE" = "bison" ]; then
- install_bison
- elif [ "$FOUND_VALUE" = "flex" ]; then
- INSTALLED+=("flex")
- elif [ "$FOUND_VALUE" = "python" ]; then
- INSTALLED+=("python")
- elif [ "$FOUND_VALUE" = "libtool" ]; then
- INSTALLED+=("libtool")
- elif [ "$FOUND_VALUE" = "automake" ]; then
- INSTALLED+=("automake")
- INSTALLED+=("autoconf")
- elif [ "$FOUND_VALUE" = "libarchive" ]; then
- INSTALLED+=("bzip2")
- elif [ "$FOUND_VALUE" = "libssh2" ]; then
- INSTALLED+=("libssh2")
- fi
- fi
- done
-
- fi
- done
-
- for option in "${INSTALLED[@]}" ; do
- COMMAND="${COMMAND} $option"
- done
-
- echo "Ensuring you have all dependencies installed..."
- ${COMMAND} > /dev/null 2>&1
-}
diff --git a/debian.sh b/debian.sh
deleted file mode 100644
index 612106eaf..000000000
--- a/debian.sh
+++ /dev/null
@@ -1,90 +0,0 @@
-#!/bin/bash
-# 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.
-
-verify_enable_platform(){
- feature="$1"
- verify_gcc_enable "$feature"
-}
-add_os_flags() {
- #CMAKE_BUILD_COMMAND="${CMAKE_BUILD_COMMAND}"
- :
-}
-bootstrap_cmake(){
- if [ "$VERSION_CODENAME" = buster ]; then
- sudo bash -c 'source /etc/os-release; grep "$VERSION_CODENAME-backports" /etc/apt/sources.list &>/dev/null || echo "deb http://deb.debian.org/debian $VERSION_CODENAME-backports main" >> /etc/apt/sources.list'
- sudo apt-get -y update
- sudo apt-get -t buster-backports install -y cmake
- else
- sudo apt-get -y update
- sudo apt-get install -y cmake
- fi
-}
-bootstrap_compiler(){
- sudo apt-get -y install build-essential
-}
-build_deps(){
- sudo apt-get -y update
- RETVAL=$?
- if [ "$RETVAL" -ne "0" ]; then
- sudo apt-get install -y libssl-dev > /dev/null
- fi
- COMMAND="sudo apt-get -y install gcc g++ zlib1g-dev uuid uuid-dev perl libbz2-dev"
- export DEBIAN_FRONTEND=noninteractive
- INSTALLED=()
- sudo apt-get -y update
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "$option_value" = "${TRUE}" ]; then
- # option is enabled
- FOUND_VALUE=""
- for cmake_opt in "${DEPENDENCIES[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND_VALUE="$VALUE"
- if [ "$FOUND_VALUE" = "bison" ]; then
- INSTALLED+=("bison")
- elif [ "$FOUND_VALUE" = "flex" ]; then
- INSTALLED+=("flex")
- elif [ "$FOUND_VALUE" = "libtool" ]; then
- INSTALLED+=("libtool")
- elif [ "$FOUND_VALUE" = "python" ]; then
- INSTALLED+=("libpython3-dev")
- elif [ "$FOUND_VALUE" = "automake" ]; then
- INSTALLED+=("automake")
- elif [ "$FOUND_VALUE" = "libarchive" ]; then
- INSTALLED+=("liblzma-dev")
- elif [ "$FOUND_VALUE" = "libssh2" ]; then
- INSTALLED+=("libssh2-1-dev")
- fi
- fi
- done
-
- fi
- done
-
- INSTALLED+=("autoconf")
-
- for option in "${INSTALLED[@]}" ; do
- COMMAND="${COMMAND} $option"
- done
-
- echo "Ensuring you have all dependencies installed..."
- ${COMMAND}
-
-}
diff --git a/deploy.sh b/deploy.sh
deleted file mode 100755
index f1df2ffc2..000000000
--- a/deploy.sh
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/bin/bash
-# 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.
-
-
-build_identifier=$1
-
-echo "${build_identifier}" > build_identifier
-
-./bootstrap.sh -d -p --build_identifier="${build_identifier}"
-
-pushd build || exit 1
-./controller/minifi-controller --manifest >> build_output
-popd || exit 2
diff --git a/fedora.sh b/fedora.sh
deleted file mode 100644
index 455aabf42..000000000
--- a/fedora.sh
+++ /dev/null
@@ -1,83 +0,0 @@
-#!/bin/bash
-# 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.
-
-verify_enable_platform(){
- feature="$1"
- verify_gcc_enable "$feature"
-}
-add_os_flags() {
- :
-}
-bootstrap_cmake(){
- sudo yum -y install wget
- wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
- sudo yum -y install epel-release-latest-7.noarch.rpm
- sudo yum -y install cmake3
-}
-bootstrap_compiler() {
- sudo yum -y install gcc gcc-c++
-}
-build_deps(){
- # Install epel-release so that cmake3 will be available for installation
- sudo yum -y install wget
- wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
- sudo yum -y install epel-release-latest-7.noarch.rpm
-
- COMMAND="sudo yum -y install libuuid libuuid-devel patch perl bzip2-devel"
- INSTALLED=()
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "$option_value" = "${TRUE}" ]; then
- # option is enabled
- FOUND_VALUE=""
- for cmake_opt in "${DEPENDENCIES[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND_VALUE="$VALUE"
- echo "$FOUND_VALUE"
- if [ "$FOUND_VALUE" = "bison" ]; then
- INSTALLED+=("bison")
- elif [ "$FOUND_VALUE" = "flex" ]; then
- INSTALLED+=("flex")
- elif [ "$FOUND_VALUE" = "python" ]; then
- INSTALLED+=("python3-devel")
- elif [ "$FOUND_VALUE" = "libtool" ]; then
- INSTALLED+=("libtool")
- elif [ "$FOUND_VALUE" = "autoconf" ]; then
- INSTALLED+=("autoconf")
- elif [ "$FOUND_VALUE" = "automake" ]; then
- INSTALLED+=("automake")
- elif [ "$FOUND_VALUE" = "libarchive" ]; then
- INSTALLED+=("xz-devel")
- elif [ "$FOUND_VALUE" = "libssh2" ]; then
- INSTALLED+=("libssh2-devel")
- fi
- fi
- done
-
- fi
- done
-
- for option in "${INSTALLED[@]}" ; do
- COMMAND="${COMMAND} $option"
- done
- echo "Installing ${COMMAND}"
- ${COMMAND}
-
-}
diff --git a/linux.sh b/linux.sh
deleted file mode 100644
index 88f81ae1f..000000000
--- a/linux.sh
+++ /dev/null
@@ -1,60 +0,0 @@
-#!/bin/bash
-# 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.
-verify_gcc_enable(){
- #feature="$1"
- [ "$COMPILER_MAJOR" -ge 11 ] && echo true || echo false
-}
-
-install_cmake_from_binary() {
- CMAKE_VERSION="3.24.4"
- arch=$(uname -m)
- if [ "$arch" = "x86_64" ]; then
- CMAKE_URL="https://cmake.org/files/v3.24/cmake-3.24.4-linux-x86_64.tar.gz"
- EXPECTED_SHA256="cac77d28fb8668c179ac02c283b058aeb846fe2133a57d40b503711281ed9f19"
- elif [ "$arch" = "aarch64" ]; then
- CMAKE_URL="https://cmake.org/files/v3.24/cmake-3.24.4-linux-aarch64.tar.gz"
- EXPECTED_SHA256="86f823f2636bf715af89da10e04daa476755a799d451baee66247846e95d7bee"
- else
- echo "Unknown architecture: $arch"
- exit 1
- fi
-
- TMP_DIR=$(mktemp -d)
-
- install_pkgs wget
- wget -P "$TMP_DIR" "$CMAKE_URL"
-
- ACTUAL_SHA256=$(sha256sum "$TMP_DIR/cmake-$CMAKE_VERSION-linux-$arch.tar.gz" | cut -d " " -f 1)
-
- if [ "$ACTUAL_SHA256" != "$EXPECTED_SHA256" ]; then
- echo "ERROR: SHA-256 verification failed. Aborting."
- rm -r "$TMP_DIR"
- exit 1
- fi
-
- echo "Installing CMake $CMAKE_VERSION to /opt/cmake-$CMAKE_VERSION..."
- set -x
- tar -C "$TMP_DIR" -zxf "$TMP_DIR/cmake-$CMAKE_VERSION-linux-$arch.tar.gz"
- sudo mv "$TMP_DIR/cmake-$CMAKE_VERSION-linux-$arch" /opt/cmake-$CMAKE_VERSION
-
- sudo ln -s "/opt/cmake-$CMAKE_VERSION/bin/cmake" /usr/local/bin/cmake
- set +x
-
- echo "CMake $CMAKE_VERSION has been installed successfully."
- rm -r "$TMP_DIR"
-}
diff --git a/rheldistro.sh b/rheldistro.sh
deleted file mode 100644
index 4cc2d4ff5..000000000
--- a/rheldistro.sh
+++ /dev/null
@@ -1,91 +0,0 @@
-#!/bin/bash
-# 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.
-
-verify_enable_platform() {
- feature="$1"
- verify_gcc_enable "$feature"
-}
-
-add_os_flags() {
- :
-}
-install_bison() {
- INSTALLED+=("bison")
-}
-
-bootstrap_cmake(){
- if [ "$OS_MAJOR" -lt 8 ]; then
- sudo yum -y install wget patch
- wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
- sudo yum -y install epel-release-latest-7.noarch.rpm
- sudo yum -y install cmake3
- else
- sudo dnf -y install cmake
- fi
-}
-bootstrap_compiler() {
- sudo yum -y install gcc gcc-c++
-}
-build_deps(){
-# Install epel-release so that cmake3 will be available for installation
- sudo yum -y install wget
- wget "https://dl.fedoraproject.org/pub/epel/epel-release-latest-${OS_MAJOR}.noarch.rpm"
- sudo yum -y install "epel-release-latest-${OS_MAJOR}.noarch.rpm"
-
- COMMAND="sudo yum install libuuid libuuid-devel perl bzip2-devel"
- INSTALLED=()
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "$option_value" = "${TRUE}" ]; then
- # option is enabled
- FOUND_VALUE=""
- for cmake_opt in "${DEPENDENCIES[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND_VALUE="$VALUE"
- if [ "$FOUND_VALUE" = "bison" ]; then
- install_bison
- elif [ "$FOUND_VALUE" = "flex" ]; then
- INSTALLED+=("flex")
- elif [ "$FOUND_VALUE" = "automake" ]; then
- INSTALLED+=("automake")
- elif [ "$FOUND_VALUE" = "autoconf" ]; then
- INSTALLED+=("autoconf")
- elif [ "$FOUND_VALUE" = "libtool" ]; then
- INSTALLED+=("libtool")
- elif [ "$FOUND_VALUE" = "python" ]; then
- INSTALLED+=("python3-devel")
- elif [ "$FOUND_VALUE" = "libarchive" ]; then
- INSTALLED+=("xz-devel")
- elif [ "$FOUND_VALUE" = "libssh2" ]; then
- INSTALLED+=("libssh2-devel")
- fi
- fi
- done
-
- fi
- done
-
- for option in "${INSTALLED[@]}" ; do
- COMMAND="${COMMAND} $option"
- done
-
- ${COMMAND}
-
-}
diff --git a/suse.sh b/suse.sh
deleted file mode 100644
index c484681e9..000000000
--- a/suse.sh
+++ /dev/null
@@ -1,96 +0,0 @@
-#!/bin/bash
-# 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.
-
-verify_enable_platform() {
- feature="$1"
- verify_gcc_enable "${feature}"
-}
-
-add_os_flags() {
- :
-}
-install_bison() {
- BISON_INSTALLED="false"
- if [ -x "$(command -v bison)" ]; then
- BISON_VERSION=$(bison --version | head -n 1 | awk '{print $4}')
- BISON_MAJOR=$(echo "${BISON_VERSION}" | cut -d. -f1)
- if (( BISON_MAJOR >= 3 )); then
- BISON_INSTALLED="true"
- fi
- fi
- if [ "$BISON_INSTALLED" = "false" ]; then
- wget https://ftp.gnu.org/gnu/bison/bison-3.0.4.tar.xz
- tar xvf bison-3.0.4.tar.xz
- pushd bison-3.0.4 || exit 1
- ./configure
- make
- sudo make install
- popd || exit 2
- fi
-}
-
-bootstrap_cmake(){
- sudo zypper in -y cmake
-}
-bootstrap_compiler() {
- sudo zypper in -y gcc gcc-c++
-}
-build_deps(){
- # Install epel-release so that cmake3 will be available for installation
- COMMAND="sudo zypper in -y libuuid1 libuuid-devel perl libbz2-devel"
- INSTALLED=()
- for option in "${OPTIONS[@]}" ; do
- option_value="${!option}"
- if [ "$option_value" = "${TRUE}" ]; then
- # option is enabled
- FOUND_VALUE=""
- for cmake_opt in "${DEPENDENCIES[@]}" ; do
- KEY=${cmake_opt%%:*}
- VALUE=${cmake_opt#*:}
- if [ "$KEY" = "$option" ]; then
- FOUND_VALUE="$VALUE"
- if [ "$FOUND_VALUE" = "bison" ]; then
- install_bison
- elif [ "$FOUND_VALUE" = "flex" ]; then
- INSTALLED+=("flex")
- elif [ "$FOUND_VALUE" = "automake" ]; then
- INSTALLED+=("automake")
- elif [ "$FOUND_VALUE" = "autoconf" ]; then
- INSTALLED+=("autoconf")
- elif [ "$FOUND_VALUE" = "libtool" ]; then
- INSTALLED+=("libtool")
- elif [ "$FOUND_VALUE" = "python" ]; then
- INSTALLED+=("python3-devel")
- elif [ "$FOUND_VALUE" = "libarchive" ]; then
- INSTALLED+=("xz-devel")
- elif [ "$FOUND_VALUE" = "libssh2" ]; then
- INSTALLED+=("libssh2-devel")
- fi
- fi
- done
-
- fi
- done
-
- for option in "${INSTALLED[@]}" ; do
- COMMAND="${COMMAND} $option"
- done
-
- ${COMMAND}
-
-}
(nifi-minifi-cpp) 02/04: MINIFICPP-2629 Clean up minifi-api includes
Posted by sz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
szaszm pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/nifi-minifi-cpp.git
commit cd4729197b95b54b25cf13e005e85b5d88f4a31f
Author: Gabor Gyimesi <ga...@gmail.com>
AuthorDate: Fri Oct 17 17:14:51 2025 +0200
MINIFICPP-2629 Clean up minifi-api includes
- Remove duplicate header files with the same content
- Remove proxy header files in core/extension-framework that only include minifi-api headers
- Include only the minifi-api headers when implementation is not used
- Additionally fix clang-tidy issues in these files
Closes #2029
Signed-off-by: Marton Szasz <sz...@apache.org>
---
.clang-tidy | 2 +-
cmake/Extensions.cmake | 2 +-
controller/Controller.cpp | 2 +-
controller/MiNiFiController.cpp | 6 +-
controller/tests/ControllerTests.cpp | 1 -
core-framework/include/Exception.h | 21 -----
core-framework/include/SwapManager.h | 21 -----
core-framework/include/agent/agent_version.h | 19 -----
core-framework/include/core/Annotation.h | 20 -----
.../include/core/BufferedContentSession.h | 2 +-
core-framework/include/core/ClassLoader.h | 1 -
.../include/core/ConfigurableComponentImpl.h | 2 +-
core-framework/include/core/Connectable.h | 2 +-
core-framework/include/core/ContentRepository.h | 2 +-
core-framework/include/core/ContentSession.h | 5 +-
.../include/core/OutputAttributeDefinition.h | 20 -----
core-framework/include/core/ProcessContext.h | 3 +-
.../include/core/ProcessContextBuilder.h | 3 +-
core-framework/include/core/ProcessorImpl.h | 7 +-
core-framework/include/core/Property.h | 25 ------
core-framework/include/core/PropertyDefinition.h | 20 -----
.../include/core/PropertyDefinitionBuilder.h | 2 +-
.../include/core/RelationshipDefinition.h | 20 -----
core-framework/include/core/Repository.h | 8 +-
core-framework/include/core/Resource.h | 1 +
core-framework/include/core/StreamManager.h | 4 +-
core-framework/include/core/TypedValues.h | 6 +-
core-framework/include/core/logging/Logger.h | 20 -----
.../include/core/state/MetricsPublisher.h | 2 +-
core-framework/include/http/BaseHTTPClient.h | 2 +-
core-framework/include/http/HTTPClient.h | 2 +-
core-framework/include/io/ArchiveStream.h | 20 -----
core-framework/include/io/BufferStream.h | 2 +-
core-framework/include/io/CRCStream.h | 2 +-
core-framework/include/io/StreamPipe.h | 4 +-
core-framework/include/io/ZlibStream.h | 2 +-
core-framework/include/utils/AutoPersistor.h | 2 +-
core-framework/include/utils/ByteArrayCallback.h | 4 +-
core-framework/include/utils/Cron.h | 2 +-
core-framework/include/utils/Export.h | 35 --------
core-framework/include/utils/FileMutex.h | 2 +-
core-framework/include/utils/GeneralUtils.h | 2 +-
core-framework/include/utils/IntervalSwitch.h | 2 +-
.../utils/LineByLineInputOutputStreamCallback.h | 6 +-
core-framework/include/utils/Literals.h | 19 -----
core-framework/include/utils/OptionalUtils.h | 2 +-
core-framework/include/utils/ParsingUtils.h | 4 +-
core-framework/include/utils/PropertyExceptions.h | 19 -----
core-framework/include/utils/StringUtils.h | 2 +-
core-framework/include/utils/ThreadPool.h | 2 +-
core-framework/include/utils/ValueParser.h | 2 +-
.../include/utils/crypto/EncryptionManager.h | 2 +-
.../include/utils/crypto/EncryptionProvider.h | 2 +-
.../include/utils/crypto/ciphers/Aes256Ecb.h | 4 +-
core-framework/include/utils/file/FileUtils.h | 2 +-
core-framework/include/utils/gsl.h | 21 -----
.../include/utils/net/NetworkInterfaceInfo.h | 2 +-
core-framework/src/core/BufferedContentSession.cpp | 6 +-
core-framework/src/core/ContentSession.cpp | 1 -
core-framework/src/core/ProcessorImpl.cpp | 5 +-
core-framework/src/core/ProcessorMetrics.cpp | 2 +-
core-framework/src/core/Property.cpp | 4 +-
core-framework/src/core/TypedValues.cpp | 2 +-
core-framework/src/http/HTTPClient.cpp | 4 +-
core-framework/src/http/HTTPStream.cpp | 2 +-
core-framework/src/io/BufferStream.cpp | 2 +-
core-framework/src/io/FileStream.cpp | 10 +--
core-framework/src/io/InputStream.cpp | 2 +-
core-framework/src/io/OutputStream.cpp | 2 +-
core-framework/src/io/ZlibStream.cpp | 4 +-
core-framework/src/utils/ByteArrayCallback.cpp | 8 +-
.../src/utils/CallBackTimer.cpp | 0
core-framework/src/utils/Environment.cpp | 2 +-
core-framework/src/utils/Error.cpp | 2 +-
core-framework/src/utils/FileMutex.cpp | 2 +-
core-framework/src/utils/Id.cpp | 6 +-
.../utils/LineByLineInputOutputStreamCallback.cpp | 2 +-
core-framework/src/utils/OsUtils.cpp | 10 +--
core-framework/src/utils/RegexUtils.cpp | 2 +-
core-framework/src/utils/StoppableThread.cpp | 2 +-
core-framework/src/utils/SystemCpuUsageTracker.cpp | 5 +-
core-framework/src/utils/file/FileUtils.cpp | 2 +-
core-framework/src/utils/file/PathUtils.cpp | 2 +-
core-framework/src/utils/net/DNS.cpp | 2 +-
core-framework/src/utils/net/Socket.cpp | 2 +-
encrypt-config/EncryptConfig.cpp | 1 -
encrypt-config/EncryptConfigMain.cpp | 2 +-
encrypt-config/tests/ConfigFileTests.cpp | 2 +-
extension-framework/include/FlowFileRecord.h | 21 -----
extension-framework/include/ResourceClaim.h | 21 -----
.../include/controllers/SSLContextService.h | 19 -----
.../controllers/SSLContextServiceInterface.h | 19 -----
.../controllers/keyvalue/KeyValueStateManager.h | 2 +-
.../include/core/AbstractProcessor.h | 2 +-
extension-framework/include/core/FlowFile.h | 20 -----
extension-framework/include/core/FlowFileStore.h | 2 +-
extension-framework/include/core/StateStorage.h | 2 +-
extension-framework/include/properties/Configure.h | 19 -----
.../include/properties/Properties.h | 19 -----
.../include/serialization/PayloadSerializer.h | 2 +-
.../include/utils/ListingStateManager.h | 4 +-
.../include/utils/ProcessorConfigUtils.h | 2 +-
extension-framework/include/utils/ResourceQueue.h | 2 +-
.../include/utils/file/FileReaderCallback.h | 2 +-
extension-framework/include/utils/net/Server.h | 2 +-
extension-framework/include/utils/net/Ssl.h | 6 +-
extension-framework/include/utils/net/UdpServer.h | 2 +-
.../controllers/keyvalue/KeyValueStateStorage.cpp | 4 +-
extension-framework/src/core/ProcessContext.cpp | 22 ------
.../src/serialization/FlowFileV3Serializer.cpp | 6 +-
.../src/utils/ListingStateManager.cpp | 6 +-
extension-framework/src/utils/net/Ssl.cpp | 2 +-
extensions/aws/AWSCredentialsProvider.cpp | 2 +-
extensions/aws/AWSCredentialsProvider.h | 2 +-
.../aws/controllerservices/AWSCredentialsService.h | 2 +-
extensions/aws/processors/AwsProcessor.cpp | 4 +-
extensions/aws/processors/AwsProcessor.h | 2 +-
extensions/aws/processors/DeleteS3Object.cpp | 2 +-
extensions/aws/processors/DeleteS3Object.h | 2 +-
extensions/aws/processors/FetchS3Object.cpp | 2 +-
extensions/aws/processors/FetchS3Object.h | 2 +-
extensions/aws/processors/ListS3.cpp | 2 +-
extensions/aws/processors/ListS3.h | 2 +-
extensions/aws/processors/PutKinesisStream.cpp | 2 +-
extensions/aws/processors/PutS3Object.cpp | 8 +-
extensions/aws/processors/PutS3Object.h | 4 +-
extensions/aws/processors/S3Processor.cpp | 3 +-
extensions/aws/processors/S3Processor.h | 6 +-
extensions/aws/s3/MultipartUploadStateStorage.cpp | 2 +-
extensions/aws/s3/MultipartUploadStateStorage.h | 6 +-
extensions/aws/s3/S3RequestSender.h | 2 +-
extensions/aws/s3/S3Wrapper.cpp | 2 +-
extensions/aws/s3/S3Wrapper.h | 10 +--
extensions/aws/tests/AWSCredentialsServiceTest.cpp | 2 +-
extensions/aws/utils/AWSSdkLogger.cpp | 2 +-
extensions/aws/utils/AWSSdkLogger.h | 2 +-
.../AzureStorageCredentialsService.h | 4 +-
.../processors/AzureBlobStorageProcessorBase.cpp | 2 +-
.../processors/AzureBlobStorageProcessorBase.h | 6 +-
.../AzureBlobStorageSingleBlobProcessorBase.cpp | 2 +-
.../AzureBlobStorageSingleBlobProcessorBase.h | 2 +-
.../AzureDataLakeStorageFileProcessorBase.h | 2 +-
.../processors/AzureDataLakeStorageProcessorBase.h | 6 +-
.../azure/processors/AzureStorageProcessorBase.cpp | 2 +-
.../azure/processors/AzureStorageProcessorBase.h | 6 +-
.../azure/processors/DeleteAzureBlobStorage.h | 4 +-
.../processors/DeleteAzureDataLakeStorage.cpp | 2 +-
.../azure/processors/FetchAzureBlobStorage.h | 4 +-
.../azure/processors/FetchAzureDataLakeStorage.cpp | 8 +-
.../azure/processors/FetchAzureDataLakeStorage.h | 2 +-
extensions/azure/processors/ListAzureBlobStorage.h | 4 +-
.../azure/processors/PutAzureBlobStorage.cpp | 2 +-
extensions/azure/processors/PutAzureBlobStorage.h | 6 +-
.../azure/processors/PutAzureDataLakeStorage.cpp | 2 +-
.../azure/processors/PutAzureDataLakeStorage.h | 4 +-
extensions/azure/storage/AzureBlobStorage.h | 6 +-
.../azure/storage/AzureBlobStorageClient.cpp | 1 +
extensions/azure/storage/AzureBlobStorageClient.h | 2 +-
extensions/azure/storage/AzureDataLakeStorage.cpp | 2 +-
extensions/azure/storage/AzureDataLakeStorage.h | 4 +-
.../azure/storage/AzureDataLakeStorageClient.h | 3 +-
extensions/azure/storage/BlobStorageClient.h | 4 +-
extensions/azure/storage/DataLakeStorageClient.h | 4 +-
extensions/azure/utils/AzureSdkLogger.h | 2 +-
extensions/bustache/ApplyTemplate.cpp | 2 +-
extensions/bustache/tests/ApplyTemplateTests.cpp | 2 +-
extensions/civetweb/processors/ListenHTTP.cpp | 5 +-
extensions/civetweb/processors/ListenHTTP.h | 11 +--
.../civetweb/tests/HttpPostIntegrationTest.cpp | 2 +-
.../controllerservices/CouchbaseClusterService.cpp | 1 +
.../controllerservices/CouchbaseClusterService.h | 6 +-
.../couchbase/processors/GetCouchbaseKey.cpp | 2 +-
.../couchbase/processors/PutCouchbaseKey.cpp | 2 +-
.../ElasticsearchCredentialsControllerService.h | 2 +-
extensions/elasticsearch/PostElasticsearch.cpp | 2 +-
extensions/elasticsearch/PostElasticsearch.h | 6 +-
extensions/elasticsearch/tests/MockElastic.h | 2 +-
.../elasticsearch/tests/PostElasticsearchTests.cpp | 2 +-
extensions/execute-process/ExecuteProcess.cpp | 6 +-
extensions/execute-process/ExecuteProcess.h | 6 +-
.../impl/expression/Expression.h | 2 +-
.../tests/ExpressionLanguageTests.cpp | 4 +-
.../tests/ProcessContextExprTests.cpp | 6 +-
extensions/gcp/GCPAttributes.h | 2 +-
.../GCPCredentialsControllerService.h | 4 +-
extensions/gcp/processors/DeleteGCSObject.cpp | 4 +-
extensions/gcp/processors/DeleteGCSObject.h | 4 +-
extensions/gcp/processors/FetchGCSObject.cpp | 4 +-
extensions/gcp/processors/FetchGCSObject.h | 4 +-
extensions/gcp/processors/GCSProcessor.cpp | 2 +-
extensions/gcp/processors/GCSProcessor.h | 4 +-
extensions/gcp/processors/ListGCSBucket.cpp | 4 +-
extensions/gcp/processors/ListGCSBucket.h | 6 +-
extensions/gcp/processors/PutGCSObject.cpp | 4 +-
extensions/gcp/processors/PutGCSObject.h | 4 +-
.../tests/GCPCredentialsControllerServiceTests.cpp | 6 +-
extensions/grafana-loki/PushGrafanaLoki.cpp | 2 +-
extensions/grafana-loki/PushGrafanaLoki.h | 8 +-
extensions/grafana-loki/PushGrafanaLokiGrpc.h | 1 -
.../grafana-loki/tests/MockGrafanaLokiREST.h | 2 +-
extensions/kafka/ConsumeKafka.cpp | 4 +-
extensions/kafka/ConsumeKafka.h | 4 +-
extensions/kafka/KafkaConnection.cpp | 2 +-
extensions/kafka/KafkaConnection.h | 4 +-
extensions/kafka/KafkaProcessorBase.cpp | 2 +-
extensions/kafka/KafkaProcessorBase.h | 2 +-
extensions/kafka/PublishKafka.cpp | 10 +--
extensions/kafka/PublishKafka.h | 10 +--
extensions/kafka/rdkafka_utils.cpp | 2 +-
extensions/kubernetes/ApiClient.h | 2 +-
.../KubernetesControllerService.cpp | 4 +-
.../KubernetesControllerService.h | 4 +-
.../processors/CollectKubernetesPodMetrics.cpp | 2 +-
.../processors/CollectKubernetesPodMetrics.h | 2 +-
extensions/libarchive/ArchiveMetadata.cpp | 4 +-
extensions/libarchive/BinFiles.cpp | 2 +-
extensions/libarchive/BinFiles.h | 8 +-
extensions/libarchive/CompressContent.cpp | 2 +-
extensions/libarchive/CompressContent.h | 8 +-
extensions/libarchive/FocusArchiveEntry.cpp | 7 +-
extensions/libarchive/FocusArchiveEntry.h | 8 +-
extensions/libarchive/ManipulateArchive.cpp | 6 +-
extensions/libarchive/ManipulateArchive.h | 8 +-
extensions/libarchive/MergeContent.cpp | 2 +-
extensions/libarchive/MergeContent.h | 4 +-
extensions/libarchive/ReadArchiveStream.h | 3 +-
extensions/libarchive/UnfocusArchiveEntry.cpp | 4 +-
extensions/libarchive/UnfocusArchiveEntry.h | 4 +-
extensions/libarchive/WriteArchiveStream.h | 2 +-
.../libarchive/tests/CompressContentTests.cpp | 6 +-
.../libarchive/tests/ManipulateArchiveTests.cpp | 2 +-
extensions/libarchive/tests/MergeFileTests.cpp | 12 +--
extensions/libarchive/tests/util/ArchiveTests.cpp | 4 +-
.../llamacpp/processors/DefaultLlamaContext.cpp | 2 +-
.../llamacpp/processors/RunLlamaCppInference.cpp | 4 +-
.../llamacpp/tests/RunLlamaCppInferenceTests.cpp | 2 +-
extensions/lua/LuaInputStream.h | 2 +-
extensions/lua/LuaLogger.h | 1 -
extensions/lua/LuaOutputStream.h | 2 +-
extensions/lua/LuaScriptFlowFile.cpp | 10 +--
extensions/lua/LuaScriptFlowFile.h | 6 +-
extensions/lua/LuaScriptStateManager.h | 2 +-
.../mqtt/processors/AbstractMQTTProcessor.cpp | 2 +-
extensions/mqtt/processors/AbstractMQTTProcessor.h | 3 +-
extensions/mqtt/processors/ConsumeMQTT.cpp | 2 +-
extensions/mqtt/processors/ConsumeMQTT.h | 8 +-
extensions/mqtt/processors/PublishMQTT.cpp | 2 +-
extensions/mqtt/processors/PublishMQTT.h | 6 +-
extensions/opc/include/fetchopc.h | 10 +--
extensions/opc/include/opc.h | 6 +-
extensions/opc/include/opcbase.h | 4 +-
extensions/opc/include/putopc.h | 6 +-
extensions/opc/src/fetchopc.cpp | 2 +-
extensions/opc/src/opc.cpp | 9 +--
extensions/opc/src/opcbase.cpp | 2 +-
extensions/opc/src/putopc.cpp | 2 +-
extensions/opencv/CaptureRTSPFrame.cpp | 2 +-
extensions/opencv/CaptureRTSPFrame.h | 4 +-
extensions/opencv/MotionDetector.cpp | 2 +-
extensions/opencv/MotionDetector.h | 4 +-
extensions/pdh/PerformanceDataMonitor.cpp | 2 +-
extensions/pdh/PerformanceDataMonitor.h | 4 +-
.../pdh/tests/PerformanceDataCounterTests.cpp | 2 +-
extensions/procfs/DiskStat.cpp | 2 +-
extensions/procfs/NetDev.cpp | 2 +-
extensions/procfs/ProcFs.h | 2 +-
extensions/procfs/ProcFsSerialization.h | 2 +-
extensions/procfs/processors/ProcFsMonitor.cpp | 4 +-
extensions/procfs/processors/ProcFsMonitor.h | 6 +-
extensions/procfs/tests/MemInfoTests.cpp | 2 +-
extensions/prometheus/PrometheusExposerWrapper.h | 4 +-
extensions/prometheus/PrometheusMetricsPublisher.h | 2 +-
.../prometheus/PublishedMetricGaugeCollection.cpp | 2 +-
.../prometheus/PublishedMetricGaugeCollection.h | 4 +-
extensions/python/ExecutePythonProcessor.cpp | 2 +-
extensions/python/ExecutePythonProcessor.h | 6 +-
extensions/python/PythonDependencyInstaller.h | 4 +-
extensions/python/PythonProcessor.h | 2 +-
extensions/python/PythonScriptEngine.h | 2 +-
extensions/python/tests/PythonManifestTests.cpp | 4 +-
extensions/python/types/PyInputStream.cpp | 2 +-
extensions/python/types/PyInputStream.h | 2 +-
extensions/python/types/PyLogger.cpp | 2 +-
extensions/python/types/PyLogger.h | 2 +-
extensions/python/types/PyOutputStream.h | 2 +-
extensions/python/types/PyProcessContext.cpp | 4 +-
extensions/python/types/PyProcessContext.h | 2 +-
extensions/python/types/PyProcessSession.cpp | 2 +-
extensions/python/types/PyRecordSetReader.h | 2 +-
extensions/python/types/PyRecordSetWriter.h | 2 +-
extensions/python/types/PySSLContextService.h | 2 +-
extensions/python/types/PyScriptFlowFile.h | 2 +-
extensions/python/types/PyStateManager.h | 2 +-
extensions/python/types/Types.h | 2 +-
.../rocksdb-repos/DatabaseContentRepository.cpp | 4 +-
.../rocksdb-repos/DatabaseContentRepository.h | 4 +-
extensions/rocksdb-repos/FlowFileLoader.cpp | 4 +-
extensions/rocksdb-repos/FlowFileLoader.h | 6 +-
extensions/rocksdb-repos/FlowFileRepository.cpp | 4 +-
extensions/rocksdb-repos/FlowFileRepository.h | 2 +-
extensions/rocksdb-repos/ProvenanceRepository.h | 2 +-
extensions/rocksdb-repos/RocksDbStream.cpp | 2 +-
.../controllers/RocksDbStateStorage.h | 4 +-
extensions/rocksdb-repos/database/OpenRocksDb.h | 4 +-
extensions/rocksdb-repos/database/RocksDatabase.h | 2 +-
.../rocksdb-repos/database/RocksDbInstance.h | 2 +-
extensions/rocksdb-repos/database/RocksDbUtils.cpp | 4 +-
extensions/rocksdb-repos/database/RocksDbUtils.h | 2 +-
.../encryption/RocksDbEncryptionProvider.h | 2 +-
.../rocksdb-repos/tests/ContentSessionTests.cpp | 2 +-
.../tests/DBContentRepositoryTests.cpp | 4 +-
extensions/rocksdb-repos/tests/EncryptionTests.cpp | 1 +
extensions/rocksdb-repos/tests/ProvenanceTests.cpp | 5 +-
extensions/rocksdb-repos/tests/RepoTests.cpp | 8 +-
extensions/rocksdb-repos/tests/SwapTests.cpp | 7 +-
extensions/script/ExecuteScript.h | 4 +-
extensions/script/ScriptExecutor.h | 2 +-
extensions/sftp/client/SFTPClient.cpp | 2 +-
extensions/sftp/client/SFTPClient.h | 4 +-
extensions/sftp/processors/FetchSFTP.cpp | 4 +-
extensions/sftp/processors/FetchSFTP.h | 4 +-
extensions/sftp/processors/ListSFTP.cpp | 10 +--
extensions/sftp/processors/ListSFTP.h | 6 +-
extensions/sftp/processors/PutSFTP.cpp | 7 +-
extensions/sftp/processors/PutSFTP.h | 8 +-
extensions/sftp/processors/SFTPProcessorBase.cpp | 17 ++--
extensions/sftp/processors/SFTPProcessorBase.h | 6 +-
extensions/sftp/tests/ListSFTPTests.cpp | 2 +-
extensions/sftp/tests/ListThenFetchSFTPTests.cpp | 4 +-
extensions/sftp/tests/PutSFTPTests.cpp | 4 +-
extensions/sftp/tests/tools/SFTPTestServer.h | 2 +-
extensions/smb/FetchSmb.h | 6 +-
extensions/smb/ListSmb.h | 6 +-
extensions/smb/PutSmb.cpp | 2 +-
extensions/smb/SmbConnectionControllerService.cpp | 1 +
extensions/smb/SmbConnectionControllerService.h | 6 +-
.../utils/MockSmbConnectionControllerService.h | 1 -
extensions/splunk/PutSplunkHTTP.cpp | 2 +-
extensions/splunk/PutSplunkHTTP.h | 6 +-
extensions/splunk/QuerySplunkIndexingStatus.cpp | 2 +-
extensions/splunk/QuerySplunkIndexingStatus.h | 6 +-
extensions/splunk/SplunkHECProcessor.cpp | 2 +-
extensions/splunk/SplunkHECProcessor.h | 4 +-
extensions/splunk/tests/MockSplunkHEC.h | 2 +-
extensions/sql/data/JSONSQLWriter.cpp | 2 +-
extensions/sql/data/SQLRowsetProcessor.cpp | 21 ++---
extensions/sql/data/SociConnectors.h | 4 +-
extensions/sql/processors/ExecuteSQL.cpp | 4 +-
extensions/sql/processors/ExecuteSQL.h | 6 +-
extensions/sql/processors/FlowFileSource.h | 2 +-
extensions/sql/processors/PutSQL.cpp | 4 +-
extensions/sql/processors/PutSQL.h | 4 +-
extensions/sql/processors/QueryDatabaseTable.cpp | 6 +-
extensions/sql/processors/QueryDatabaseTable.h | 4 +-
extensions/sql/processors/SQLProcessor.cpp | 6 +-
extensions/sql/processors/SQLProcessor.h | 2 +-
extensions/sql/services/DatabaseService.cpp | 2 +-
extensions/sql/services/DatabaseService.h | 2 +-
extensions/sql/tests/FlowFileMatcher.h | 2 +-
extensions/sql/tests/SQLTestPlan.h | 2 +
.../controllers/InMemoryKeyValueStorage.h | 2 +-
.../controllers/JsonRecordSetWriter.h | 2 +-
.../controllers/PersistentMapStateStorage.h | 6 +-
.../controllers/VolatileMapStateStorage.h | 6 +-
.../standard-processors/controllers/XMLReader.cpp | 2 +-
.../standard-processors/controllers/XMLReader.h | 2 +-
.../controllers/XMLRecordSetWriter.cpp | 2 +-
.../controllers/XMLRecordSetWriter.h | 2 +-
.../standard-processors/modbus/FetchModbusTcp.cpp | 2 +-
.../standard-processors/modbus/FetchModbusTcp.h | 4 +-
.../processors/AppendHostInfo.cpp | 4 +-
.../processors/AppendHostInfo.h | 6 +-
.../processors/AttributeRollingWindow.cpp | 2 +-
.../processors/AttributeRollingWindow.h | 5 +-
.../processors/AttributesToJSON.cpp | 6 +-
.../processors/AttributesToJSON.h | 8 +-
.../standard-processors/processors/ConvertRecord.h | 2 +-
.../processors/DefragmentText.cpp | 6 +-
.../processors/DefragmentText.h | 4 +-
.../processors/EvaluateJsonPath.h | 4 +-
.../standard-processors/processors/ExtractText.cpp | 6 +-
.../standard-processors/processors/ExtractText.h | 8 +-
.../standard-processors/processors/FetchFile.h | 4 +-
.../processors/GenerateFlowFile.cpp | 2 +-
.../processors/GenerateFlowFile.h | 10 +--
.../standard-processors/processors/GetFile.cpp | 2 +-
.../standard-processors/processors/GetFile.h | 8 +-
.../standard-processors/processors/GetTCP.cpp | 4 +-
extensions/standard-processors/processors/GetTCP.h | 10 +--
.../standard-processors/processors/HashContent.cpp | 4 +-
.../standard-processors/processors/HashContent.h | 6 +-
.../standard-processors/processors/InvokeHTTP.cpp | 6 +-
.../standard-processors/processors/InvokeHTTP.h | 10 +--
.../processors/JoltTransformJSON.h | 4 +-
.../standard-processors/processors/ListFile.cpp | 2 +-
.../standard-processors/processors/ListFile.h | 6 +-
.../processors/ListenSyslog.cpp | 4 +-
.../standard-processors/processors/ListenSyslog.h | 8 +-
.../standard-processors/processors/ListenTCP.cpp | 4 +-
.../standard-processors/processors/ListenTCP.h | 8 +-
.../standard-processors/processors/ListenUDP.cpp | 2 +-
.../standard-processors/processors/ListenUDP.h | 6 +-
.../processors/LogAttribute.cpp | 2 +-
.../standard-processors/processors/LogAttribute.h | 8 +-
.../processors/NetworkListenerProcessor.h | 6 +-
.../standard-processors/processors/PutFile.cpp | 16 ++--
.../standard-processors/processors/PutFile.h | 8 +-
.../standard-processors/processors/PutTCP.cpp | 6 +-
extensions/standard-processors/processors/PutTCP.h | 10 +--
.../standard-processors/processors/PutUDP.cpp | 6 +-
extensions/standard-processors/processors/PutUDP.h | 6 +-
.../standard-processors/processors/ReplaceText.h | 12 +--
.../standard-processors/processors/RetryFlowFile.h | 10 +--
.../processors/RouteOnAttribute.h | 4 +-
.../standard-processors/processors/RouteText.cpp | 2 +-
.../standard-processors/processors/RouteText.h | 8 +-
.../processors/SegmentContent.cpp | 4 +-
.../processors/SegmentContent.h | 8 +-
.../processors/SplitContent.cpp | 6 +-
.../standard-processors/processors/SplitContent.h | 8 +-
.../standard-processors/processors/SplitJson.h | 4 +-
.../standard-processors/processors/SplitRecord.h | 14 ++--
.../standard-processors/processors/SplitText.cpp | 8 +-
.../standard-processors/processors/SplitText.h | 6 +-
.../standard-processors/processors/TailFile.cpp | 2 +-
.../standard-processors/processors/TailFile.h | 8 +-
.../processors/TextFragmentUtils.h | 2 +-
.../processors/UpdateAttribute.cpp | 2 +-
.../processors/UpdateAttribute.h | 4 +-
.../tests/integration/InvokeHTTPTests.cpp | 4 +-
.../tests/integration/ProcessGroupTest.cpp | 2 +-
.../tests/integration/VerifyInvokeHTTP.h | 2 +-
.../tests/unit/AttributeRollingWindowTests.cpp | 2 +-
.../tests/unit/ControllerServiceTests.cpp | 4 +-
.../tests/unit/ExtractTextTests.cpp | 4 +-
.../tests/unit/FetchFileTests.cpp | 2 +-
.../standard-processors/tests/unit/GetTCPTests.cpp | 2 +-
.../tests/unit/ListFileTests.cpp | 2 +-
.../tests/unit/ProcessorTests.cpp | 8 +-
.../tests/unit/PutFileTests.cpp | 4 +-
.../standard-processors/tests/unit/PutUDPTests.cpp | 2 +-
.../tests/unit/ReplaceTextTests.cpp | 1 +
.../tests/unit/RouteTextTests.cpp | 3 +-
.../tests/unit/SegmentContentTests.cpp | 2 +-
.../tests/unit/SplitContentTests.cpp | 2 +-
.../tests/unit/SplitTextTests.cpp | 2 +-
.../tests/unit/TailFileTests.cpp | 3 +-
.../tests/unit/YamlConnectionParserTest.cpp | 2 +-
extensions/standard-processors/utils/JoltUtils.cpp | 23 +++---
extensions/standard-processors/utils/JoltUtils.h | 4 +-
extensions/systemd/ConsumeJournald.cpp | 4 +-
extensions/systemd/ConsumeJournald.h | 8 +-
extensions/systemd/libwrapper/DlopenWrapper.cpp | 4 +-
extensions/systemd/libwrapper/LibWrapper.cpp | 10 +--
extensions/systemd/libwrapper/LibWrapper.h | 12 +--
extensions/systemd/tests/ConsumeJournaldTest.cpp | 4 +-
extensions/test-processors/KamikazeProcessor.cpp | 4 +-
extensions/test-processors/KamikazeProcessor.h | 4 +-
.../windows-event-log/ConsumeWindowsEventLog.cpp | 4 +-
.../windows-event-log/ConsumeWindowsEventLog.h | 10 +--
extensions/windows-event-log/TailEventLog.cpp | 4 +-
extensions/windows-event-log/TailEventLog.h | 6 +-
.../windows-event-log/tests/BookmarkTests.cpp | 2 +-
extensions/windows-event-log/tests/CWELTestUtils.h | 2 +-
extensions/windows-event-log/wel/Bookmark.h | 4 +-
extensions/windows-event-log/wel/EventPath.h | 2 +-
extensions/windows-event-log/wel/JSONUtils.cpp | 2 +-
extensions/windows-event-log/wel/MetadataWalker.h | 2 +-
.../windows-event-log/wel/WindowsEventLog.cpp | 2 +-
extensions/windows-event-log/wel/WindowsEventLog.h | 2 +-
extensions/windows-event-log/wel/XMLString.h | 2 +-
generateVersion.bat | 6 +-
generateVersion.sh | 2 +-
libminifi/include/Connection.h | 7 +-
libminifi/include/CronDrivenSchedulingAgent.h | 6 +-
libminifi/include/EventDrivenSchedulingAgent.h | 6 +-
libminifi/include/FlowController.h | 15 ++--
libminifi/include/FlowFileRecord.h | 6 +-
libminifi/include/RemoteProcessGroupPort.h | 7 +-
libminifi/include/ResourceClaim.h | 2 +-
libminifi/include/RootProcessGroupWrapper.h | 5 +-
libminifi/include/SchedulingAgent.h | 8 +-
libminifi/include/ThreadedSchedulingAgent.h | 4 +-
libminifi/include/TimerDrivenSchedulingAgent.h | 6 +-
libminifi/include/agent/build_description.h | 5 +-
libminifi/include/c2/C2Agent.h | 2 +-
libminifi/include/c2/C2MetricsPublisher.h | 6 +-
libminifi/include/c2/C2Payload.h | 2 +-
libminifi/include/c2/C2Protocol.h | 2 +-
libminifi/include/c2/C2Utils.h | 2 +-
libminifi/include/c2/ControllerSocketProtocol.h | 4 +-
libminifi/include/c2/HeartbeatLogger.h | 2 +-
libminifi/include/c2/HeartbeatReporter.h | 2 +-
libminifi/include/c2/PayloadSerializer.h | 6 +-
libminifi/include/c2/protocols/RESTProtocol.h | 2 +-
.../controllers/NetworkPrioritizerService.h | 5 +-
libminifi/include/controllers/SSLContextService.h | 4 +-
.../controllers/UpdatePolicyControllerService.h | 4 +-
libminifi/include/core/FlowConfiguration.h | 7 +-
libminifi/include/core/FlowFile.h | 8 +-
libminifi/include/core/ForwardingContentSession.h | 5 +-
libminifi/include/core/ParameterContext.h | 2 +-
libminifi/include/core/ParameterTokenParser.h | 2 +-
libminifi/include/core/ProcessGroup.h | 6 +-
libminifi/include/core/ProcessSession.h | 8 +-
.../include/core/ProcessSessionReadCallback.h | 2 +-
libminifi/include/core/Processor.h | 4 +-
libminifi/include/core/RepositoryFactory.h | 4 +-
libminifi/include/core/SerializableComponent.h | 4 +-
.../core/controller/ControllerServiceLookup.h | 21 -----
.../core/controller/ControllerServiceNode.h | 6 +-
.../core/controller/ControllerServiceNodeMap.h | 2 +-
.../core/controller/ControllerServiceProvider.h | 4 +-
.../ForwardingControllerServiceProvider.h | 2 +-
.../include/core/extension/ExtensionManager.h | 2 +-
libminifi/include/core/extension/Module.h | 6 +-
libminifi/include/core/extension/Utils.h | 2 +-
libminifi/include/core/flow/Node.h | 2 +-
.../include/core/flow/StructuredConfiguration.h | 2 +-
.../include/core/flow/StructuredConnectionParser.h | 2 +-
libminifi/include/core/json/JsonNode.h | 2 +-
libminifi/include/core/logging/LoggerBase.h | 2 +-
libminifi/include/core/logging/LoggerFactory.h | 43 ----------
.../core/logging/internal/ActiveCompressor.h | 18 +----
.../core/logging/internal/CompressionManager.h | 6 +-
.../include/core/logging/internal/LogCompressor.h | 18 +----
.../reporting/SiteToSiteProvenanceReportingTask.h | 1 -
.../include/core/repository/AtomicRepoEntries.h | 2 +-
.../repository/LegacyVolatileContentRepository.h | 3 +-
.../core/repository/VolatileFlowFileRepository.h | 3 +-
.../core/repository/VolatileProvenanceRepository.h | 1 -
.../include/core/repository/VolatileRepository.h | 2 -
libminifi/include/core/state/ConnectionStore.h | 4 +-
libminifi/include/core/state/LogMetricsPublisher.h | 4 +-
.../include/core/state/MetricsPublisherFactory.h | 2 +-
.../include/core/state/MetricsPublisherStore.h | 5 +-
libminifi/include/core/state/UpdateController.h | 19 +----
.../include/core/state/nodes/AgentInformation.h | 6 +-
.../include/core/state/nodes/AssetInformation.h | 2 +-
.../core/state/nodes/ConfigurationChecksums.h | 2 +-
.../include/core/state/nodes/DeviceInformation.h | 3 +-
.../include/core/state/nodes/FlowInformation.h | 4 +-
libminifi/include/core/state/nodes/MetricsBase.h | 2 -
libminifi/include/core/state/nodes/QueueMetrics.h | 1 -
.../include/core/state/nodes/RepositoryMetrics.h | 2 +-
.../state/nodes/RepositoryMetricsSourceStore.h | 4 +-
.../include/core/state/nodes/ResponseNodeLoader.h | 6 +-
libminifi/include/core/yaml/YamlConfiguration.h | 2 +-
libminifi/include/core/yaml/YamlNode.h | 2 +-
libminifi/include/io/AtomicEntryStream.h | 4 +-
libminifi/include/properties/Configuration.h | 2 +-
libminifi/include/properties/Properties.h | 2 +-
libminifi/include/provenance/Provenance.h | 9 +--
.../include/sitetosite/HttpSiteToSiteClient.h | 2 +-
libminifi/include/sitetosite/RawSiteToSiteClient.h | 3 +-
libminifi/include/sitetosite/SiteToSiteClient.h | 2 +-
libminifi/include/utils/FlowFileQueue.h | 3 +-
libminifi/include/utils/MinMaxHeap.h | 2 +-
libminifi/include/utils/file/AssetManager.h | 2 +-
libminifi/include/utils/tls/ExtendedKeyUsage.h | 2 +-
libminifi/src/Configure.cpp | 2 +-
libminifi/src/Connection.cpp | 2 +-
libminifi/src/CronDrivenSchedulingAgent.cpp | 4 +-
libminifi/src/DiskSpaceWatchdog.cpp | 4 +-
libminifi/src/EventDrivenSchedulingAgent.cpp | 6 +-
libminifi/src/Exception.cpp | 2 +-
libminifi/src/FlowController.cpp | 5 +-
libminifi/src/FlowFileRecord.cpp | 11 +--
libminifi/src/RemoteProcessGroupPort.cpp | 7 +-
libminifi/src/ResourceClaim.cpp | 3 +-
libminifi/src/SchedulingAgent.cpp | 2 +-
libminifi/src/ThreadedSchedulingAgent.cpp | 7 +-
libminifi/src/agent/JsonSchema.cpp | 4 +-
libminifi/src/c2/C2Agent.cpp | 12 +--
libminifi/src/c2/C2MetricsPublisher.cpp | 5 +-
.../src/c2/ControllerSocketMetricsPublisher.cpp | 2 +-
libminifi/src/c2/ControllerSocketProtocol.cpp | 2 +-
libminifi/src/c2/protocols/RESTProtocol.cpp | 2 +-
libminifi/src/core/ClassLoader.cpp | 5 +-
libminifi/src/core/FlowConfiguration.cpp | 2 +
libminifi/src/core/FlowFile.cpp | 2 +-
libminifi/src/core/ForwardingContentSession.cpp | 7 +-
libminifi/src/core/ProcessSession.cpp | 11 +--
libminifi/src/core/ProcessSessionReadCallback.cpp | 4 +-
libminifi/src/core/Processor.cpp | 6 +-
libminifi/src/core/RepositoryFactory.cpp | 2 -
.../core/controller/ControllerServiceProvider.cpp | 2 +-
libminifi/src/core/extension/DynamicLibrary.cpp | 1 -
libminifi/src/core/extension/ExtensionManager.cpp | 2 +-
libminifi/src/core/extension/Module.cpp | 2 +-
libminifi/src/core/logging/LoggerConfiguration.cpp | 2 +-
libminifi/src/core/logging/WindowsEventLogSink.cpp | 2 +-
.../core/logging/internal/CompressionManager.cpp | 4 +-
.../SiteToSiteProvenanceReportingTask.cpp | 8 +-
.../src/core/repository/VolatileRepository.cpp | 1 -
.../src/core/repository/VolatileRepositoryData.cpp | 4 +-
libminifi/src/core/state/MetricsPublisherStore.cpp | 1 +
libminifi/src/core/state/UpdateController.cpp | 12 +--
libminifi/src/core/state/Value.cpp | 2 +-
.../src/core/state/nodes/AgentInformation.cpp | 2 +-
.../src/core/state/nodes/BuildInformation.cpp | 2 +-
.../src/core/state/nodes/ResponseNodeLoader.cpp | 2 +-
.../EnvironmentVariableParameterProvider.cpp | 2 +-
libminifi/src/provenance/Provenance.cpp | 8 +-
libminifi/src/sitetosite/HttpSiteToSiteClient.cpp | 2 +-
libminifi/src/sitetosite/RawSiteToSiteClient.cpp | 2 +-
libminifi/src/sitetosite/SiteToSiteClient.cpp | 3 +-
libminifi/src/utils/CallBackTimer.cpp | 92 ----------------------
libminifi/src/utils/tls/TLSUtils.cpp | 2 +-
libminifi/test/flow-tests/CustomProcessors.h | 4 +-
libminifi/test/flow-tests/FlowControllerTests.cpp | 4 +-
libminifi/test/flow-tests/SessionTests.cpp | 1 +
libminifi/test/integration/C2DebugBundleTest.cpp | 2 +-
libminifi/test/integration/C2NullConfiguration.cpp | 2 +-
.../test/integration/C2PropertiesUpdateTests.cpp | 2 +-
libminifi/test/integration/C2UpdateTest.cpp | 2 +-
.../integration/OnScheduleErrorHandlingTests.cpp | 2 +-
libminifi/test/integration/SiteToSiteRestTest.cpp | 2 +-
.../keyvalue-tests/PersistentStateStorageTest.cpp | 1 -
libminifi/test/libtest/integration/CivetStream.h | 3 +-
.../test/libtest/integration/HTTPHandlers.cpp | 2 +-
libminifi/test/libtest/integration/HTTPHandlers.h | 9 ---
.../test/libtest/integration/IntegrationBase.cpp | 1 +
libminifi/test/libtest/unit/MockClasses.h | 6 +-
libminifi/test/libtest/unit/ProvenanceTestHelper.h | 4 +-
.../libtest/unit/ReadFromFlowFileTestProcessor.cpp | 2 +-
.../libtest/unit/ReadFromFlowFileTestProcessor.h | 6 +-
libminifi/test/libtest/unit/RecordSetTesters.h | 4 +-
.../libtest/unit/SingleProcessorTestController.cpp | 5 +-
.../libtest/unit/SingleProcessorTestController.h | 4 +-
libminifi/test/libtest/unit/SiteToSiteHelper.h | 2 +-
libminifi/test/libtest/unit/StatefulProcessor.cpp | 4 +-
libminifi/test/libtest/unit/StatefulProcessor.h | 2 +-
libminifi/test/libtest/unit/TestBase.cpp | 8 +-
libminifi/test/libtest/unit/TestBase.h | 2 +-
libminifi/test/libtest/unit/TestUtils.cpp | 16 ++--
libminifi/test/libtest/unit/TestUtils.h | 1 -
.../libtest/unit/WriteToFlowFileTestProcessor.cpp | 2 +-
.../libtest/unit/WriteToFlowFileTestProcessor.h | 10 +--
.../test/persistence-tests/PersistenceTests.cpp | 3 +
libminifi/test/unit/CRCTests.cpp | 4 +-
libminifi/test/unit/ComponentManifestTests.cpp | 2 +-
.../unit/ControllerSocketMetricsPublisherTest.cpp | 2 +-
libminifi/test/unit/EnvironmentUtilsTests.cpp | 7 +-
libminifi/test/unit/ExceptionTests.cpp | 2 +-
libminifi/test/unit/ExpectedTest.cpp | 2 +-
libminifi/test/unit/ExtendedKeyUsageTests.cpp | 20 ++---
libminifi/test/unit/ExtensionVerificationTests.cpp | 2 +-
libminifi/test/unit/FileSystemRepositoryTests.cpp | 5 +-
libminifi/test/unit/FileUtilsTests.cpp | 2 +-
libminifi/test/unit/FlowFileQueueSwapTests.cpp | 20 ++---
libminifi/test/unit/FlowFileQueueTests.cpp | 1 +
libminifi/test/unit/FlowFileSerializationTests.cpp | 2 +-
libminifi/test/unit/FlowStatusBuilderTests.cpp | 2 +
libminifi/test/unit/MemoryUsageTest.cpp | 2 +-
libminifi/test/unit/MetricsPublisherStoreTests.cpp | 2 +
libminifi/test/unit/MetricsTests.cpp | 1 +
libminifi/test/unit/MinifiConcurrentQueueTests.cpp | 2 +-
.../test/unit/NetworkPrioritizerServiceTests.cpp | 2 +-
libminifi/test/unit/ProcessContextTest.cpp | 4 +-
libminifi/test/unit/ProcessorConfigUtilsTests.cpp | 5 +-
libminifi/test/unit/ResponseNodeLoaderTests.cpp | 3 +-
libminifi/test/unit/SchedulingAgentTests.cpp | 2 +
libminifi/test/unit/SiteToSiteTests.cpp | 3 +-
libminifi/test/unit/StreamTests.cpp | 2 +-
libminifi/test/unit/UpdatePolicyTests.cpp | 1 -
libminifi/test/unit/ZlibStreamTests.cpp | 2 +-
minifi-api/include/minifi-cpp/Connection.h | 7 +-
minifi-api/include/minifi-cpp/FlowFileRecord.h | 2 +-
minifi-api/include/minifi-cpp/ResourceClaim.h | 1 -
.../minifi-cpp/controllers/RecordSetReader.h | 6 +-
minifi-api/include/minifi-cpp/core/Connectable.h | 2 +-
.../include/minifi-cpp/core/ContentRepository.h | 2 +-
.../include/minifi-cpp/core/ContentSession.h | 2 +-
minifi-api/include/minifi-cpp/core/FlowFile.h | 4 +-
.../minifi-cpp/core/ProcessContextBuilder.h | 2 +-
minifi-api/include/minifi-cpp/core/ProcessorApi.h | 5 +-
minifi-api/include/minifi-cpp/core/Property.h | 2 +-
.../include/minifi-cpp/core/PropertyDefinition.h | 2 +-
minifi-api/include/minifi-cpp/core/Repository.h | 2 +-
.../minifi-cpp/core/SerializableComponent.h | 6 +-
minifi-api/include/minifi-cpp/core/StreamManager.h | 4 +-
.../core/controller/ControllerServiceNode.h | 2 +-
.../core/controller/ControllerServiceProvider.h | 2 +-
.../include/minifi-cpp/core/logging/Logger.h | 2 +-
minifi-api/include/minifi-cpp/io/ArchiveStream.h | 2 +-
minifi-api/include/minifi-cpp/io/OutputStream.h | 2 +-
minifi-api/include/minifi-cpp/io/Stream.h | 2 +-
.../include/minifi-cpp/properties/Configure.h | 2 +-
.../include/minifi-cpp/provenance/Provenance.h | 2 +-
.../include/minifi-cpp/utils/PropertyExceptions.h | 2 +-
minifi_main/AgentDocs.cpp | 2 +-
minifi_main/Fips.h | 2 +-
minifi_main/MiNiFiMain.cpp | 2 +-
minifi_main/TableFormatter.cpp | 2 +-
695 files changed, 1263 insertions(+), 1970 deletions(-)
diff --git a/.clang-tidy b/.clang-tidy
index 63fb7029d..3e7311914 100644
--- a/.clang-tidy
+++ b/.clang-tidy
@@ -1,6 +1,7 @@
Checks: >
-clang-analyzer-optin.cplusplus.VirtualCall,
-clang-analyzer-optin.core.EnumCastOutOfRange,
+ -clang-analyzer-unix.BlockInCriticalSection,
boost-use-to-string,
portability-restrict-system-includes,
portability-simd-intrinsics,
@@ -251,7 +252,6 @@ Checks: >
readability-avoid-return-with-void-value,
readability-avoid-unconditional-preprocessor-if,
readability-enum-initial-value,
- readability-math-missing-parentheses,
readability-operators-representation,
readability-redundant-casting,
readability-redundant-inline-specifier,
diff --git a/cmake/Extensions.cmake b/cmake/Extensions.cmake
index ee52f4d23..82a66e14b 100644
--- a/cmake/Extensions.cmake
+++ b/cmake/Extensions.cmake
@@ -25,7 +25,7 @@ set_property(GLOBAL PROPERTY EXTENSION-OPTIONS "")
set(extension-build-info-file "${CMAKE_CURRENT_BINARY_DIR}/ExtensionBuildInfo.cpp")
file(GENERATE OUTPUT ${extension-build-info-file}
CONTENT "\
- #include \"utils/Export.h\"\n\
+ #include \"minifi-cpp/utils/Export.h\"\n\
#ifdef BUILD_ID_VARIABLE_NAME\n\
EXTENSIONAPI extern const char* const BUILD_ID_VARIABLE_NAME = \"__EXTENSION_BUILD_IDENTIFIER_BEGIN__${BUILD_IDENTIFIER}__EXTENSION_BUILD_IDENTIFIER_END__\";\n\
#else\n\
diff --git a/controller/Controller.cpp b/controller/Controller.cpp
index 93b7b5fd7..293979ad7 100644
--- a/controller/Controller.cpp
+++ b/controller/Controller.cpp
@@ -25,7 +25,7 @@
#include "asio/ssl/context.hpp"
#include "asio/ssl/stream.hpp"
#include "asio/connect.hpp"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "utils/ConfigurationUtils.h"
#include "utils/net/AsioSocketUtils.h"
#include "utils/file/FileUtils.h"
diff --git a/controller/MiNiFiController.cpp b/controller/MiNiFiController.cpp
index 619415c25..64e94fef2 100644
--- a/controller/MiNiFiController.cpp
+++ b/controller/MiNiFiController.cpp
@@ -23,14 +23,14 @@
#include "Controller.h"
#include "Defaults.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "MainHelper.h"
-#include "agent/agent_version.h"
+#include "minifi-cpp/agent/agent_version.h"
#include "argparse/argparse.hpp"
#include "c2/ControllerSocketProtocol.h"
#include "controllers/SSLContextService.h"
#include "core/ConfigurationFactory.h"
-#include "core/controller/ControllerService.h"
+#include "minifi-cpp/core/controller/ControllerService.h"
#include "core/extension/ExtensionManager.h"
#include "properties/Configure.h"
#include "range/v3/algorithm/contains.hpp"
diff --git a/controller/tests/ControllerTests.cpp b/controller/tests/ControllerTests.cpp
index 778062d42..bd0149ca0 100644
--- a/controller/tests/ControllerTests.cpp
+++ b/controller/tests/ControllerTests.cpp
@@ -30,7 +30,6 @@
#include "c2/ControllerSocketProtocol.h"
#include "unit/TestUtils.h"
#include "c2/ControllerSocketMetricsPublisher.h"
-#include "core/controller/ControllerServiceProvider.h"
#include "controllers/SSLContextService.h"
#include "utils/StringUtils.h"
#include "state/UpdateController.h"
diff --git a/core-framework/include/Exception.h b/core-framework/include/Exception.h
deleted file mode 100644
index 2bd20d067..000000000
--- a/core-framework/include/Exception.h
+++ /dev/null
@@ -1,21 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/Exception.h"
diff --git a/core-framework/include/SwapManager.h b/core-framework/include/SwapManager.h
deleted file mode 100644
index 21c4c2863..000000000
--- a/core-framework/include/SwapManager.h
+++ /dev/null
@@ -1,21 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/SwapManager.h"
diff --git a/core-framework/include/agent/agent_version.h b/core-framework/include/agent/agent_version.h
deleted file mode 100644
index 6f739203b..000000000
--- a/core-framework/include/agent/agent_version.h
+++ /dev/null
@@ -1,19 +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.
- */
-#pragma once
-
-#include "minifi-cpp/agent/agent_version.h"
diff --git a/core-framework/include/core/Annotation.h b/core-framework/include/core/Annotation.h
deleted file mode 100644
index 9b729f880..000000000
--- a/core-framework/include/core/Annotation.h
+++ /dev/null
@@ -1,20 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/core/Annotation.h"
diff --git a/core-framework/include/core/BufferedContentSession.h b/core-framework/include/core/BufferedContentSession.h
index 97ca2f609..f98987735 100644
--- a/core-framework/include/core/BufferedContentSession.h
+++ b/core-framework/include/core/BufferedContentSession.h
@@ -20,7 +20,7 @@
#include <memory>
#include <map>
-#include "io/BaseStream.h"
+#include "minifi-cpp/io/BaseStream.h"
#include "ContentSession.h"
namespace org::apache::nifi::minifi::core {
diff --git a/core-framework/include/core/ClassLoader.h b/core-framework/include/core/ClassLoader.h
index 26915db5b..1f1cb70a1 100644
--- a/core-framework/include/core/ClassLoader.h
+++ b/core-framework/include/core/ClassLoader.h
@@ -19,7 +19,6 @@
#include "minifi-cpp/core/ClassLoader.h"
#include "utils/GeneralUtils.h"
-#include "ObjectFactory.h"
namespace org::apache::nifi::minifi::core {
diff --git a/core-framework/include/core/ConfigurableComponentImpl.h b/core-framework/include/core/ConfigurableComponentImpl.h
index cf0460c5f..0335e8043 100644
--- a/core-framework/include/core/ConfigurableComponentImpl.h
+++ b/core-framework/include/core/ConfigurableComponentImpl.h
@@ -23,7 +23,7 @@
#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
namespace org::apache::nifi::minifi::core {
diff --git a/core-framework/include/core/Connectable.h b/core-framework/include/core/Connectable.h
index 6b402a184..af9e620ef 100644
--- a/core-framework/include/core/Connectable.h
+++ b/core-framework/include/core/Connectable.h
@@ -33,7 +33,7 @@
#include "minifi-cpp/core/RelationshipDefinition.h"
#include "minifi-cpp/core/Scheduling.h"
#include "minifi-cpp/core/state/FlowIdentifier.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "minifi-cpp/core/Connectable.h"
namespace org::apache::nifi::minifi::core {
diff --git a/core-framework/include/core/ContentRepository.h b/core-framework/include/core/ContentRepository.h
index ab9d97533..0b9d91563 100644
--- a/core-framework/include/core/ContentRepository.h
+++ b/core-framework/include/core/ContentRepository.h
@@ -26,7 +26,7 @@
#include <list>
#include "StreamManager.h"
-#include "ContentSession.h"
+#include "minifi-cpp/core/ContentSession.h"
#include "core/Core.h"
#include "minifi-cpp/core/ContentRepository.h"
#include "core/RepositoryMetricsSource.h"
diff --git a/core-framework/include/core/ContentSession.h b/core-framework/include/core/ContentSession.h
index c07fd3b9d..2924fee29 100644
--- a/core-framework/include/core/ContentSession.h
+++ b/core-framework/include/core/ContentSession.h
@@ -21,14 +21,13 @@
#include <memory>
#include <utility>
#include <map>
-#include "io/BaseStream.h"
+#include "minifi-cpp/io/BaseStream.h"
#include "minifi-cpp/core/ContentSession.h"
-#include "ContentRepository.h"
+#include "minifi-cpp/core/ContentRepository.h"
namespace org::apache::nifi::minifi::core {
class StreamAppendLock;
-class ContentRepository;
class ContentSessionImpl : public virtual ContentSession {
struct AppendState {
diff --git a/core-framework/include/core/OutputAttributeDefinition.h b/core-framework/include/core/OutputAttributeDefinition.h
deleted file mode 100644
index e0b8af569..000000000
--- a/core-framework/include/core/OutputAttributeDefinition.h
+++ /dev/null
@@ -1,20 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/core/OutputAttributeDefinition.h"
diff --git a/core-framework/include/core/ProcessContext.h b/core-framework/include/core/ProcessContext.h
index a89b5c7df..5c533721b 100644
--- a/core-framework/include/core/ProcessContext.h
+++ b/core-framework/include/core/ProcessContext.h
@@ -29,9 +29,8 @@
#include <vector>
#include "core/ConfigurableComponentImpl.h"
-#include "core/ContentRepository.h"
+#include "minifi-cpp/core/ContentRepository.h"
#include "core/Core.h"
-#include "core/Property.h"
#include "core/VariableRegistry.h"
#include "core/logging/LoggerFactory.h"
#include "minifi-cpp/controllers/keyvalue/KeyValueStateStorage.h"
diff --git a/core-framework/include/core/ProcessContextBuilder.h b/core-framework/include/core/ProcessContextBuilder.h
index 979ab1d0d..3b6cbf517 100644
--- a/core-framework/include/core/ProcessContextBuilder.h
+++ b/core-framework/include/core/ProcessContextBuilder.h
@@ -27,11 +27,10 @@
#include "minifi-cpp/core/Property.h"
#include "core/Core.h"
#include "utils/Id.h"
-#include "core/ContentRepository.h"
+#include "minifi-cpp/core/ContentRepository.h"
#include "core/logging/LoggerFactory.h"
#include "ProcessContext.h"
#include "minifi-cpp/core/FlowFile.h"
-#include "VariableRegistry.h"
#include "minifi-cpp/core/ProcessContextBuilder.h"
#include "utils/GeneralUtils.h"
diff --git a/core-framework/include/core/ProcessorImpl.h b/core-framework/include/core/ProcessorImpl.h
index fc6fc8a80..44fec377c 100644
--- a/core-framework/include/core/ProcessorImpl.h
+++ b/core-framework/include/core/ProcessorImpl.h
@@ -28,21 +28,20 @@
#include <string>
#include "core/ConfigurableComponentImpl.h"
-#include "core/Connectable.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/Core.h"
#include "minifi-cpp/core/Annotation.h"
#include "minifi-cpp/core/DynamicProperty.h"
#include "minifi-cpp/core/Scheduling.h"
#include "minifi-cpp/core/state/nodes/MetricsBase.h"
#include "minifi-cpp/core/ProcessorMetrics.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/Id.h"
#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "minifi-cpp/core/ProcessorApi.h"
#include "utils/PropertyErrors.h"
#include "minifi-cpp/core/ProcessorMetadata.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#define ADD_GET_PROCESSOR_NAME \
std::string getProcessorType() const override { \
diff --git a/core-framework/include/core/Property.h b/core-framework/include/core/Property.h
deleted file mode 100644
index 544e48189..000000000
--- a/core-framework/include/core/Property.h
+++ /dev/null
@@ -1,25 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/core/Property.h"
-
-namespace org::apache::nifi::minifi::core {
-
-
-} // namespace org::apache::nifi::minifi::core
diff --git a/core-framework/include/core/PropertyDefinition.h b/core-framework/include/core/PropertyDefinition.h
deleted file mode 100644
index 56299edf4..000000000
--- a/core-framework/include/core/PropertyDefinition.h
+++ /dev/null
@@ -1,20 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/core/PropertyDefinition.h"
diff --git a/core-framework/include/core/PropertyDefinitionBuilder.h b/core-framework/include/core/PropertyDefinitionBuilder.h
index 2ce5cdf69..c99038041 100644
--- a/core-framework/include/core/PropertyDefinitionBuilder.h
+++ b/core-framework/include/core/PropertyDefinitionBuilder.h
@@ -18,7 +18,7 @@
#include <utility>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "core/ClassName.h"
diff --git a/core-framework/include/core/RelationshipDefinition.h b/core-framework/include/core/RelationshipDefinition.h
deleted file mode 100644
index 56b101f7c..000000000
--- a/core-framework/include/core/RelationshipDefinition.h
+++ /dev/null
@@ -1,20 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/core/RelationshipDefinition.h"
diff --git a/core-framework/include/core/Repository.h b/core-framework/include/core/Repository.h
index b5f25a0e2..ee2d3a040 100644
--- a/core-framework/include/core/Repository.h
+++ b/core-framework/include/core/Repository.h
@@ -30,13 +30,13 @@
#include <utility>
#include <vector>
-#include "core/Connectable.h"
-#include "core/ContentRepository.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Connectable.h"
+#include "minifi-cpp/core/ContentRepository.h"
+#include "minifi-cpp/core/Property.h"
#include "core/logging/LoggerFactory.h"
#include "core/RepositoryMetricsSource.h"
#include "utils/BackTrace.h"
-#include "utils/Literals.h"
+#include "minifi-cpp/utils/Literals.h"
#include "utils/StringUtils.h"
#include "utils/TimeUtil.h"
#include "core/Core.h"
diff --git a/core-framework/include/core/Resource.h b/core-framework/include/core/Resource.h
index 999f1ddb5..0b73c8ba9 100644
--- a/core-framework/include/core/Resource.h
+++ b/core-framework/include/core/Resource.h
@@ -30,6 +30,7 @@
#include "utils/OptionalUtils.h"
#include "utils/Macro.h"
#include "core/ProcessorFactoryImpl.h"
+#include "core/ObjectFactory.h"
namespace org::apache::nifi::minifi::core {
diff --git a/core-framework/include/core/StreamManager.h b/core-framework/include/core/StreamManager.h
index fed007150..8f5fe5ce5 100644
--- a/core-framework/include/core/StreamManager.h
+++ b/core-framework/include/core/StreamManager.h
@@ -22,13 +22,13 @@
#include "minifi-cpp/core/StreamManager.h"
#include "io/BufferStream.h"
-#include "io/BaseStream.h"
+#include "minifi-cpp/io/BaseStream.h"
namespace org::apache::nifi::minifi::core {
/**
* Purpose: Provides a base for all stream based managers. The goal here is to provide
- * a small set of interfaces that provide a small set of operations to provide state
+ * a small set of interfaces that provide a small set of operations to provide state
* management for streams.
*/
template<typename T>
diff --git a/core-framework/include/core/TypedValues.h b/core-framework/include/core/TypedValues.h
index b609146c4..e17e14349 100644
--- a/core-framework/include/core/TypedValues.h
+++ b/core-framework/include/core/TypedValues.h
@@ -27,10 +27,10 @@
#include "state/Value.h"
#include "utils/StringUtils.h"
#include "utils/ValueParser.h"
-#include "utils/PropertyExceptions.h"
-#include "utils/Literals.h"
+#include "minifi-cpp/utils/PropertyExceptions.h"
+#include "minifi-cpp/utils/Literals.h"
#include "utils/TimeUtil.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::core {
diff --git a/core-framework/include/core/logging/Logger.h b/core-framework/include/core/logging/Logger.h
deleted file mode 100644
index 1cb475395..000000000
--- a/core-framework/include/core/logging/Logger.h
+++ /dev/null
@@ -1,20 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/core/logging/Logger.h"
diff --git a/core-framework/include/core/state/MetricsPublisher.h b/core-framework/include/core/state/MetricsPublisher.h
index 7c3f92e67..9c141e8fb 100644
--- a/core-framework/include/core/state/MetricsPublisher.h
+++ b/core-framework/include/core/state/MetricsPublisher.h
@@ -20,7 +20,7 @@
#include <memory>
#include "core/Core.h"
-#include "properties/Configure.h"
+#include "minifi-cpp/properties/Configure.h"
#include "minifi-cpp/core/state/MetricsPublisher.h"
namespace org::apache::nifi::minifi::state {
diff --git a/core-framework/include/http/BaseHTTPClient.h b/core-framework/include/http/BaseHTTPClient.h
index ad22ce950..84c7bbb7c 100644
--- a/core-framework/include/http/BaseHTTPClient.h
+++ b/core-framework/include/http/BaseHTTPClient.h
@@ -27,7 +27,7 @@
#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "utils/ByteArrayCallback.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::http {
enum class HttpRequestMethod {
diff --git a/core-framework/include/http/HTTPClient.h b/core-framework/include/http/HTTPClient.h
index eb9e7f057..b38d4b0db 100644
--- a/core-framework/include/http/HTTPClient.h
+++ b/core-framework/include/http/HTTPClient.h
@@ -42,7 +42,7 @@
#include <vector>
#include "core/Connectable.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "utils/ByteArrayCallback.h"
diff --git a/core-framework/include/io/ArchiveStream.h b/core-framework/include/io/ArchiveStream.h
deleted file mode 100644
index 5c4962127..000000000
--- a/core-framework/include/io/ArchiveStream.h
+++ /dev/null
@@ -1,20 +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.
- */
-#pragma once
-
-#include "minifi-cpp/io/ArchiveStream.h"
diff --git a/core-framework/include/io/BufferStream.h b/core-framework/include/io/BufferStream.h
index cadf54ab4..340e7a9a0 100644
--- a/core-framework/include/io/BufferStream.h
+++ b/core-framework/include/io/BufferStream.h
@@ -23,7 +23,7 @@
#include <vector>
#include <string>
#include "BaseStream.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org {
namespace apache {
diff --git a/core-framework/include/io/CRCStream.h b/core-framework/include/io/CRCStream.h
index 50fc877be..a53e44c5d 100644
--- a/core-framework/include/io/CRCStream.h
+++ b/core-framework/include/io/CRCStream.h
@@ -34,7 +34,7 @@
#endif
#include "InputStream.h"
#include "OutputStream.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::io {
namespace internal {
diff --git a/core-framework/include/io/StreamPipe.h b/core-framework/include/io/StreamPipe.h
index 7502239b6..ccd7809d2 100644
--- a/core-framework/include/io/StreamPipe.h
+++ b/core-framework/include/io/StreamPipe.h
@@ -23,8 +23,8 @@
#include <functional>
#include <memory>
#include <utility>
-#include "InputStream.h"
-#include "OutputStream.h"
+#include "minifi-cpp/io/InputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
#include "minifi-cpp/io/StreamCallback.h"
#include "utils/ConfigurationUtils.h"
diff --git a/core-framework/include/io/ZlibStream.h b/core-framework/include/io/ZlibStream.h
index 42beb7924..b90c76add 100644
--- a/core-framework/include/io/ZlibStream.h
+++ b/core-framework/include/io/ZlibStream.h
@@ -27,7 +27,7 @@
#include "OutputStream.h"
#include "Stream.h"
#include "minifi-cpp/core/logging/Logger.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::io {
diff --git a/core-framework/include/utils/AutoPersistor.h b/core-framework/include/utils/AutoPersistor.h
index 4f44688e2..e7e620247 100644
--- a/core-framework/include/utils/AutoPersistor.h
+++ b/core-framework/include/utils/AutoPersistor.h
@@ -26,7 +26,7 @@
#include "core/ConfigurableComponentImpl.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::controllers {
diff --git a/core-framework/include/utils/ByteArrayCallback.h b/core-framework/include/utils/ByteArrayCallback.h
index 2145de7aa..76d34146d 100644
--- a/core-framework/include/utils/ByteArrayCallback.h
+++ b/core-framework/include/utils/ByteArrayCallback.h
@@ -24,8 +24,8 @@
#include "concurrentqueue.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/gsl.h"
-#include "io/InputStream.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/io/InputStream.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/core-framework/include/utils/Cron.h b/core-framework/include/utils/Cron.h
index 97b78e3d9..bef03c8ca 100644
--- a/core-framework/include/utils/Cron.h
+++ b/core-framework/include/utils/Cron.h
@@ -23,7 +23,7 @@
#include <memory>
#include <utility>
#include "date/tz.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::utils {
class BadCronExpression : public minifi::Exception {
diff --git a/core-framework/include/utils/Export.h b/core-framework/include/utils/Export.h
deleted file mode 100644
index 175821d93..000000000
--- a/core-framework/include/utils/Export.h
+++ /dev/null
@@ -1,35 +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.
- */
-
-#pragma once
-
-#ifdef WIN32
- #ifdef LIBMINIFI
- #define MINIFIAPI __declspec(dllexport)
- #else
- #define MINIFIAPI __declspec(dllimport)
- #endif
- #ifdef MODULE_NAME
- #define EXTENSIONAPI __declspec(dllexport)
- #else
- #define EXTENSIONAPI __declspec(dllimport)
- #endif
-#else
- #define MINIFIAPI
- #define EXTENSIONAPI
-#endif
diff --git a/core-framework/include/utils/FileMutex.h b/core-framework/include/utils/FileMutex.h
index 54596ead2..1715f8123 100644
--- a/core-framework/include/utils/FileMutex.h
+++ b/core-framework/include/utils/FileMutex.h
@@ -21,7 +21,7 @@
#include <array>
#include <mutex>
#include <optional>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#ifdef WIN32
#include <windows.h>
diff --git a/core-framework/include/utils/GeneralUtils.h b/core-framework/include/utils/GeneralUtils.h
index 034bf2058..31c71e436 100644
--- a/core-framework/include/utils/GeneralUtils.h
+++ b/core-framework/include/utils/GeneralUtils.h
@@ -22,7 +22,7 @@
#include <type_traits>
#include <utility>
-#include "gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/core-framework/include/utils/IntervalSwitch.h b/core-framework/include/utils/IntervalSwitch.h
index 0052b4e00..a776feb23 100644
--- a/core-framework/include/utils/IntervalSwitch.h
+++ b/core-framework/include/utils/IntervalSwitch.h
@@ -21,7 +21,7 @@
#include <functional>
#include <utility>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org {
namespace apache {
diff --git a/core-framework/include/utils/LineByLineInputOutputStreamCallback.h b/core-framework/include/utils/LineByLineInputOutputStreamCallback.h
index b52821d8e..72fb0bedd 100644
--- a/core-framework/include/utils/LineByLineInputOutputStreamCallback.h
+++ b/core-framework/include/utils/LineByLineInputOutputStreamCallback.h
@@ -22,9 +22,9 @@
#include <string>
#include <vector>
-#include "core/logging/Logger.h"
-#include "io/InputStream.h"
-#include "io/OutputStream.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/io/InputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
#include "io/StreamPipe.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/core-framework/include/utils/Literals.h b/core-framework/include/utils/Literals.h
deleted file mode 100644
index 741166a1a..000000000
--- a/core-framework/include/utils/Literals.h
+++ /dev/null
@@ -1,19 +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.
- */
-#pragma once
-
-#include "minifi-cpp/utils/Literals.h"
diff --git a/core-framework/include/utils/OptionalUtils.h b/core-framework/include/utils/OptionalUtils.h
index 7d71f8f7c..7289b6457 100644
--- a/core-framework/include/utils/OptionalUtils.h
+++ b/core-framework/include/utils/OptionalUtils.h
@@ -25,7 +25,7 @@
#include "nonstd/expected.hpp"
#include "utils/GeneralUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/detail/MonadicOperationWrappers.h"
#include "fmt/format.h"
diff --git a/core-framework/include/utils/ParsingUtils.h b/core-framework/include/utils/ParsingUtils.h
index 7aa8d99ec..34307b0ff 100644
--- a/core-framework/include/utils/ParsingUtils.h
+++ b/core-framework/include/utils/ParsingUtils.h
@@ -16,12 +16,10 @@
*/
#pragma once
-
-
#include "ParsingErrors.h"
#include "StringUtils.h"
#include "TimeUtil.h"
-#include "Literals.h"
+#include "minifi-cpp/utils/Literals.h"
#include "fmt/format.h"
namespace org::apache::nifi::minifi::parsing {
diff --git a/core-framework/include/utils/PropertyExceptions.h b/core-framework/include/utils/PropertyExceptions.h
deleted file mode 100644
index 51fb47f99..000000000
--- a/core-framework/include/utils/PropertyExceptions.h
+++ /dev/null
@@ -1,19 +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.
- */
-#pragma once
-
-#include "minifi-cpp/utils/PropertyExceptions.h"
diff --git a/core-framework/include/utils/StringUtils.h b/core-framework/include/utils/StringUtils.h
index d220f2a43..8929f1123 100644
--- a/core-framework/include/utils/StringUtils.h
+++ b/core-framework/include/utils/StringUtils.h
@@ -35,7 +35,7 @@
#endif
#include "utils/expected.h"
#include "utils/FailurePolicy.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/span.h"
#include "utils/meta/detected.h"
#include "range/v3/view/transform.hpp"
diff --git a/core-framework/include/utils/ThreadPool.h b/core-framework/include/utils/ThreadPool.h
index f5a90f698..d65baf07a 100644
--- a/core-framework/include/utils/ThreadPool.h
+++ b/core-framework/include/utils/ThreadPool.h
@@ -39,7 +39,7 @@
#include "core/expect.h"
#include "minifi-cpp/controllers/ThreadManagementService.h"
#include "minifi-cpp/core/controller/ControllerServiceLookup.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/core-framework/include/utils/ValueParser.h b/core-framework/include/utils/ValueParser.h
index ec24fd192..71329cb17 100644
--- a/core-framework/include/utils/ValueParser.h
+++ b/core-framework/include/utils/ValueParser.h
@@ -27,7 +27,7 @@
#include <limits>
#include <algorithm>
-#include "PropertyExceptions.h"
+#include "minifi-cpp/utils/PropertyExceptions.h"
namespace org::apache::nifi::minifi::utils {
namespace internal {
diff --git a/core-framework/include/utils/crypto/EncryptionManager.h b/core-framework/include/utils/crypto/EncryptionManager.h
index bdcede1dc..b156c1845 100644
--- a/core-framework/include/utils/crypto/EncryptionManager.h
+++ b/core-framework/include/utils/crypto/EncryptionManager.h
@@ -26,7 +26,7 @@
#include "utils/crypto/EncryptionUtils.h"
#include "utils/crypto/ciphers/XSalsa20.h"
#include "utils/crypto/ciphers/Aes256Ecb.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::utils::crypto {
diff --git a/core-framework/include/utils/crypto/EncryptionProvider.h b/core-framework/include/utils/crypto/EncryptionProvider.h
index b72c38134..5556c63db 100644
--- a/core-framework/include/utils/crypto/EncryptionProvider.h
+++ b/core-framework/include/utils/crypto/EncryptionProvider.h
@@ -26,7 +26,7 @@
#include "utils/crypto/EncryptionUtils.h"
#include "utils/crypto/ciphers/XSalsa20.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::utils::crypto {
diff --git a/core-framework/include/utils/crypto/ciphers/Aes256Ecb.h b/core-framework/include/utils/crypto/ciphers/Aes256Ecb.h
index 0e920afec..c45f1f37d 100644
--- a/core-framework/include/utils/crypto/ciphers/Aes256Ecb.h
+++ b/core-framework/include/utils/crypto/ciphers/Aes256Ecb.h
@@ -22,8 +22,8 @@
#include <utility>
#include "utils/crypto/EncryptionUtils.h"
-#include "Exception.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org {
namespace apache {
diff --git a/core-framework/include/utils/file/FileUtils.h b/core-framework/include/utils/file/FileUtils.h
index f0968177d..36f6d5e53 100644
--- a/core-framework/include/utils/file/FileUtils.h
+++ b/core-framework/include/utils/file/FileUtils.h
@@ -74,7 +74,7 @@
#include "utils/StringUtils.h"
#include "utils/expected.h"
#include "utils/file/PathUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#ifndef S_ISDIR
#define S_ISDIR(mode) (((mode) & S_IFMT) == S_IFDIR)
diff --git a/core-framework/include/utils/gsl.h b/core-framework/include/utils/gsl.h
deleted file mode 100644
index 5b145ae44..000000000
--- a/core-framework/include/utils/gsl.h
+++ /dev/null
@@ -1,21 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/utils/gsl.h"
diff --git a/core-framework/include/utils/net/NetworkInterfaceInfo.h b/core-framework/include/utils/net/NetworkInterfaceInfo.h
index 5d8f7953e..64fb2f212 100644
--- a/core-framework/include/utils/net/NetworkInterfaceInfo.h
+++ b/core-framework/include/utils/net/NetworkInterfaceInfo.h
@@ -22,7 +22,7 @@
#include <memory>
#include <unordered_map>
#include <optional>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#ifdef WIN32
struct _IP_ADAPTER_ADDRESSES_LH;
diff --git a/core-framework/src/core/BufferedContentSession.cpp b/core-framework/src/core/BufferedContentSession.cpp
index 9a9e1f131..418da5c16 100644
--- a/core-framework/src/core/BufferedContentSession.cpp
+++ b/core-framework/src/core/BufferedContentSession.cpp
@@ -18,11 +18,11 @@
#include "core/BufferedContentSession.h"
#include <memory>
-#include "core/ContentRepository.h"
-#include "io/BaseStream.h"
+#include "minifi-cpp/core/ContentRepository.h"
+#include "minifi-cpp/io/BaseStream.h"
#include "io/StreamPipe.h"
#include "io/StreamSlice.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::core {
diff --git a/core-framework/src/core/ContentSession.cpp b/core-framework/src/core/ContentSession.cpp
index d22fdd4d1..a7e7e594a 100644
--- a/core-framework/src/core/ContentSession.cpp
+++ b/core-framework/src/core/ContentSession.cpp
@@ -19,7 +19,6 @@
#include "core/ContentSession.h"
#include "io/StreamPipe.h"
#include "io/StreamSlice.h"
-#include "core/ContentRepository.h"
namespace org::apache::nifi::minifi::core {
diff --git a/core-framework/src/core/ProcessorImpl.cpp b/core-framework/src/core/ProcessorImpl.cpp
index bda6c6910..4c349b6a1 100644
--- a/core-framework/src/core/ProcessorImpl.cpp
+++ b/core-framework/src/core/ProcessorImpl.cpp
@@ -28,15 +28,14 @@
#include <vector>
#include "minifi-cpp/Connection.h"
-#include "core/Connectable.h"
#include "core/logging/LoggerFactory.h"
#include "minifi-cpp/core/ProcessorConfig.h"
#include "minifi-cpp/core/ProcessContext.h"
#include "minifi-cpp/core/ProcessSessionFactory.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "range/v3/algorithm/any_of.hpp"
#include "fmt/format.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "core/ProcessorMetrics.h"
#include "minifi-cpp/core/ProcessorDescriptor.h"
diff --git a/core-framework/src/core/ProcessorMetrics.cpp b/core-framework/src/core/ProcessorMetrics.cpp
index 9952f74b4..5de69f200 100644
--- a/core-framework/src/core/ProcessorMetrics.cpp
+++ b/core-framework/src/core/ProcessorMetrics.cpp
@@ -18,7 +18,7 @@
#include "core/ProcessorImpl.h"
#include "core/state/Value.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "range/v3/numeric/accumulate.hpp"
using namespace std::literals::chrono_literals;
diff --git a/core-framework/src/core/Property.cpp b/core-framework/src/core/Property.cpp
index 047d715a7..8af7fa490 100644
--- a/core-framework/src/core/Property.cpp
+++ b/core-framework/src/core/Property.cpp
@@ -16,11 +16,11 @@
* limitations under the License.
*/
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include <utility>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "utils/PropertyErrors.h"
#include "range/v3/algorithm/none_of.hpp"
diff --git a/core-framework/src/core/TypedValues.cpp b/core-framework/src/core/TypedValues.cpp
index 7dde6a98a..c1a7ca3d0 100644
--- a/core-framework/src/core/TypedValues.cpp
+++ b/core-framework/src/core/TypedValues.cpp
@@ -18,7 +18,7 @@
#include <memory>
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/TypedValues.h"
#include "core/logging/LoggerFactory.h"
diff --git a/core-framework/src/http/HTTPClient.cpp b/core-framework/src/http/HTTPClient.cpp
index cc879f58a..af8d965ea 100644
--- a/core-framework/src/http/HTTPClient.cpp
+++ b/core-framework/src/http/HTTPClient.cpp
@@ -31,9 +31,9 @@
#include "magic_enum.hpp"
#include "range/v3/algorithm/all_of.hpp"
#include "range/v3/action/transform.hpp"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/HTTPUtils.h"
-#include "utils/Literals.h"
+#include "minifi-cpp/utils/Literals.h"
#include "utils/StringUtils.h"
using namespace std::literals::chrono_literals;
diff --git a/core-framework/src/http/HTTPStream.cpp b/core-framework/src/http/HTTPStream.cpp
index cd989af9b..32e1857df 100644
--- a/core-framework/src/http/HTTPStream.cpp
+++ b/core-framework/src/http/HTTPStream.cpp
@@ -24,7 +24,7 @@
#include "http/HTTPCallback.h"
#include "io/validation.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::http {
diff --git a/core-framework/src/io/BufferStream.cpp b/core-framework/src/io/BufferStream.cpp
index 235fd595c..2dad267d2 100644
--- a/core-framework/src/io/BufferStream.cpp
+++ b/core-framework/src/io/BufferStream.cpp
@@ -20,7 +20,7 @@
#include <cstring>
#include "io/BufferStream.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::io {
diff --git a/core-framework/src/io/FileStream.cpp b/core-framework/src/io/FileStream.cpp
index 00a4e0f7e..d2154d43b 100644
--- a/core-framework/src/io/FileStream.cpp
+++ b/core-framework/src/io/FileStream.cpp
@@ -21,12 +21,12 @@
#include <vector>
#include <string>
#include <utility>
+#include <algorithm>
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "io/validation.h"
#include "io/FileStream.h"
-#include "io/InputStream.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::io {
@@ -125,9 +125,7 @@ size_t FileStream::write(const uint8_t *value, size_t size) {
return STREAM_ERROR;
}
offset_ += size;
- if (offset_ > length_) {
- length_ = offset_;
- }
+ length_ = std::max(offset_, length_);
if (!file_stream_->flush()) {
logger_->log_error("{}{}", WRITE_ERROR_MSG, FLUSH_CALL_ERROR_MSG);
return STREAM_ERROR;
diff --git a/core-framework/src/io/InputStream.cpp b/core-framework/src/io/InputStream.cpp
index 6765698fb..f23e72b3d 100644
--- a/core-framework/src/io/InputStream.cpp
+++ b/core-framework/src/io/InputStream.cpp
@@ -19,7 +19,7 @@
#include <vector>
#include <string>
#include "io/InputStream.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::io {
diff --git a/core-framework/src/io/OutputStream.cpp b/core-framework/src/io/OutputStream.cpp
index 1b48912c8..31f13fd15 100644
--- a/core-framework/src/io/OutputStream.cpp
+++ b/core-framework/src/io/OutputStream.cpp
@@ -22,7 +22,7 @@
#include <string>
#include <algorithm>
#include "io/OutputStream.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::io {
diff --git a/core-framework/src/io/ZlibStream.cpp b/core-framework/src/io/ZlibStream.cpp
index 9d8912c7a..436d9c5c9 100644
--- a/core-framework/src/io/ZlibStream.cpp
+++ b/core-framework/src/io/ZlibStream.cpp
@@ -19,8 +19,8 @@
#include <utility>
#include "io/ZlibStream.h"
-#include "Exception.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/logging/LoggerFactory.h"
#include "magic_enum.hpp"
diff --git a/core-framework/src/utils/ByteArrayCallback.cpp b/core-framework/src/utils/ByteArrayCallback.cpp
index 018d24790..8446e9a27 100644
--- a/core-framework/src/utils/ByteArrayCallback.cpp
+++ b/core-framework/src/utils/ByteArrayCallback.cpp
@@ -22,7 +22,7 @@
#include <string>
#include <memory>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::utils {
@@ -100,7 +100,7 @@ size_t ByteOutputCallback::read_current_str(char *buffer, size_t size) {
read_started_ = true;
do {
std::lock_guard<std::recursive_mutex> lock(vector_lock_);
- if (current_str_pos <= current_str.length() && current_str.length() > 0) {
+ if (current_str_pos <= current_str.length() && !current_str.empty()) {
size_t str_remaining = current_str.length() - current_str_pos;
size_t current_str_read = str_remaining;
if (str_remaining > amount_to_read) {
@@ -137,9 +137,9 @@ size_t ByteOutputCallback::read_current_str(char *buffer, size_t size) {
bool ByteOutputCallback::preload_next_str() {
// wait until there is data or this stream has been stopped.
- if (queue_.size_approx() == 0 && current_str.length() == 0) {
+ if (queue_.size_approx() == 0 && current_str.empty()) {
std::unique_lock<std::recursive_mutex> lock(vector_lock_);
- if (queue_.size_approx() == 0 && current_str.length() == 0) {
+ if (queue_.size_approx() == 0 && current_str.empty()) {
spinner_.wait(lock, [&] {
return queue_.size_approx() > 0 || !is_alive_;});
}
diff --git a/extension-framework/src/utils/CallBackTimer.cpp b/core-framework/src/utils/CallBackTimer.cpp
similarity index 100%
rename from extension-framework/src/utils/CallBackTimer.cpp
rename to core-framework/src/utils/CallBackTimer.cpp
diff --git a/core-framework/src/utils/Environment.cpp b/core-framework/src/utils/Environment.cpp
index 299946134..91c3a58c7 100644
--- a/core-framework/src/utils/Environment.cpp
+++ b/core-framework/src/utils/Environment.cpp
@@ -29,7 +29,7 @@
#include <iostream>
#include <unordered_map>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#ifdef WIN32
#include "utils/UnicodeConversion.h"
#endif
diff --git a/core-framework/src/utils/Error.cpp b/core-framework/src/utils/Error.cpp
index aca9ded44..81717f57f 100644
--- a/core-framework/src/utils/Error.cpp
+++ b/core-framework/src/utils/Error.cpp
@@ -18,7 +18,7 @@
#include "utils/Error.h"
#include <cerrno>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#ifdef WIN32
#include <windows.h>
diff --git a/core-framework/src/utils/FileMutex.cpp b/core-framework/src/utils/FileMutex.cpp
index 758f1d248..702cffc91 100644
--- a/core-framework/src/utils/FileMutex.cpp
+++ b/core-framework/src/utils/FileMutex.cpp
@@ -19,7 +19,7 @@
#include <span>
#include <iostream>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/OsUtils.h"
#include "utils/Error.h"
diff --git a/core-framework/src/utils/Id.cpp b/core-framework/src/utils/Id.cpp
index 2de52b553..3037827f1 100644
--- a/core-framework/src/utils/Id.cpp
+++ b/core-framework/src/utils/Id.cpp
@@ -42,7 +42,7 @@
#endif
#include "utils/StringUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::utils {
@@ -170,8 +170,8 @@ std::optional<Identifier> Identifier::parse(const std::string &str) {
bool Identifier::parseByte(Data &data, const uint8_t *input, int &charIdx, int &byteIdx) {
uint8_t upper = 0;
uint8_t lower = 0;
- if (!string::from_hex(input[charIdx++], upper)
- || !string::from_hex(input[charIdx++], lower)) {
+ if (!string::from_hex(input[charIdx++], upper) // NOLINT(bugprone-inc-dec-in-conditions)
+ || !string::from_hex(input[charIdx++], lower)) { // NOLINT(bugprone-inc-dec-in-conditions)
return false;
}
data[byteIdx++] = (upper << 4) | lower;
diff --git a/core-framework/src/utils/LineByLineInputOutputStreamCallback.cpp b/core-framework/src/utils/LineByLineInputOutputStreamCallback.cpp
index 6be8b7fd3..ec59fff53 100644
--- a/core-framework/src/utils/LineByLineInputOutputStreamCallback.cpp
+++ b/core-framework/src/utils/LineByLineInputOutputStreamCallback.cpp
@@ -17,7 +17,7 @@
#include "utils/LineByLineInputOutputStreamCallback.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/span.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/core-framework/src/utils/OsUtils.cpp b/core-framework/src/utils/OsUtils.cpp
index 0da1af7eb..6aa43ca59 100644
--- a/core-framework/src/utils/OsUtils.cpp
+++ b/core-framework/src/utils/OsUtils.cpp
@@ -22,8 +22,8 @@
#include <map>
#include "fmt/format.h"
-#include "utils/gsl.h"
-#include "Exception.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/Exception.h"
#ifdef __linux__
#include <sys/sysinfo.h>
@@ -177,7 +177,7 @@ int64_t OsUtils::getCurrentProcessPhysicalMemoryUsage() {
std::string line;
while (std::getline(status_file, line)) {
- if (line.rfind(resident_set_size_prefix, 0) == 0) {
+ if (line.starts_with(resident_set_size_prefix)) {
std::istringstream resident_set_size_value(line.substr(resident_set_size_prefix.length()));
uint64_t memory_usage_in_kBytes = 0;
resident_set_size_value >> memory_usage_in_kBytes;
@@ -221,11 +221,11 @@ int64_t OsUtils::getSystemPhysicalMemoryUsage() {
std::optional<uint64_t> total_memory_kByte;
std::optional<uint64_t> available_memory_kByte;
while ((!total_memory_kByte.has_value() || !available_memory_kByte.has_value()) && std::getline(meminfo_file, line)) {
- if (line.rfind(total_memory_prefix, 0) == 0) {
+ if (line.starts_with(total_memory_prefix)) {
std::istringstream total_memory_line(line.substr(total_memory_prefix.length()));
total_memory_kByte.emplace(0);
total_memory_line >> total_memory_kByte.value();
- } else if (line.rfind(available_memory_prefix, 0) == 0) {
+ } else if (line.starts_with(available_memory_prefix)) {
std::istringstream available_memory_line(line.substr(available_memory_prefix.length()));
available_memory_kByte.emplace(0);
available_memory_line >> available_memory_kByte.value();
diff --git a/core-framework/src/utils/RegexUtils.cpp b/core-framework/src/utils/RegexUtils.cpp
index 0af1e68ad..5cb691a81 100644
--- a/core-framework/src/utils/RegexUtils.cpp
+++ b/core-framework/src/utils/RegexUtils.cpp
@@ -21,7 +21,7 @@
#include <iostream>
#include <vector>
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/core-framework/src/utils/StoppableThread.cpp b/core-framework/src/utils/StoppableThread.cpp
index 8fea65a6d..03022758a 100644
--- a/core-framework/src/utils/StoppableThread.cpp
+++ b/core-framework/src/utils/StoppableThread.cpp
@@ -16,7 +16,7 @@
*/
#include "utils/StoppableThread.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/core-framework/src/utils/SystemCpuUsageTracker.cpp b/core-framework/src/utils/SystemCpuUsageTracker.cpp
index 049dd0702..65c7d57b3 100644
--- a/core-framework/src/utils/SystemCpuUsageTracker.cpp
+++ b/core-framework/src/utils/SystemCpuUsageTracker.cpp
@@ -16,7 +16,7 @@
*/
#include "utils/SystemCpuUsageTracker.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::utils {
#ifdef __linux__
@@ -44,6 +44,7 @@ void SystemCpuUsageTracker::queryCpuTimes() {
previous_total_sys_ = total_sys_;
previous_total_idle_ = total_idle_;
gsl::owner<FILE*> file = fopen("/proc/stat", "r");
+ if (!file) { return; }
if (fscanf(file, "cpu %lu %lu %lu %lu", &total_user_, &total_user_low_, &total_sys_, &total_idle_) != 4) { // NOLINT(cert-err34-c)
total_user_ = previous_total_user_;
total_user_low_ = previous_total_user_low_;
@@ -76,7 +77,7 @@ double SystemCpuUsageTracker::getCpuUsageBetweenLastTwoQueries() const {
if (total_diff + total_idle_diff == 0) {
return -1.0;
}
- double percent = static_cast<double>(total_diff) / static_cast<double>(total_diff + total_idle_diff);
+ double percent = static_cast<double>(total_diff) / static_cast<double>(total_diff + total_idle_diff); // NOLINT(clang-analyzer-optin.taint.TaintedDiv)
return percent;
}
diff --git a/core-framework/src/utils/file/FileUtils.cpp b/core-framework/src/utils/file/FileUtils.cpp
index 9c68f1469..e24b903e1 100644
--- a/core-framework/src/utils/file/FileUtils.cpp
+++ b/core-framework/src/utils/file/FileUtils.cpp
@@ -23,7 +23,7 @@
#include <iostream>
#include "utils/ConfigurationUtils.h"
-#include "utils/Literals.h"
+#include "minifi-cpp/utils/Literals.h"
#include "utils/Searcher.h"
#ifdef WIN32
diff --git a/core-framework/src/utils/file/PathUtils.cpp b/core-framework/src/utils/file/PathUtils.cpp
index 9722270b0..908e04f6a 100644
--- a/core-framework/src/utils/file/PathUtils.cpp
+++ b/core-framework/src/utils/file/PathUtils.cpp
@@ -28,7 +28,7 @@
#include <iostream>
#include "utils/file/FileUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::utils::file {
diff --git a/core-framework/src/utils/net/DNS.cpp b/core-framework/src/utils/net/DNS.cpp
index 48d499f81..160277dac 100644
--- a/core-framework/src/utils/net/DNS.cpp
+++ b/core-framework/src/utils/net/DNS.cpp
@@ -16,7 +16,7 @@
*/
#include "utils/net/DNS.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "utils/StringUtils.h"
#include "utils/net/AsioCoro.h"
#include "asio/detached.hpp"
diff --git a/core-framework/src/utils/net/Socket.cpp b/core-framework/src/utils/net/Socket.cpp
index 6b6ac2b84..5e1b6698e 100644
--- a/core-framework/src/utils/net/Socket.cpp
+++ b/core-framework/src/utils/net/Socket.cpp
@@ -25,7 +25,7 @@
#include <arpa/inet.h>
#endif
#include <cstring>
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::utils::net {
diff --git a/encrypt-config/EncryptConfig.cpp b/encrypt-config/EncryptConfig.cpp
index 064bd939a..5e3bbd378 100644
--- a/encrypt-config/EncryptConfig.cpp
+++ b/encrypt-config/EncryptConfig.cpp
@@ -27,7 +27,6 @@
#include "ConfigFile.h"
#include "ConfigFileEncryptor.h"
#include "FlowConfigEncryptor.h"
-#include "core/extension/ExtensionManager.h"
#include "utils/Enum.h"
#include "utils/file/FileUtils.h"
diff --git a/encrypt-config/EncryptConfigMain.cpp b/encrypt-config/EncryptConfigMain.cpp
index 0091b2230..c8e76ccfb 100644
--- a/encrypt-config/EncryptConfigMain.cpp
+++ b/encrypt-config/EncryptConfigMain.cpp
@@ -20,7 +20,7 @@
#include "EncryptConfig.h"
#include "argparse/argparse.hpp"
-#include "agent/agent_version.h"
+#include "minifi-cpp/agent/agent_version.h"
#include "utils/StringUtils.h"
namespace minifi = org::apache::nifi::minifi;
diff --git a/encrypt-config/tests/ConfigFileTests.cpp b/encrypt-config/tests/ConfigFileTests.cpp
index 9df4b5762..32224a4c4 100644
--- a/encrypt-config/tests/ConfigFileTests.cpp
+++ b/encrypt-config/tests/ConfigFileTests.cpp
@@ -23,7 +23,7 @@
#include "ConfigFile.h"
#include "properties/Configuration.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
diff --git a/extension-framework/include/FlowFileRecord.h b/extension-framework/include/FlowFileRecord.h
deleted file mode 100644
index 8a1658e33..000000000
--- a/extension-framework/include/FlowFileRecord.h
+++ /dev/null
@@ -1,21 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/FlowFileRecord.h"
diff --git a/extension-framework/include/ResourceClaim.h b/extension-framework/include/ResourceClaim.h
deleted file mode 100644
index c9948ea60..000000000
--- a/extension-framework/include/ResourceClaim.h
+++ /dev/null
@@ -1,21 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/ResourceClaim.h"
diff --git a/extension-framework/include/controllers/SSLContextService.h b/extension-framework/include/controllers/SSLContextService.h
deleted file mode 100644
index 58dabc724..000000000
--- a/extension-framework/include/controllers/SSLContextService.h
+++ /dev/null
@@ -1,19 +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.
- */
-#pragma once
-
-#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
diff --git a/extension-framework/include/controllers/SSLContextServiceInterface.h b/extension-framework/include/controllers/SSLContextServiceInterface.h
deleted file mode 100644
index 58dabc724..000000000
--- a/extension-framework/include/controllers/SSLContextServiceInterface.h
+++ /dev/null
@@ -1,19 +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.
- */
-#pragma once
-
-#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
diff --git a/extension-framework/include/controllers/keyvalue/KeyValueStateManager.h b/extension-framework/include/controllers/keyvalue/KeyValueStateManager.h
index 604a113ae..d9f778de3 100644
--- a/extension-framework/include/controllers/keyvalue/KeyValueStateManager.h
+++ b/extension-framework/include/controllers/keyvalue/KeyValueStateManager.h
@@ -23,7 +23,7 @@
#include "core/StateManager.h"
#include "core/Core.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::controllers {
diff --git a/extension-framework/include/core/AbstractProcessor.h b/extension-framework/include/core/AbstractProcessor.h
index f4a76f57e..86ce4050e 100644
--- a/extension-framework/include/core/AbstractProcessor.h
+++ b/extension-framework/include/core/AbstractProcessor.h
@@ -23,7 +23,7 @@
#include "minifi-cpp/core/Annotation.h"
#include "core/Core.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/StringUtils.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extension-framework/include/core/FlowFile.h b/extension-framework/include/core/FlowFile.h
deleted file mode 100644
index 4a64a2d07..000000000
--- a/extension-framework/include/core/FlowFile.h
+++ /dev/null
@@ -1,20 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/core/FlowFile.h"
diff --git a/extension-framework/include/core/FlowFileStore.h b/extension-framework/include/core/FlowFileStore.h
index 6b261dd39..94df5722f 100644
--- a/extension-framework/include/core/FlowFileStore.h
+++ b/extension-framework/include/core/FlowFileStore.h
@@ -21,7 +21,7 @@
#include <unordered_set>
#include <utility>
-#include "FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
namespace org::apache::nifi::minifi::core {
class FlowFileStore {
diff --git a/extension-framework/include/core/StateStorage.h b/extension-framework/include/core/StateStorage.h
index ed431bb72..5e0ca80ee 100644
--- a/extension-framework/include/core/StateStorage.h
+++ b/extension-framework/include/core/StateStorage.h
@@ -22,7 +22,7 @@
#include <unordered_map>
#include "core/Core.h"
-#include "StateManager.h"
+#include "minifi-cpp/core/StateManager.h"
#include "minifi-cpp/core/StateStorage.h"
namespace org::apache::nifi::minifi::core {
diff --git a/extension-framework/include/properties/Configure.h b/extension-framework/include/properties/Configure.h
deleted file mode 100644
index d3d229d21..000000000
--- a/extension-framework/include/properties/Configure.h
+++ /dev/null
@@ -1,19 +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.
- */
-#pragma once
-
-#include "minifi-cpp/properties/Configure.h"
diff --git a/extension-framework/include/properties/Properties.h b/extension-framework/include/properties/Properties.h
deleted file mode 100644
index c1e3eca4c..000000000
--- a/extension-framework/include/properties/Properties.h
+++ /dev/null
@@ -1,19 +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.
- */
-#pragma once
-
-#include "minifi-cpp/properties/Properties.h"
diff --git a/extension-framework/include/serialization/PayloadSerializer.h b/extension-framework/include/serialization/PayloadSerializer.h
index efa3384d6..e1089a7e8 100644
--- a/extension-framework/include/serialization/PayloadSerializer.h
+++ b/extension-framework/include/serialization/PayloadSerializer.h
@@ -19,7 +19,7 @@
#pragma once
#include <memory>
-#include "io/OutputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
#include "FlowFileSerializer.h"
namespace org {
diff --git a/extension-framework/include/utils/ListingStateManager.h b/extension-framework/include/utils/ListingStateManager.h
index 1d84ade10..f028f95ae 100644
--- a/extension-framework/include/utils/ListingStateManager.h
+++ b/extension-framework/include/utils/ListingStateManager.h
@@ -25,8 +25,8 @@
#include <chrono>
#include <utility>
-#include "core/StateManager.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/StateManager.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/extension-framework/include/utils/ProcessorConfigUtils.h b/extension-framework/include/utils/ProcessorConfigUtils.h
index 0d91513f9..148435df8 100644
--- a/extension-framework/include/utils/ProcessorConfigUtils.h
+++ b/extension-framework/include/utils/ProcessorConfigUtils.h
@@ -23,7 +23,7 @@
#include <vector>
#include "core/ClassName.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "utils/Enum.h"
#include "utils/expected.h"
diff --git a/extension-framework/include/utils/ResourceQueue.h b/extension-framework/include/utils/ResourceQueue.h
index 91219602e..7f0331a33 100644
--- a/extension-framework/include/utils/ResourceQueue.h
+++ b/extension-framework/include/utils/ResourceQueue.h
@@ -27,7 +27,7 @@
#include <mutex>
#include <condition_variable>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "concurrentqueue.h"
#include "utils/MinifiConcurrentQueue.h"
diff --git a/extension-framework/include/utils/file/FileReaderCallback.h b/extension-framework/include/utils/file/FileReaderCallback.h
index 1780cbb60..2bf55cbe0 100644
--- a/extension-framework/include/utils/file/FileReaderCallback.h
+++ b/extension-framework/include/utils/file/FileReaderCallback.h
@@ -23,7 +23,7 @@
#include <string>
#include "io/StreamPipe.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/extension-framework/include/utils/net/Server.h b/extension-framework/include/utils/net/Server.h
index b36936ef6..bda53c7fa 100644
--- a/extension-framework/include/utils/net/Server.h
+++ b/extension-framework/include/utils/net/Server.h
@@ -23,7 +23,7 @@
#include "utils/Enum.h"
#include "utils/MinifiConcurrentQueue.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "asio/ts/buffer.hpp"
#include "asio/awaitable.hpp"
#include "asio/co_spawn.hpp"
diff --git a/extension-framework/include/utils/net/Ssl.h b/extension-framework/include/utils/net/Ssl.h
index b21a7352e..563d6e393 100644
--- a/extension-framework/include/utils/net/Ssl.h
+++ b/extension-framework/include/utils/net/Ssl.h
@@ -20,9 +20,9 @@
#include <memory>
#include <optional>
-#include "core/ProcessContext.h"
-#include "core/Property.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/core/Property.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "utils/Enum.h"
namespace org::apache::nifi::minifi::utils::net {
diff --git a/extension-framework/include/utils/net/UdpServer.h b/extension-framework/include/utils/net/UdpServer.h
index 510f2beaa..4fb2dcb93 100644
--- a/extension-framework/include/utils/net/UdpServer.h
+++ b/extension-framework/include/utils/net/UdpServer.h
@@ -23,7 +23,7 @@
#include "Server.h"
#include "utils/MinifiConcurrentQueue.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::utils::net {
diff --git a/extension-framework/src/controllers/keyvalue/KeyValueStateStorage.cpp b/extension-framework/src/controllers/keyvalue/KeyValueStateStorage.cpp
index 2339b3e33..26cccd547 100644
--- a/extension-framework/src/controllers/keyvalue/KeyValueStateStorage.cpp
+++ b/extension-framework/src/controllers/keyvalue/KeyValueStateStorage.cpp
@@ -17,14 +17,14 @@
#include <memory>
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "controllers/keyvalue/KeyValueStateManager.h"
#include "controllers/keyvalue/KeyValueStateStorage.h"
#include "rapidjson/rapidjson.h"
#include "rapidjson/document.h"
#include "rapidjson/stringbuffer.h"
#include "rapidjson/writer.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#undef GetObject // windows.h #defines GetObject = GetObjectA or GetObjectW, which conflicts with rapidjson
diff --git a/extension-framework/src/core/ProcessContext.cpp b/extension-framework/src/core/ProcessContext.cpp
deleted file mode 100644
index 971a6ab62..000000000
--- a/extension-framework/src/core/ProcessContext.cpp
+++ /dev/null
@@ -1,22 +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.
- */
-
-#include "minifi-cpp/core/ProcessContext.h"
-
-namespace org::apache::nifi::minifi::core {
-
-} // namespace org::apache::nifi::minifi::core
diff --git a/extension-framework/src/serialization/FlowFileV3Serializer.cpp b/extension-framework/src/serialization/FlowFileV3Serializer.cpp
index 77d327c80..972092ce4 100644
--- a/extension-framework/src/serialization/FlowFileV3Serializer.cpp
+++ b/extension-framework/src/serialization/FlowFileV3Serializer.cpp
@@ -18,8 +18,8 @@
#include "serialization/FlowFileV3Serializer.h"
#include "io/StreamPipe.h"
-#include "utils/gsl.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/core/FlowFile.h"
namespace org::apache::nifi::minifi {
@@ -84,7 +84,7 @@ int64_t FlowFileV3Serializer::serialize(const std::shared_ptr<core::FlowFile>& f
}
}
{
- const auto ret = out->write(static_cast<uint64_t>(flowFile->getSize()));
+ const auto ret = out->write(flowFile->getSize());
if (io::isError(ret)) return -1;
sum += ret;
}
diff --git a/extension-framework/src/utils/ListingStateManager.cpp b/extension-framework/src/utils/ListingStateManager.cpp
index 4657fe41f..d56a8f445 100644
--- a/extension-framework/src/utils/ListingStateManager.cpp
+++ b/extension-framework/src/utils/ListingStateManager.cpp
@@ -18,7 +18,7 @@
#include "utils/ListingStateManager.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
namespace org::apache::nifi::minifi::utils {
@@ -27,7 +27,7 @@ static const std::string LATEST_LISTED_OBJECT_TIMESTAMP = "listed_timestamp";
bool ListingState::wasObjectListedAlready(const ListedObject &object) const {
return listed_key_timestamp > object.getLastModified() ||
- (listed_key_timestamp == object.getLastModified() && listed_keys.find(object.getKey()) != listed_keys.end());
+ (listed_key_timestamp == object.getLastModified() && listed_keys.contains(object.getKey()));
}
void ListingState::updateState(const ListedObject &object) {
@@ -62,7 +62,7 @@ uint64_t ListingStateManager::getLatestListedKeyTimestampInMilliseconds(const st
std::unordered_set<std::string> ListingStateManager::getLatestListedKeys(const std::unordered_map<std::string, std::string> &state) {
std::unordered_set<std::string> latest_listed_keys;
for (const auto& kvp : state) {
- if (kvp.first.rfind(LATEST_LISTED_OBJECT_PREFIX, 0) == 0) {
+ if (kvp.first.starts_with(LATEST_LISTED_OBJECT_PREFIX)) {
latest_listed_keys.insert(kvp.second);
}
}
diff --git a/extension-framework/src/utils/net/Ssl.cpp b/extension-framework/src/utils/net/Ssl.cpp
index b40f87a55..ef482bfa6 100644
--- a/extension-framework/src/utils/net/Ssl.cpp
+++ b/extension-framework/src/utils/net/Ssl.cpp
@@ -15,7 +15,7 @@
* limitations under the License.
*/
#include "utils/net/Ssl.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
namespace org::apache::nifi::minifi::utils::net {
diff --git a/extensions/aws/AWSCredentialsProvider.cpp b/extensions/aws/AWSCredentialsProvider.cpp
index 11c82d352..06de2b3a4 100644
--- a/extensions/aws/AWSCredentialsProvider.cpp
+++ b/extensions/aws/AWSCredentialsProvider.cpp
@@ -19,7 +19,7 @@
#include "AWSCredentialsProvider.h"
#include "aws/core/auth/AWSCredentialsProviderChain.h"
-#include "properties/Properties.h"
+#include "minifi-cpp/properties/Properties.h"
namespace org::apache::nifi::minifi::aws {
diff --git a/extensions/aws/AWSCredentialsProvider.h b/extensions/aws/AWSCredentialsProvider.h
index 701b6a533..302a8407d 100644
--- a/extensions/aws/AWSCredentialsProvider.h
+++ b/extensions/aws/AWSCredentialsProvider.h
@@ -24,7 +24,7 @@
#include "aws/core/auth/AWSCredentials.h"
#include "utils/AWSInitializer.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org {
diff --git a/extensions/aws/controllerservices/AWSCredentialsService.h b/extensions/aws/controllerservices/AWSCredentialsService.h
index 473d45941..b70038177 100644
--- a/extensions/aws/controllerservices/AWSCredentialsService.h
+++ b/extensions/aws/controllerservices/AWSCredentialsService.h
@@ -28,7 +28,7 @@
#include "utils/AWSInitializer.h"
#include "core/controller/ControllerService.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "AWSCredentialsProvider.h"
diff --git a/extensions/aws/processors/AwsProcessor.cpp b/extensions/aws/processors/AwsProcessor.cpp
index 5e7ef1e14..6c0a1b19e 100644
--- a/extensions/aws/processors/AwsProcessor.cpp
+++ b/extensions/aws/processors/AwsProcessor.cpp
@@ -23,8 +23,8 @@
#include "controllerservices/AWSCredentialsService.h"
#include "S3Wrapper.h"
-#include "core/ProcessContext.h"
-#include "properties/Properties.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/properties/Properties.h"
#include "range/v3/algorithm/contains.hpp"
#include "utils/HTTPUtils.h"
#include "utils/StringUtils.h"
diff --git a/extensions/aws/processors/AwsProcessor.h b/extensions/aws/processors/AwsProcessor.h
index f8ed99608..3637fdc34 100644
--- a/extensions/aws/processors/AwsProcessor.h
+++ b/extensions/aws/processors/AwsProcessor.h
@@ -29,7 +29,7 @@
#include "aws/core/auth/AWSCredentialsProvider.h"
#include "AWSCredentialsProvider.h"
#include "utils/ProxyOptions.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "core/ProcessorImpl.h"
diff --git a/extensions/aws/processors/DeleteS3Object.cpp b/extensions/aws/processors/DeleteS3Object.cpp
index 84b375e6e..a921dc1ca 100644
--- a/extensions/aws/processors/DeleteS3Object.cpp
+++ b/extensions/aws/processors/DeleteS3Object.cpp
@@ -20,7 +20,7 @@
#include <set>
#include <memory>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
diff --git a/extensions/aws/processors/DeleteS3Object.h b/extensions/aws/processors/DeleteS3Object.h
index 1aa9c8075..7ac4269ba 100644
--- a/extensions/aws/processors/DeleteS3Object.h
+++ b/extensions/aws/processors/DeleteS3Object.h
@@ -23,7 +23,7 @@
#include <string>
#include <utility>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "S3Processor.h"
#include "utils/ArrayUtils.h"
diff --git a/extensions/aws/processors/FetchS3Object.cpp b/extensions/aws/processors/FetchS3Object.cpp
index 9a7bb0ec4..b04570119 100644
--- a/extensions/aws/processors/FetchS3Object.cpp
+++ b/extensions/aws/processors/FetchS3Object.cpp
@@ -20,7 +20,7 @@
#include <memory>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/OptionalUtils.h"
diff --git a/extensions/aws/processors/FetchS3Object.h b/extensions/aws/processors/FetchS3Object.h
index c703821fc..0b4a638bb 100644
--- a/extensions/aws/processors/FetchS3Object.h
+++ b/extensions/aws/processors/FetchS3Object.h
@@ -24,7 +24,7 @@
#include <utility>
#include <vector>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "io/StreamPipe.h"
diff --git a/extensions/aws/processors/ListS3.cpp b/extensions/aws/processors/ListS3.cpp
index f11bca209..7c0524bd0 100644
--- a/extensions/aws/processors/ListS3.cpp
+++ b/extensions/aws/processors/ListS3.cpp
@@ -21,7 +21,7 @@
#include <memory>
#include <utility>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/aws/processors/ListS3.h b/extensions/aws/processors/ListS3.h
index f54810d40..7d37cc2be 100644
--- a/extensions/aws/processors/ListS3.h
+++ b/extensions/aws/processors/ListS3.h
@@ -24,7 +24,7 @@
#include <tuple>
#include <memory>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "S3Processor.h"
diff --git a/extensions/aws/processors/PutKinesisStream.cpp b/extensions/aws/processors/PutKinesisStream.cpp
index e34b79ea5..3b94c4b64 100644
--- a/extensions/aws/processors/PutKinesisStream.cpp
+++ b/extensions/aws/processors/PutKinesisStream.cpp
@@ -24,7 +24,7 @@
#include "aws/kinesis/KinesisClient.h"
#include "aws/kinesis/model/PutRecordsRequest.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "range/v3/algorithm/for_each.hpp"
diff --git a/extensions/aws/processors/PutS3Object.cpp b/extensions/aws/processors/PutS3Object.cpp
index ddb218f98..68ddd5e47 100644
--- a/extensions/aws/processors/PutS3Object.cpp
+++ b/extensions/aws/processors/PutS3Object.cpp
@@ -21,10 +21,10 @@
#include <memory>
#include "AWSCredentialsService.h"
-#include "properties/Properties.h"
+#include "minifi-cpp/properties/Properties.h"
#include "utils/StringUtils.h"
#include "utils/MapUtils.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "range/v3/algorithm/contains.hpp"
@@ -69,13 +69,13 @@ void PutS3Object::onSchedule(core::ProcessContext& context, core::ProcessSession
}
multipart_threshold_ = context.getProperty(MultipartThreshold)
- | minifi::utils::andThen([&](const auto str) { return parsing::parseDataSizeMinMax(str, getMinPartSize(), getMaxUploadSize()); })
+ | minifi::utils::andThen([&](const auto& str) { return parsing::parseDataSizeMinMax(str, getMinPartSize(), getMaxUploadSize()); })
| minifi::utils::orThrow("Multipart Part Size is not between the valid 5MB and 5GB range!");
logger_->log_debug("PutS3Object: Multipart Threshold {}", multipart_threshold_);
multipart_size_ = context.getProperty(MultipartPartSize)
- | minifi::utils::andThen([&](const auto str) { return parsing::parseDataSizeMinMax(str, getMinPartSize(), getMaxUploadSize()); })
+ | minifi::utils::andThen([&](const auto& str) { return parsing::parseDataSizeMinMax(str, getMinPartSize(), getMaxUploadSize()); })
| minifi::utils::orThrow("Multipart Part Size is not between the valid 5MB and 5GB range!");
diff --git a/extensions/aws/processors/PutS3Object.h b/extensions/aws/processors/PutS3Object.h
index 912c45b7d..9ecdc01a6 100644
--- a/extensions/aws/processors/PutS3Object.h
+++ b/extensions/aws/processors/PutS3Object.h
@@ -28,13 +28,13 @@
#include <vector>
#include <chrono>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "io/StreamPipe.h"
#include "S3Processor.h"
#include "utils/ArrayUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/Id.h"
#include "utils/Enum.h"
diff --git a/extensions/aws/processors/S3Processor.cpp b/extensions/aws/processors/S3Processor.cpp
index 44e08e08e..e09c477dd 100644
--- a/extensions/aws/processors/S3Processor.cpp
+++ b/extensions/aws/processors/S3Processor.cpp
@@ -23,8 +23,7 @@
#include "AWSCredentialsService.h"
#include "S3Wrapper.h"
-#include "core/ProcessContext.h"
-#include "properties/Properties.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "range/v3/algorithm/contains.hpp"
#include "utils/HTTPUtils.h"
#include "utils/StringUtils.h"
diff --git a/extensions/aws/processors/S3Processor.h b/extensions/aws/processors/S3Processor.h
index 6d31d1eee..8dbc75f39 100644
--- a/extensions/aws/processors/S3Processor.h
+++ b/extensions/aws/processors/S3Processor.h
@@ -30,10 +30,10 @@
#include "AwsProcessor.h"
#include "S3Wrapper.h"
#include "aws/core/auth/AWSCredentialsProvider.h"
-#include "core/Property.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "utils/OptionalUtils.h"
diff --git a/extensions/aws/s3/MultipartUploadStateStorage.cpp b/extensions/aws/s3/MultipartUploadStateStorage.cpp
index ede5bf9e3..62ca31da6 100644
--- a/extensions/aws/s3/MultipartUploadStateStorage.cpp
+++ b/extensions/aws/s3/MultipartUploadStateStorage.cpp
@@ -17,7 +17,7 @@
#include "MultipartUploadStateStorage.h"
#include "utils/StringUtils.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
namespace org::apache::nifi::minifi::aws::s3 {
diff --git a/extensions/aws/s3/MultipartUploadStateStorage.h b/extensions/aws/s3/MultipartUploadStateStorage.h
index 10360d305..65eb03d40 100644
--- a/extensions/aws/s3/MultipartUploadStateStorage.h
+++ b/extensions/aws/s3/MultipartUploadStateStorage.h
@@ -26,12 +26,12 @@
#include <mutex>
#include <unordered_map>
-#include "core/StateManager.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/StateManager.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "aws/core/utils/DateTime.h"
#include "utils/file/FileUtils.h"
-#include "properties/Configure.h"
+#include "minifi-cpp/properties/Configure.h"
namespace org::apache::nifi::minifi::aws::s3 {
diff --git a/extensions/aws/s3/S3RequestSender.h b/extensions/aws/s3/S3RequestSender.h
index 0c92ad117..1a1fbee90 100644
--- a/extensions/aws/s3/S3RequestSender.h
+++ b/extensions/aws/s3/S3RequestSender.h
@@ -47,7 +47,7 @@
#include "aws/s3/model/ListMultipartUploadsResult.h"
#include "aws/s3/model/AbortMultipartUploadRequest.h"
#include "aws/s3/model/AbortMultipartUploadResult.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "utils/AWSInitializer.h"
diff --git a/extensions/aws/s3/S3Wrapper.cpp b/extensions/aws/s3/S3Wrapper.cpp
index 70972bbea..7b3b80749 100644
--- a/extensions/aws/s3/S3Wrapper.cpp
+++ b/extensions/aws/s3/S3Wrapper.cpp
@@ -26,7 +26,7 @@
#include "utils/ArrayUtils.h"
#include "utils/StringUtils.h"
#include "utils/file/FileUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/RegexUtils.h"
#include "aws/core/utils/HashingUtils.h"
#include "range/v3/algorithm/any_of.hpp"
diff --git a/extensions/aws/s3/S3Wrapper.h b/extensions/aws/s3/S3Wrapper.h
index 76756da09..ab92e8b4e 100644
--- a/extensions/aws/s3/S3Wrapper.h
+++ b/extensions/aws/s3/S3Wrapper.h
@@ -27,7 +27,7 @@
#include <utility>
#include <vector>
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "MultipartUploadStateStorage.h"
#include "S3RequestSender.h"
#include "aws/s3/model/ObjectCannedACL.h"
@@ -35,17 +35,17 @@
#include "aws/s3/model/StorageClass.h"
#include "aws/s3/model/ChecksumAlgorithm.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "io/InputStream.h"
-#include "io/OutputStream.h"
+#include "minifi-cpp/io/InputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
#include "range/v3/algorithm/find.hpp"
#include "utils/AWSInitializer.h"
#include "utils/ConfigurationUtils.h"
#include "utils/ListingStateManager.h"
#include "utils/OptionalUtils.h"
#include "utils/StringUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ProxyOptions.h"
namespace org::apache::nifi::minifi::aws::s3 {
diff --git a/extensions/aws/tests/AWSCredentialsServiceTest.cpp b/extensions/aws/tests/AWSCredentialsServiceTest.cpp
index ccaf91aef..d6377c8d0 100644
--- a/extensions/aws/tests/AWSCredentialsServiceTest.cpp
+++ b/extensions/aws/tests/AWSCredentialsServiceTest.cpp
@@ -23,7 +23,7 @@
#include "unit/Catch.h"
#include "controllerservices/AWSCredentialsService.h"
#include "unit/TestUtils.h"
-#include "core/controller/ControllerServiceNode.h"
+#include "minifi-cpp/core/controller/ControllerServiceNode.h"
class AWSCredentialsServiceTestAccessor {
public:
diff --git a/extensions/aws/utils/AWSSdkLogger.cpp b/extensions/aws/utils/AWSSdkLogger.cpp
index 1514c3f31..fd8a5d9c3 100644
--- a/extensions/aws/utils/AWSSdkLogger.cpp
+++ b/extensions/aws/utils/AWSSdkLogger.cpp
@@ -21,7 +21,7 @@
#include <cstdarg>
#include "aws/core/utils/logging/LogLevel.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::aws::utils {
diff --git a/extensions/aws/utils/AWSSdkLogger.h b/extensions/aws/utils/AWSSdkLogger.h
index af8b2529d..b6d310861 100644
--- a/extensions/aws/utils/AWSSdkLogger.h
+++ b/extensions/aws/utils/AWSSdkLogger.h
@@ -20,7 +20,7 @@
#include <memory>
#include "aws/core/utils/logging/LogSystemInterface.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::aws::utils {
diff --git a/extensions/azure/controllerservices/AzureStorageCredentialsService.h b/extensions/azure/controllerservices/AzureStorageCredentialsService.h
index 4662bd630..b93d42b22 100644
--- a/extensions/azure/controllerservices/AzureStorageCredentialsService.h
+++ b/extensions/azure/controllerservices/AzureStorageCredentialsService.h
@@ -24,11 +24,11 @@
#include "core/controller/ControllerService.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "storage/AzureStorageCredentials.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/AzureEnums.h"
namespace org::apache::nifi::minifi::azure::controllers {
diff --git a/extensions/azure/processors/AzureBlobStorageProcessorBase.cpp b/extensions/azure/processors/AzureBlobStorageProcessorBase.cpp
index 88ae2a2e9..25355e704 100644
--- a/extensions/azure/processors/AzureBlobStorageProcessorBase.cpp
+++ b/extensions/azure/processors/AzureBlobStorageProcessorBase.cpp
@@ -20,7 +20,7 @@
#include "AzureBlobStorageProcessorBase.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "utils/ProcessorConfigUtils.h"
namespace org::apache::nifi::minifi::azure::processors {
diff --git a/extensions/azure/processors/AzureBlobStorageProcessorBase.h b/extensions/azure/processors/AzureBlobStorageProcessorBase.h
index 88c09bd75..959a023de 100644
--- a/extensions/azure/processors/AzureBlobStorageProcessorBase.h
+++ b/extensions/azure/processors/AzureBlobStorageProcessorBase.h
@@ -25,10 +25,10 @@
#include <string>
#include <utility>
-#include "core/Property.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "storage/AzureBlobStorage.h"
#include "AzureStorageProcessorBase.h"
#include "storage/AzureStorageCredentials.h"
diff --git a/extensions/azure/processors/AzureBlobStorageSingleBlobProcessorBase.cpp b/extensions/azure/processors/AzureBlobStorageSingleBlobProcessorBase.cpp
index 2f2351c1c..f9d27478b 100644
--- a/extensions/azure/processors/AzureBlobStorageSingleBlobProcessorBase.cpp
+++ b/extensions/azure/processors/AzureBlobStorageSingleBlobProcessorBase.cpp
@@ -20,7 +20,7 @@
#include "AzureBlobStorageSingleBlobProcessorBase.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
namespace org::apache::nifi::minifi::azure::processors {
diff --git a/extensions/azure/processors/AzureBlobStorageSingleBlobProcessorBase.h b/extensions/azure/processors/AzureBlobStorageSingleBlobProcessorBase.h
index 0e2b08466..abf4ba711 100644
--- a/extensions/azure/processors/AzureBlobStorageSingleBlobProcessorBase.h
+++ b/extensions/azure/processors/AzureBlobStorageSingleBlobProcessorBase.h
@@ -26,7 +26,7 @@
#include <utility>
#include "AzureBlobStorageProcessorBase.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "utils/ArrayUtils.h"
namespace org::apache::nifi::minifi::azure::processors {
diff --git a/extensions/azure/processors/AzureDataLakeStorageFileProcessorBase.h b/extensions/azure/processors/AzureDataLakeStorageFileProcessorBase.h
index f45608319..e34c2836f 100644
--- a/extensions/azure/processors/AzureDataLakeStorageFileProcessorBase.h
+++ b/extensions/azure/processors/AzureDataLakeStorageFileProcessorBase.h
@@ -22,7 +22,7 @@
#include <memory>
#include "AzureDataLakeStorageProcessorBase.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "utils/ArrayUtils.h"
diff --git a/extensions/azure/processors/AzureDataLakeStorageProcessorBase.h b/extensions/azure/processors/AzureDataLakeStorageProcessorBase.h
index 3a3e2b07b..dc2f55f3e 100644
--- a/extensions/azure/processors/AzureDataLakeStorageProcessorBase.h
+++ b/extensions/azure/processors/AzureDataLakeStorageProcessorBase.h
@@ -25,9 +25,9 @@
#include <memory>
#include <optional>
-#include "core/Property.h"
-#include "core/PropertyDefinition.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "storage/AzureDataLakeStorage.h"
#include "utils/ArrayUtils.h"
diff --git a/extensions/azure/processors/AzureStorageProcessorBase.cpp b/extensions/azure/processors/AzureStorageProcessorBase.cpp
index 9844a390e..7795a4786 100644
--- a/extensions/azure/processors/AzureStorageProcessorBase.cpp
+++ b/extensions/azure/processors/AzureStorageProcessorBase.cpp
@@ -23,7 +23,7 @@
#include <memory>
#include <string>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "controllerservices/AzureStorageCredentialsService.h"
namespace org::apache::nifi::minifi::azure::processors {
diff --git a/extensions/azure/processors/AzureStorageProcessorBase.h b/extensions/azure/processors/AzureStorageProcessorBase.h
index 5eb0b07b1..8f98f72a0 100644
--- a/extensions/azure/processors/AzureStorageProcessorBase.h
+++ b/extensions/azure/processors/AzureStorageProcessorBase.h
@@ -26,11 +26,11 @@
#include <utility>
#include <tuple>
-#include "core/PropertyDefinition.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
+#include "minifi-cpp/core/Property.h"
#include "core/PropertyDefinitionBuilder.h"
#include "core/ProcessorImpl.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "storage/AzureStorageCredentials.h"
namespace org::apache::nifi::minifi::azure::processors {
diff --git a/extensions/azure/processors/DeleteAzureBlobStorage.h b/extensions/azure/processors/DeleteAzureBlobStorage.h
index 890d9f19d..dde252383 100644
--- a/extensions/azure/processors/DeleteAzureBlobStorage.h
+++ b/extensions/azure/processors/DeleteAzureBlobStorage.h
@@ -26,8 +26,8 @@
#include <utility>
#include <vector>
-#include "core/Property.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "AzureBlobStorageSingleBlobProcessorBase.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extensions/azure/processors/DeleteAzureDataLakeStorage.cpp b/extensions/azure/processors/DeleteAzureDataLakeStorage.cpp
index 71483585f..6ad257717 100644
--- a/extensions/azure/processors/DeleteAzureDataLakeStorage.cpp
+++ b/extensions/azure/processors/DeleteAzureDataLakeStorage.cpp
@@ -21,7 +21,7 @@
#include "DeleteAzureDataLakeStorage.h"
#include "utils/ProcessorConfigUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
diff --git a/extensions/azure/processors/FetchAzureBlobStorage.h b/extensions/azure/processors/FetchAzureBlobStorage.h
index c9e1ee601..d3d9a9bee 100644
--- a/extensions/azure/processors/FetchAzureBlobStorage.h
+++ b/extensions/azure/processors/FetchAzureBlobStorage.h
@@ -26,8 +26,8 @@
#include <utility>
#include <vector>
-#include "core/PropertyDefinition.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
+#include "minifi-cpp/core/Property.h"
#include "AzureBlobStorageSingleBlobProcessorBase.h"
#include "core/logging/LoggerFactory.h"
#include "utils/ArrayUtils.h"
diff --git a/extensions/azure/processors/FetchAzureDataLakeStorage.cpp b/extensions/azure/processors/FetchAzureDataLakeStorage.cpp
index 4dffd0392..fa51c21f4 100644
--- a/extensions/azure/processors/FetchAzureDataLakeStorage.cpp
+++ b/extensions/azure/processors/FetchAzureDataLakeStorage.cpp
@@ -20,7 +20,7 @@
#include "FetchAzureDataLakeStorage.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
@@ -40,17 +40,17 @@ std::optional<storage::FetchAzureDataLakeStorageParameters> FetchAzureDataLakeSt
}
if (auto range_start = utils::parseOptionalU64Property(context, RangeStart, &flow_file)) {
- params.range_start = *range_start;
+ params.range_start = range_start;
logger_->log_debug("Range Start property set to {}", *params.range_start);
}
if (auto range_length = utils::parseOptionalU64Property(context, RangeLength, &flow_file)) {
- params.range_length = *range_length;
+ params.range_length = range_length;
logger_->log_debug("Range Length property set to {}", *params.range_length);
}
if (auto number_of_retries = utils::parseOptionalU64Property(context, NumberOfRetries, &flow_file)) {
- params.number_of_retries = *number_of_retries;
+ params.number_of_retries = number_of_retries;
logger_->log_debug("Number Of Retries property set to {}", *params.number_of_retries);
}
diff --git a/extensions/azure/processors/FetchAzureDataLakeStorage.h b/extensions/azure/processors/FetchAzureDataLakeStorage.h
index f7ab3a11d..15a780abf 100644
--- a/extensions/azure/processors/FetchAzureDataLakeStorage.h
+++ b/extensions/azure/processors/FetchAzureDataLakeStorage.h
@@ -21,7 +21,7 @@
#include <utility>
#include <memory>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "io/StreamPipe.h"
#include "utils/ArrayUtils.h"
diff --git a/extensions/azure/processors/ListAzureBlobStorage.h b/extensions/azure/processors/ListAzureBlobStorage.h
index cfe630bf6..a387d01d2 100644
--- a/extensions/azure/processors/ListAzureBlobStorage.h
+++ b/extensions/azure/processors/ListAzureBlobStorage.h
@@ -26,8 +26,8 @@
#include <utility>
#include <vector>
-#include "core/Property.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "AzureBlobStorageProcessorBase.h"
#include "core/logging/LoggerFactory.h"
#include "utils/AzureEnums.h"
diff --git a/extensions/azure/processors/PutAzureBlobStorage.cpp b/extensions/azure/processors/PutAzureBlobStorage.cpp
index fd3576641..bf53b1bf1 100644
--- a/extensions/azure/processors/PutAzureBlobStorage.cpp
+++ b/extensions/azure/processors/PutAzureBlobStorage.cpp
@@ -20,7 +20,7 @@
#include "PutAzureBlobStorage.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/azure/processors/PutAzureBlobStorage.h b/extensions/azure/processors/PutAzureBlobStorage.h
index 4c1f9d6ab..06d3dfaa5 100644
--- a/extensions/azure/processors/PutAzureBlobStorage.h
+++ b/extensions/azure/processors/PutAzureBlobStorage.h
@@ -26,10 +26,10 @@
#include <utility>
#include <vector>
-#include "core/ProcessContext.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/logging/LoggerFactory.h"
#include "AzureBlobStorageSingleBlobProcessorBase.h"
#include "io/StreamPipe.h"
diff --git a/extensions/azure/processors/PutAzureDataLakeStorage.cpp b/extensions/azure/processors/PutAzureDataLakeStorage.cpp
index c1531de2c..95c591d84 100644
--- a/extensions/azure/processors/PutAzureDataLakeStorage.cpp
+++ b/extensions/azure/processors/PutAzureDataLakeStorage.cpp
@@ -23,7 +23,7 @@
#include <vector>
#include "utils/ProcessorConfigUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
diff --git a/extensions/azure/processors/PutAzureDataLakeStorage.h b/extensions/azure/processors/PutAzureDataLakeStorage.h
index e1bac70cc..4cdd012c8 100644
--- a/extensions/azure/processors/PutAzureDataLakeStorage.h
+++ b/extensions/azure/processors/PutAzureDataLakeStorage.h
@@ -27,10 +27,10 @@
#include "AzureDataLakeStorageFileProcessorBase.h"
#include "io/StreamPipe.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/ArrayUtils.h"
#include "utils/Enum.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
template<typename AzureDataLakeStorageProcessor>
class AzureDataLakeStorageTestsFixture;
diff --git a/extensions/azure/storage/AzureBlobStorage.h b/extensions/azure/storage/AzureBlobStorage.h
index 51b0d6e1e..c1b2acfd7 100644
--- a/extensions/azure/storage/AzureBlobStorage.h
+++ b/extensions/azure/storage/AzureBlobStorage.h
@@ -26,11 +26,11 @@
#include "BlobStorageClient.h"
#include "azure/storage/blobs.hpp"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ListingStateManager.h"
-#include "io/OutputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
namespace org::apache::nifi::minifi::azure::storage {
diff --git a/extensions/azure/storage/AzureBlobStorageClient.cpp b/extensions/azure/storage/AzureBlobStorageClient.cpp
index be6186a7f..837efa4ac 100644
--- a/extensions/azure/storage/AzureBlobStorageClient.cpp
+++ b/extensions/azure/storage/AzureBlobStorageClient.cpp
@@ -27,6 +27,7 @@
#include "utils/AzureSdkLogger.h"
#include "utils/span.h"
+#include "io/InputStream.h"
namespace org::apache::nifi::minifi::azure::storage {
diff --git a/extensions/azure/storage/AzureBlobStorageClient.h b/extensions/azure/storage/AzureBlobStorageClient.h
index 89c42c434..2b67c7635 100644
--- a/extensions/azure/storage/AzureBlobStorageClient.h
+++ b/extensions/azure/storage/AzureBlobStorageClient.h
@@ -27,7 +27,7 @@
#include "BlobStorageClient.h"
#include "azure/storage/blobs.hpp"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::azure::storage {
diff --git a/extensions/azure/storage/AzureDataLakeStorage.cpp b/extensions/azure/storage/AzureDataLakeStorage.cpp
index 6906dcc6c..cb55dc1a8 100644
--- a/extensions/azure/storage/AzureDataLakeStorage.cpp
+++ b/extensions/azure/storage/AzureDataLakeStorage.cpp
@@ -26,7 +26,7 @@
#include "io/StreamPipe.h"
#include "utils/file/FileUtils.h"
#include "utils/StringUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/GeneralUtils.h"
#include "utils/RegexUtils.h"
diff --git a/extensions/azure/storage/AzureDataLakeStorage.h b/extensions/azure/storage/AzureDataLakeStorage.h
index fcfbe1c5d..f7443c928 100644
--- a/extensions/azure/storage/AzureDataLakeStorage.h
+++ b/extensions/azure/storage/AzureDataLakeStorage.h
@@ -25,11 +25,11 @@
#include <optional>
#include <utility>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "DataLakeStorageClient.h"
#include "utils/ListingStateManager.h"
-#include "io/OutputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
namespace org::apache::nifi::minifi::azure::storage {
diff --git a/extensions/azure/storage/AzureDataLakeStorageClient.h b/extensions/azure/storage/AzureDataLakeStorageClient.h
index db11cbdd4..9c9615869 100644
--- a/extensions/azure/storage/AzureDataLakeStorageClient.h
+++ b/extensions/azure/storage/AzureDataLakeStorageClient.h
@@ -27,9 +27,10 @@
#include <azure/storage/files/datalake.hpp>
#include "DataLakeStorageClient.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "utils/span.h"
+#include "io/InputStream.h"
namespace org::apache::nifi::minifi::azure::storage {
diff --git a/extensions/azure/storage/BlobStorageClient.h b/extensions/azure/storage/BlobStorageClient.h
index 4f28e1acc..007b3b86f 100644
--- a/extensions/azure/storage/BlobStorageClient.h
+++ b/extensions/azure/storage/BlobStorageClient.h
@@ -27,9 +27,9 @@
#include "azure/storage/blobs/blob_responses.hpp"
#include "AzureStorageCredentials.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/Enum.h"
-#include "io/InputStream.h"
+#include "minifi-cpp/io/InputStream.h"
namespace org::apache::nifi::minifi::azure::storage {
diff --git a/extensions/azure/storage/DataLakeStorageClient.h b/extensions/azure/storage/DataLakeStorageClient.h
index 839302da7..06445a2e8 100644
--- a/extensions/azure/storage/DataLakeStorageClient.h
+++ b/extensions/azure/storage/DataLakeStorageClient.h
@@ -26,8 +26,8 @@
#include "AzureStorageCredentials.h"
-#include "utils/gsl.h"
-#include "io/InputStream.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/io/InputStream.h"
#include "azure/storage/files/datalake/datalake_responses.hpp"
#include "utils/Enum.h"
#include "utils/RegexUtils.h"
diff --git a/extensions/azure/utils/AzureSdkLogger.h b/extensions/azure/utils/AzureSdkLogger.h
index ce67b1472..3e4c93a48 100644
--- a/extensions/azure/utils/AzureSdkLogger.h
+++ b/extensions/azure/utils/AzureSdkLogger.h
@@ -21,7 +21,7 @@
#include <memory>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::azure::utils {
diff --git a/extensions/bustache/ApplyTemplate.cpp b/extensions/bustache/ApplyTemplate.cpp
index 6764aa842..b178a2649 100644
--- a/extensions/bustache/ApplyTemplate.cpp
+++ b/extensions/bustache/ApplyTemplate.cpp
@@ -27,7 +27,7 @@
#include "bustache/model.hpp"
#include "bustache/render/string.hpp"
#include "core/Resource.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/bustache/tests/ApplyTemplateTests.cpp b/extensions/bustache/tests/ApplyTemplateTests.cpp
index 0f697d741..3af56c297 100644
--- a/extensions/bustache/tests/ApplyTemplateTests.cpp
+++ b/extensions/bustache/tests/ApplyTemplateTests.cpp
@@ -26,7 +26,7 @@
#include "unit/Catch.h"
#include "core/Core.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/Processor.h"
#include "core/ProcessSession.h"
#include "repository/VolatileContentRepository.h"
diff --git a/extensions/civetweb/processors/ListenHTTP.cpp b/extensions/civetweb/processors/ListenHTTP.cpp
index e3d7f18b1..982c30b79 100644
--- a/extensions/civetweb/processors/ListenHTTP.cpp
+++ b/extensions/civetweb/processors/ListenHTTP.cpp
@@ -27,8 +27,9 @@
#include <vector>
#include "core/Resource.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ProcessorConfigUtils.h"
+#include "io/StreamPipe.h"
namespace org::apache::nifi::minifi::processors {
@@ -485,7 +486,7 @@ void ListenHTTP::Handler::writeBody(core::ProcessSession* payload_reader, mg_con
}
bool ListenHTTP::isSecure() const {
- return (listeningPort.length() > 0) && *listeningPort.rbegin() == 's';
+ return !listeningPort.empty() && *listeningPort.rbegin() == 's';
}
std::string ListenHTTP::getPort() const {
diff --git a/extensions/civetweb/processors/ListenHTTP.h b/extensions/civetweb/processors/ListenHTTP.h
index 06da14e1b..5952d3236 100644
--- a/extensions/civetweb/processors/ListenHTTP.h
+++ b/extensions/civetweb/processors/ListenHTTP.h
@@ -23,20 +23,21 @@
#include <memory>
#include <string>
#include <utility>
+#include <future>
#include <CivetServer.h>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
#include "utils/MinifiConcurrentQueue.h"
-#include "utils/gsl.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/RegexUtils.h"
#include "core/FlowFileStore.h"
#include "core/ProcessorImpl.h"
diff --git a/extensions/civetweb/tests/HttpPostIntegrationTest.cpp b/extensions/civetweb/tests/HttpPostIntegrationTest.cpp
index 8262fce34..e61a4e5f9 100644
--- a/extensions/civetweb/tests/HttpPostIntegrationTest.cpp
+++ b/extensions/civetweb/tests/HttpPostIntegrationTest.cpp
@@ -21,7 +21,7 @@
#include "processors/InvokeHTTP.h"
#include "processors/LogAttribute.h"
#include "unit/TestBase.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/ProcessGroup.h"
#include "FlowController.h"
#include "integration/HTTPIntegrationBase.h"
diff --git a/extensions/couchbase/controllerservices/CouchbaseClusterService.cpp b/extensions/couchbase/controllerservices/CouchbaseClusterService.cpp
index 9a04a7688..6c773a463 100644
--- a/extensions/couchbase/controllerservices/CouchbaseClusterService.cpp
+++ b/extensions/couchbase/controllerservices/CouchbaseClusterService.cpp
@@ -23,6 +23,7 @@
#include "couchbase/codec/raw_json_transcoder.hxx"
#include "couchbase/codec/raw_string_transcoder.hxx"
#include "utils/TimeUtil.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::couchbase {
diff --git a/extensions/couchbase/controllerservices/CouchbaseClusterService.h b/extensions/couchbase/controllerservices/CouchbaseClusterService.h
index 8e9040411..f443b1ee6 100644
--- a/extensions/couchbase/controllerservices/CouchbaseClusterService.h
+++ b/extensions/couchbase/controllerservices/CouchbaseClusterService.h
@@ -25,13 +25,13 @@
#include <variant>
#include "core/controller/ControllerService.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "couchbase/cluster.hxx"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/logging/LoggerFactory.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
namespace org::apache::nifi::minifi::couchbase {
diff --git a/extensions/couchbase/processors/GetCouchbaseKey.cpp b/extensions/couchbase/processors/GetCouchbaseKey.cpp
index fd983c36d..71744c13a 100644
--- a/extensions/couchbase/processors/GetCouchbaseKey.cpp
+++ b/extensions/couchbase/processors/GetCouchbaseKey.cpp
@@ -18,7 +18,7 @@
#include "GetCouchbaseKey.h"
#include "CouchbaseClusterService.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/couchbase/processors/PutCouchbaseKey.cpp b/extensions/couchbase/processors/PutCouchbaseKey.cpp
index 04acd4033..e83f0169a 100644
--- a/extensions/couchbase/processors/PutCouchbaseKey.cpp
+++ b/extensions/couchbase/processors/PutCouchbaseKey.cpp
@@ -18,7 +18,7 @@
#include "PutCouchbaseKey.h"
#include "CouchbaseClusterService.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/elasticsearch/ElasticsearchCredentialsControllerService.h b/extensions/elasticsearch/ElasticsearchCredentialsControllerService.h
index 4f41c74cf..00c42cce7 100644
--- a/extensions/elasticsearch/ElasticsearchCredentialsControllerService.h
+++ b/extensions/elasticsearch/ElasticsearchCredentialsControllerService.h
@@ -24,7 +24,7 @@
#include "http/HTTPClient.h"
#include "core/controller/ControllerService.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "utils/Enum.h"
diff --git a/extensions/elasticsearch/PostElasticsearch.cpp b/extensions/elasticsearch/PostElasticsearch.cpp
index 8424ba35a..b734f4306 100644
--- a/extensions/elasticsearch/PostElasticsearch.cpp
+++ b/extensions/elasticsearch/PostElasticsearch.cpp
@@ -20,7 +20,7 @@
#include <utility>
#include <vector>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "rapidjson/document.h"
diff --git a/extensions/elasticsearch/PostElasticsearch.h b/extensions/elasticsearch/PostElasticsearch.h
index 9397d7747..00894f4f5 100644
--- a/extensions/elasticsearch/PostElasticsearch.h
+++ b/extensions/elasticsearch/PostElasticsearch.h
@@ -22,13 +22,13 @@
#include <memory>
#include <vector>
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "ElasticsearchCredentialsControllerService.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/Enum.h"
#include "http/HTTPClient.h"
diff --git a/extensions/elasticsearch/tests/MockElastic.h b/extensions/elasticsearch/tests/MockElastic.h
index 71e60dadf..85dfad6b5 100644
--- a/extensions/elasticsearch/tests/MockElastic.h
+++ b/extensions/elasticsearch/tests/MockElastic.h
@@ -23,7 +23,7 @@
#include <vector>
#include <CivetServer.h>
#include "integration/CivetLibrary.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "rapidjson/document.h"
#include "rapidjson/writer.h"
diff --git a/extensions/elasticsearch/tests/PostElasticsearchTests.cpp b/extensions/elasticsearch/tests/PostElasticsearchTests.cpp
index 83d1f6555..d29caa35a 100644
--- a/extensions/elasticsearch/tests/PostElasticsearchTests.cpp
+++ b/extensions/elasticsearch/tests/PostElasticsearchTests.cpp
@@ -20,7 +20,7 @@
#include "MockElastic.h"
#include "unit/SingleProcessorTestController.h"
#include "unit/Catch.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "unit/TestUtils.h"
namespace org::apache::nifi::minifi::extensions::elasticsearch::test {
diff --git a/extensions/execute-process/ExecuteProcess.cpp b/extensions/execute-process/ExecuteProcess.cpp
index a569ee083..03e696a26 100644
--- a/extensions/execute-process/ExecuteProcess.cpp
+++ b/extensions/execute-process/ExecuteProcess.cpp
@@ -26,14 +26,14 @@
#include <memory>
#include <string>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "core/TypedValues.h"
#include "utils/ConfigurationUtils.h"
#include "utils/Environment.h"
#include "utils/StringUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ProcessorConfigUtils.h"
using namespace std::literals::chrono_literals;
@@ -158,7 +158,7 @@ void ExecuteProcess::readOutput(core::ProcessSession& session) const {
std::shared_ptr<core::FlowFile> flow_file;
auto num_read = read(pipefd_[0], buf_ptr, buffer.size());
while (num_read > 0) {
- if (num_read == static_cast<ssize_t>(buffer.size() - read_to_buffer)) {
+ if (num_read == static_cast<ssize_t>(buffer.size() - read_to_buffer)) { // NOLINT(modernize-use-integer-sign-comparison)
// we reach the max buffer size
logger_->log_debug("Execute Command Max Respond {}", buffer.size());
if (!writeToFlowFile(session, flow_file, buffer)) {
diff --git a/extensions/execute-process/ExecuteProcess.h b/extensions/execute-process/ExecuteProcess.h
index c8b186afd..62db144c2 100644
--- a/extensions/execute-process/ExecuteProcess.h
+++ b/extensions/execute-process/ExecuteProcess.h
@@ -38,11 +38,11 @@
#include "core/logging/LoggerFactory.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/FlowFileRecord.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/expression-language/impl/expression/Expression.h b/extensions/expression-language/impl/expression/Expression.h
index e87a1863a..db113b817 100644
--- a/extensions/expression-language/impl/expression/Expression.h
+++ b/extensions/expression-language/impl/expression/Expression.h
@@ -25,7 +25,7 @@
#include "common/Value.h"
#include "FlowFile.h"
-#include "core/VariableRegistry.h"
+#include "minifi-cpp/core/VariableRegistry.h"
namespace org::apache::nifi::minifi::expression {
diff --git a/extensions/expression-language/tests/ExpressionLanguageTests.cpp b/extensions/expression-language/tests/ExpressionLanguageTests.cpp
index a8cb42e05..3c493c5df 100644
--- a/extensions/expression-language/tests/ExpressionLanguageTests.cpp
+++ b/extensions/expression-language/tests/ExpressionLanguageTests.cpp
@@ -36,9 +36,9 @@
#include <GetFile.h>
#include <PutFile.h>
#include <UpdateAttribute.h>
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include <LogAttribute.h>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
#include "catch2/catch_approx.hpp"
diff --git a/extensions/expression-language/tests/ProcessContextExprTests.cpp b/extensions/expression-language/tests/ProcessContextExprTests.cpp
index 07133b31d..9b9635653 100644
--- a/extensions/expression-language/tests/ProcessContextExprTests.cpp
+++ b/extensions/expression-language/tests/ProcessContextExprTests.cpp
@@ -18,13 +18,13 @@
#include <memory>
#include <string>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Resource.h"
#include "ProcessContextExpr.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
diff --git a/extensions/gcp/GCPAttributes.h b/extensions/gcp/GCPAttributes.h
index 73b11fd77..5657e7200 100644
--- a/extensions/gcp/GCPAttributes.h
+++ b/extensions/gcp/GCPAttributes.h
@@ -20,7 +20,7 @@
#include <string_view>
#include "google/cloud/storage/object_metadata.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
namespace org::apache::nifi::minifi::extensions::gcp {
diff --git a/extensions/gcp/controllerservices/GCPCredentialsControllerService.h b/extensions/gcp/controllerservices/GCPCredentialsControllerService.h
index 87c100d27..20d7c65b2 100644
--- a/extensions/gcp/controllerservices/GCPCredentialsControllerService.h
+++ b/extensions/gcp/controllerservices/GCPCredentialsControllerService.h
@@ -22,9 +22,9 @@
#include <memory>
#include "core/controller/ControllerService.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "utils/Enum.h"
diff --git a/extensions/gcp/processors/DeleteGCSObject.cpp b/extensions/gcp/processors/DeleteGCSObject.cpp
index bc4c01322..4ad4b4327 100644
--- a/extensions/gcp/processors/DeleteGCSObject.cpp
+++ b/extensions/gcp/processors/DeleteGCSObject.cpp
@@ -20,8 +20,8 @@
#include "utils/ProcessorConfigUtils.h"
#include "../GCPAttributes.h"
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
diff --git a/extensions/gcp/processors/DeleteGCSObject.h b/extensions/gcp/processors/DeleteGCSObject.h
index 0bffde16b..a5d022847 100644
--- a/extensions/gcp/processors/DeleteGCSObject.h
+++ b/extensions/gcp/processors/DeleteGCSObject.h
@@ -24,8 +24,8 @@
#include "../GCPAttributes.h"
#include "GCSProcessor.h"
#include "core/logging/LoggerFactory.h"
-#include "core/OutputAttributeDefinition.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "utils/ArrayUtils.h"
diff --git a/extensions/gcp/processors/FetchGCSObject.cpp b/extensions/gcp/processors/FetchGCSObject.cpp
index fe9f5cf76..a42799e28 100644
--- a/extensions/gcp/processors/FetchGCSObject.cpp
+++ b/extensions/gcp/processors/FetchGCSObject.cpp
@@ -20,8 +20,8 @@
#include <utility>
#include "core/Resource.h"
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "../GCPAttributes.h"
diff --git a/extensions/gcp/processors/FetchGCSObject.h b/extensions/gcp/processors/FetchGCSObject.h
index f645506b1..694ad1f5e 100644
--- a/extensions/gcp/processors/FetchGCSObject.h
+++ b/extensions/gcp/processors/FetchGCSObject.h
@@ -23,8 +23,8 @@
#include "../GCPAttributes.h"
#include "GCSProcessor.h"
-#include "core/PropertyDefinition.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "google/cloud/storage/well_known_headers.h"
#include "core/logging/LoggerFactory.h"
#include "utils/ArrayUtils.h"
diff --git a/extensions/gcp/processors/GCSProcessor.cpp b/extensions/gcp/processors/GCSProcessor.cpp
index 4c833a3ce..ded36f8a2 100644
--- a/extensions/gcp/processors/GCSProcessor.cpp
+++ b/extensions/gcp/processors/GCSProcessor.cpp
@@ -20,7 +20,7 @@
#include "utils/ProcessorConfigUtils.h"
#include "../controllerservices/GCPCredentialsControllerService.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
namespace gcs = ::google::cloud::storage;
diff --git a/extensions/gcp/processors/GCSProcessor.h b/extensions/gcp/processors/GCSProcessor.h
index 430c5f04a..e3361a786 100644
--- a/extensions/gcp/processors/GCSProcessor.h
+++ b/extensions/gcp/processors/GCSProcessor.h
@@ -22,9 +22,9 @@
#include <optional>
#include "../controllerservices/GCPCredentialsControllerService.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "google/cloud/storage/oauth2/credentials.h"
diff --git a/extensions/gcp/processors/ListGCSBucket.cpp b/extensions/gcp/processors/ListGCSBucket.cpp
index 77f285765..13426e441 100644
--- a/extensions/gcp/processors/ListGCSBucket.cpp
+++ b/extensions/gcp/processors/ListGCSBucket.cpp
@@ -20,8 +20,8 @@
#include "utils/ProcessorConfigUtils.h"
#include "../GCPAttributes.h"
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
diff --git a/extensions/gcp/processors/ListGCSBucket.h b/extensions/gcp/processors/ListGCSBucket.h
index e384808d1..36c4ac1e0 100644
--- a/extensions/gcp/processors/ListGCSBucket.h
+++ b/extensions/gcp/processors/ListGCSBucket.h
@@ -24,11 +24,11 @@
#include "../GCPAttributes.h"
#include "GCSProcessor.h"
#include "core/logging/LoggerFactory.h"
-#include "core/OutputAttributeDefinition.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/ArrayUtils.h"
namespace org::apache::nifi::minifi::extensions::gcp {
diff --git a/extensions/gcp/processors/PutGCSObject.cpp b/extensions/gcp/processors/PutGCSObject.cpp
index 08b5b5746..ceea47658 100644
--- a/extensions/gcp/processors/PutGCSObject.cpp
+++ b/extensions/gcp/processors/PutGCSObject.cpp
@@ -20,8 +20,8 @@
#include <utility>
#include "core/Resource.h"
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "../GCPAttributes.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/gcp/processors/PutGCSObject.h b/extensions/gcp/processors/PutGCSObject.h
index 3a0fe3792..58d7675fa 100644
--- a/extensions/gcp/processors/PutGCSObject.h
+++ b/extensions/gcp/processors/PutGCSObject.h
@@ -23,9 +23,9 @@
#include "../GCPAttributes.h"
#include "GCSProcessor.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/logging/LoggerFactory.h"
#include "utils/ArrayUtils.h"
#include "utils/Enum.h"
diff --git a/extensions/gcp/tests/GCPCredentialsControllerServiceTests.cpp b/extensions/gcp/tests/GCPCredentialsControllerServiceTests.cpp
index eb71f1d28..969865a74 100644
--- a/extensions/gcp/tests/GCPCredentialsControllerServiceTests.cpp
+++ b/extensions/gcp/tests/GCPCredentialsControllerServiceTests.cpp
@@ -21,7 +21,7 @@
#include "../controllerservices/GCPCredentialsControllerService.h"
#include "core/Resource.h"
#include "core/Processor.h"
-#include "core/controller/ControllerServiceNode.h"
+#include "minifi-cpp/core/controller/ControllerServiceNode.h"
#include "rapidjson/document.h"
#include "rapidjson/stream.h"
#include "rapidjson/writer.h"
@@ -74,9 +74,9 @@ class GCPCredentialsTests : public ::testing::Test {
ASSERT_TRUE(gcp_credentials_);
plan_->addProcessor("DummyProcessor", "dummy_processor");
}
- TestController test_controller_{};
+ TestController test_controller_;
std::shared_ptr<TestPlan> plan_ = test_controller_.createPlan();
- std::shared_ptr<minifi::core::controller::ControllerServiceNode> gcp_credentials_node_ = plan_->addController("GCPCredentialsControllerService", "gcp_credentials_controller_service");
+ std::shared_ptr<minifi::core::controller::ControllerServiceNode> gcp_credentials_node_ = plan_->addController("GCPCredentialsControllerService", "gcp_credentials_controller_service");
std::shared_ptr<GCPCredentialsControllerService> gcp_credentials_ = std::dynamic_pointer_cast<GCPCredentialsControllerService>(gcp_credentials_node_->getControllerServiceImplementation());
};
diff --git a/extensions/grafana-loki/PushGrafanaLoki.cpp b/extensions/grafana-loki/PushGrafanaLoki.cpp
index a70013237..ad49af420 100644
--- a/extensions/grafana-loki/PushGrafanaLoki.cpp
+++ b/extensions/grafana-loki/PushGrafanaLoki.cpp
@@ -18,7 +18,7 @@
#include <utility>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "utils/ProcessorConfigUtils.h"
#include "utils/StringUtils.h"
diff --git a/extensions/grafana-loki/PushGrafanaLoki.h b/extensions/grafana-loki/PushGrafanaLoki.h
index 06676194c..152c9f32b 100644
--- a/extensions/grafana-loki/PushGrafanaLoki.h
+++ b/extensions/grafana-loki/PushGrafanaLoki.h
@@ -21,13 +21,13 @@
#include <vector>
#include <map>
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "core/StateManager.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/core/StateManager.h"
#include "utils/ArrayUtils.h"
namespace org::apache::nifi::minifi::extensions::grafana::loki {
diff --git a/extensions/grafana-loki/PushGrafanaLokiGrpc.h b/extensions/grafana-loki/PushGrafanaLokiGrpc.h
index 808f5b77d..9d9726648 100644
--- a/extensions/grafana-loki/PushGrafanaLokiGrpc.h
+++ b/extensions/grafana-loki/PushGrafanaLokiGrpc.h
@@ -19,7 +19,6 @@
#include "PushGrafanaLoki.h"
#include "core/logging/LoggerFactory.h"
-#include "core/StateManager.h"
#include "grafana-loki-push.grpc.pb.h"
#include "grafana-loki-push.pb.h"
#include "grpc/grpc.h"
diff --git a/extensions/grafana-loki/tests/MockGrafanaLokiREST.h b/extensions/grafana-loki/tests/MockGrafanaLokiREST.h
index e09ad21c2..96810fba4 100644
--- a/extensions/grafana-loki/tests/MockGrafanaLokiREST.h
+++ b/extensions/grafana-loki/tests/MockGrafanaLokiREST.h
@@ -23,7 +23,7 @@
#include <vector>
#include <CivetServer.h>
#include "integration/CivetLibrary.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "rapidjson/document.h"
#include "rapidjson/writer.h"
diff --git a/extensions/kafka/ConsumeKafka.cpp b/extensions/kafka/ConsumeKafka.cpp
index c8ef2f262..adbff6630 100644
--- a/extensions/kafka/ConsumeKafka.cpp
+++ b/extensions/kafka/ConsumeKafka.cpp
@@ -20,14 +20,14 @@
#include <algorithm>
#include <ranges>
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/ProcessSession.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "core/Resource.h"
#include "utils/OptionalUtils.h"
#include "utils/AttributeErrors.h"
#include "utils/ProcessorConfigUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/expected.h"
using namespace std::literals::chrono_literals;
diff --git a/extensions/kafka/ConsumeKafka.h b/extensions/kafka/ConsumeKafka.h
index 3a41ad4e1..96dbe58e5 100644
--- a/extensions/kafka/ConsumeKafka.h
+++ b/extensions/kafka/ConsumeKafka.h
@@ -24,10 +24,10 @@
#include "KafkaConnection.h"
#include "KafkaProcessorBase.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/logging/LoggerFactory.h"
#include "io/StreamPipe.h"
#include "rdkafka.h"
diff --git a/extensions/kafka/KafkaConnection.cpp b/extensions/kafka/KafkaConnection.cpp
index a7ec13040..ac1387fa9 100644
--- a/extensions/kafka/KafkaConnection.cpp
+++ b/extensions/kafka/KafkaConnection.cpp
@@ -20,7 +20,7 @@
#include <memory>
#include <utility>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/kafka/KafkaConnection.h b/extensions/kafka/KafkaConnection.h
index 93f5bc08e..121ab2f3d 100644
--- a/extensions/kafka/KafkaConnection.h
+++ b/extensions/kafka/KafkaConnection.h
@@ -25,10 +25,10 @@
#include <unordered_map>
#include "core/logging/LoggerFactory.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "rdkafka.h"
#include "KafkaTopic.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/kafka/KafkaProcessorBase.cpp b/extensions/kafka/KafkaProcessorBase.cpp
index f864bd278..250bef64b 100644
--- a/extensions/kafka/KafkaProcessorBase.cpp
+++ b/extensions/kafka/KafkaProcessorBase.cpp
@@ -16,7 +16,7 @@
*/
#include "KafkaProcessorBase.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "rdkafka_utils.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/kafka/KafkaProcessorBase.h b/extensions/kafka/KafkaProcessorBase.h
index 457666d30..129882ac4 100644
--- a/extensions/kafka/KafkaProcessorBase.h
+++ b/extensions/kafka/KafkaProcessorBase.h
@@ -20,7 +20,7 @@
#include <optional>
#include <string_view>
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/ProcessorImpl.h"
#include "core/PropertyDefinitionBuilder.h"
#include "rdkafka_utils.h"
diff --git a/extensions/kafka/PublishKafka.cpp b/extensions/kafka/PublishKafka.cpp
index 1805dde4c..7c6c0912c 100644
--- a/extensions/kafka/PublishKafka.cpp
+++ b/extensions/kafka/PublishKafka.cpp
@@ -21,14 +21,14 @@
#include <string>
#include <vector>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "range/v3/algorithm/all_of.hpp"
#include "rdkafka_utils.h"
#include "utils/ProcessorConfigUtils.h"
#include "utils/StringUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::processors {
@@ -112,7 +112,7 @@ class PublishKafka::Messages {
}
template<typename Func>
- auto modifyResult(size_t index, Func fun) -> decltype(fun(flow_files_.at(index))) {
+ auto modifyResult(size_t index, const Func& fun) -> decltype(fun(flow_files_.at(index))) {
std::unique_lock<std::mutex> lock(mutex_);
const auto notifier = gsl::finally([this] { cv_.notify_all(); });
try {
@@ -219,7 +219,7 @@ class ReadCallback {
// in case of success, rd_kafka_producev takes ownership of the headers, so we no longer need to delete it
std::ignore = callback_ptr.release();
}
- logger_->log_trace("produce enqueued flow file #{}/segment #{}: {}",
+ logger_->log_trace("produce enqueued flow file #{}/segment #{}: {}", // NOLINT(clang-analyzer-cplusplus.NewDeleteLeaks)
flow_file_index_,
segment_num,
rd_kafka_err2str(err));
@@ -353,7 +353,7 @@ void PublishKafka::onSchedule(core::ProcessContext& context, core::ProcessSessio
// Attributes to Send as Headers
attributeNameRegex_ = context.getProperty(AttributeNameRegex)
- | utils::transform([](const auto pattern_str) { return utils::Regex{std::move(pattern_str)}; })
+ | utils::transform([](auto pattern_str) { return utils::Regex{std::move(pattern_str)}; })
| utils::toOptional();
key_.brokers_ = brokers;
diff --git a/extensions/kafka/PublishKafka.h b/extensions/kafka/PublishKafka.h
index 26ed6c3b3..61cd6ccd3 100644
--- a/extensions/kafka/PublishKafka.h
+++ b/extensions/kafka/PublishKafka.h
@@ -29,14 +29,14 @@
#include "KafkaConnection.h"
#include "KafkaProcessorBase.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/Core.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "rdkafka.h"
diff --git a/extensions/kafka/rdkafka_utils.cpp b/extensions/kafka/rdkafka_utils.cpp
index 6482d5c52..d3c38dab1 100644
--- a/extensions/kafka/rdkafka_utils.cpp
+++ b/extensions/kafka/rdkafka_utils.cpp
@@ -19,7 +19,7 @@
#include <array>
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "utils/StringUtils.h"
namespace org::apache::nifi::minifi::utils {
diff --git a/extensions/kubernetes/ApiClient.h b/extensions/kubernetes/ApiClient.h
index 5f2d7d702..5c4c53651 100644
--- a/extensions/kubernetes/ApiClient.h
+++ b/extensions/kubernetes/ApiClient.h
@@ -18,7 +18,7 @@
#include <string>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
struct apiClient_t;
struct list_t;
diff --git a/extensions/kubernetes/controllerservice/KubernetesControllerService.cpp b/extensions/kubernetes/controllerservice/KubernetesControllerService.cpp
index be9f1618f..e1118a17a 100644
--- a/extensions/kubernetes/controllerservice/KubernetesControllerService.cpp
+++ b/extensions/kubernetes/controllerservice/KubernetesControllerService.cpp
@@ -25,8 +25,8 @@ extern "C" {
#include "core/Resource.h"
#include "core/logging/LoggerFactory.h"
-#include "Exception.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/StringUtils.h"
namespace org::apache::nifi::minifi::controllers {
diff --git a/extensions/kubernetes/controllerservice/KubernetesControllerService.h b/extensions/kubernetes/controllerservice/KubernetesControllerService.h
index b75ba9848..c331c6127 100644
--- a/extensions/kubernetes/controllerservice/KubernetesControllerService.h
+++ b/extensions/kubernetes/controllerservice/KubernetesControllerService.h
@@ -24,8 +24,8 @@
#include "../ApiClient.h"
#include "../ContainerInfo.h"
#include "controllers/AttributeProviderService.h"
-#include "core/logging/Logger.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "utils/RegexUtils.h"
diff --git a/extensions/kubernetes/processors/CollectKubernetesPodMetrics.cpp b/extensions/kubernetes/processors/CollectKubernetesPodMetrics.cpp
index 5693a06ae..7768ec956 100644
--- a/extensions/kubernetes/processors/CollectKubernetesPodMetrics.cpp
+++ b/extensions/kubernetes/processors/CollectKubernetesPodMetrics.cpp
@@ -16,7 +16,7 @@
*/
#include "CollectKubernetesPodMetrics.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "../ContainerInfo.h"
diff --git a/extensions/kubernetes/processors/CollectKubernetesPodMetrics.h b/extensions/kubernetes/processors/CollectKubernetesPodMetrics.h
index fae416df8..0867b9f66 100644
--- a/extensions/kubernetes/processors/CollectKubernetesPodMetrics.h
+++ b/extensions/kubernetes/processors/CollectKubernetesPodMetrics.h
@@ -22,7 +22,7 @@
#include "../controllerservice/KubernetesControllerService.h"
#include "core/logging/LoggerFactory.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/libarchive/ArchiveMetadata.cpp b/extensions/libarchive/ArchiveMetadata.cpp
index 134b497c9..1daca809a 100644
--- a/extensions/libarchive/ArchiveMetadata.cpp
+++ b/extensions/libarchive/ArchiveMetadata.cpp
@@ -27,8 +27,8 @@
#include <iostream>
#include "utils/file/FileManager.h"
-#include "utils/gsl.h"
-#include "Exception.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/Exception.h"
#include "rapidjson/writer.h"
#include "rapidjson/error/en.h"
diff --git a/extensions/libarchive/BinFiles.cpp b/extensions/libarchive/BinFiles.cpp
index a82ab464c..5d3322291 100644
--- a/extensions/libarchive/BinFiles.cpp
+++ b/extensions/libarchive/BinFiles.cpp
@@ -26,7 +26,7 @@
#include <utility>
#include <vector>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/StringUtils.h"
diff --git a/extensions/libarchive/BinFiles.h b/extensions/libarchive/BinFiles.h
index 0c5517ee0..02662ba5c 100644
--- a/extensions/libarchive/BinFiles.h
+++ b/extensions/libarchive/BinFiles.h
@@ -26,16 +26,16 @@
#include <map>
#include <utility>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/Id.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "core/FlowFileStore.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/libarchive/CompressContent.cpp b/extensions/libarchive/CompressContent.cpp
index 9d66edd80..aad392ab1 100644
--- a/extensions/libarchive/CompressContent.cpp
+++ b/extensions/libarchive/CompressContent.cpp
@@ -22,7 +22,7 @@
#include <memory>
#include <string>
#include <map>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "utils/StringUtils.h"
#include "core/Resource.h"
diff --git a/extensions/libarchive/CompressContent.h b/extensions/libarchive/CompressContent.h
index 171a9c1e4..08667be80 100644
--- a/extensions/libarchive/CompressContent.h
+++ b/extensions/libarchive/CompressContent.h
@@ -30,17 +30,17 @@
#include "archive_entry.h"
#include "archive.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
#include "core/Core.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "core/logging/LoggerFactory.h"
#include "io/ZlibStream.h"
#include "utils/Enum.h"
-#include "utils/gsl.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/utils/Export.h"
#include "WriteArchiveStream.h"
#include "ReadArchiveStream.h"
diff --git a/extensions/libarchive/FocusArchiveEntry.cpp b/extensions/libarchive/FocusArchiveEntry.cpp
index 58cb90c23..acc301194 100644
--- a/extensions/libarchive/FocusArchiveEntry.cpp
+++ b/extensions/libarchive/FocusArchiveEntry.cpp
@@ -29,13 +29,13 @@
#include <memory>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "SmartArchivePtrs.h"
#include "utils/ConfigurationUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace {
inline constexpr auto BUFFER_SIZE = org::apache::nifi::minifi::utils::configuration::DEFAULT_BUFFER_SIZE;
@@ -68,7 +68,6 @@ void FocusArchiveEntry::onTrigger(core::ProcessContext& context, core::ProcessSe
// For each extracted entry, import & stash to key
std::string targetEntryStashKey;
- std::string targetEntry;
for (auto &entryMetadata : archiveMetadata.entryMetadata) {
if (entryMetadata.entryType == AE_IFREG) {
diff --git a/extensions/libarchive/FocusArchiveEntry.h b/extensions/libarchive/FocusArchiveEntry.h
index 23ea6f61f..bcf816cb3 100644
--- a/extensions/libarchive/FocusArchiveEntry.h
+++ b/extensions/libarchive/FocusArchiveEntry.h
@@ -23,16 +23,16 @@
#include "archive.h"
#include "ArchiveMetadata.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
#include "utils/file/FileManager.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/libarchive/ManipulateArchive.cpp b/extensions/libarchive/ManipulateArchive.cpp
index e358e7b65..0346b0b60 100644
--- a/extensions/libarchive/ManipulateArchive.cpp
+++ b/extensions/libarchive/ManipulateArchive.cpp
@@ -27,10 +27,10 @@
#include "archive_entry.h"
#include "ManipulateArchive.h"
-#include "Exception.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/Resource.h"
#include "utils/file/FileManager.h"
#include "FocusArchiveEntry.h"
diff --git a/extensions/libarchive/ManipulateArchive.h b/extensions/libarchive/ManipulateArchive.h
index 1a6d897f8..c6dec684a 100644
--- a/extensions/libarchive/ManipulateArchive.h
+++ b/extensions/libarchive/ManipulateArchive.h
@@ -23,14 +23,14 @@
#include <string>
#include <utility>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "ArchiveMetadata.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
-#include "utils/Export.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/libarchive/MergeContent.cpp b/extensions/libarchive/MergeContent.cpp
index 8abd593e3..90bff039f 100644
--- a/extensions/libarchive/MergeContent.cpp
+++ b/extensions/libarchive/MergeContent.cpp
@@ -25,7 +25,7 @@
#include <string>
#include <utility>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "serialization/FlowFileV3Serializer.h"
diff --git a/extensions/libarchive/MergeContent.h b/extensions/libarchive/MergeContent.h
index 2853f0c5d..6b7330d01 100644
--- a/extensions/libarchive/MergeContent.h
+++ b/extensions/libarchive/MergeContent.h
@@ -33,8 +33,8 @@
#include "minifi-cpp/core/PropertyValidator.h"
#include "serialization/FlowFileSerializer.h"
#include "utils/ArrayUtils.h"
-#include "utils/gsl.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/utils/Export.h"
#include "io/Stream.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/libarchive/ReadArchiveStream.h b/extensions/libarchive/ReadArchiveStream.h
index e481fc69e..e23473ed7 100644
--- a/extensions/libarchive/ReadArchiveStream.h
+++ b/extensions/libarchive/ReadArchiveStream.h
@@ -21,8 +21,7 @@
#include <memory>
#include <utility>
-#include "io/OutputStream.h"
-#include "io/ArchiveStream.h"
+#include "minifi-cpp/io/ArchiveStream.h"
#include "io/InputStream.h"
#include "core/logging/LoggerFactory.h"
#include "archive_entry.h"
diff --git a/extensions/libarchive/UnfocusArchiveEntry.cpp b/extensions/libarchive/UnfocusArchiveEntry.cpp
index 912e89b05..8b49fe2fe 100644
--- a/extensions/libarchive/UnfocusArchiveEntry.cpp
+++ b/extensions/libarchive/UnfocusArchiveEntry.cpp
@@ -27,11 +27,11 @@
#include "SmartArchivePtrs.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ConfigurationUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace {
inline constexpr auto BUFFER_SIZE = org::apache::nifi::minifi::utils::configuration::DEFAULT_BUFFER_SIZE;
diff --git a/extensions/libarchive/UnfocusArchiveEntry.h b/extensions/libarchive/UnfocusArchiveEntry.h
index 0261eb57f..5cafd93a5 100644
--- a/extensions/libarchive/UnfocusArchiveEntry.h
+++ b/extensions/libarchive/UnfocusArchiveEntry.h
@@ -26,11 +26,11 @@
#include "archive.h"
#include "FocusArchiveEntry.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "ArchiveMetadata.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extensions/libarchive/WriteArchiveStream.h b/extensions/libarchive/WriteArchiveStream.h
index 4369543ad..1f77e160e 100644
--- a/extensions/libarchive/WriteArchiveStream.h
+++ b/extensions/libarchive/WriteArchiveStream.h
@@ -22,7 +22,7 @@
#include <utility>
#include <string>
-#include "io/ArchiveStream.h"
+#include "minifi-cpp/io/ArchiveStream.h"
#include "archive_entry.h"
#include "archive.h"
#include "SmartArchivePtrs.h"
diff --git a/extensions/libarchive/tests/CompressContentTests.cpp b/extensions/libarchive/tests/CompressContentTests.cpp
index c731c60fa..693b4915a 100644
--- a/extensions/libarchive/tests/CompressContentTests.cpp
+++ b/extensions/libarchive/tests/CompressContentTests.cpp
@@ -28,11 +28,13 @@
#include "CompressContent.h"
#include "FlowController.h"
+#include "Connection.h"
#include "catch2/generators/catch_generators.hpp"
#include "core/Core.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/ProcessContext.h"
#include "core/ProcessSession.h"
+#include "core/ProcessSessionFactory.h"
#include "core/Processor.h"
#include "io/FileStream.h"
#include "processors/GetFile.h"
@@ -43,7 +45,7 @@
#include "unit/TestBase.h"
#include "unit/TestUtils.h"
#include "utils/file/FileUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
class ReadCallback {
public:
diff --git a/extensions/libarchive/tests/ManipulateArchiveTests.cpp b/extensions/libarchive/tests/ManipulateArchiveTests.cpp
index 55aeebdba..3d2ca97a7 100644
--- a/extensions/libarchive/tests/ManipulateArchiveTests.cpp
+++ b/extensions/libarchive/tests/ManipulateArchiveTests.cpp
@@ -25,7 +25,7 @@
#include "unit/TestUtils.h"
#include "unit/Catch.h"
#include "util/ArchiveTests.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "processors/GetFile.h"
#include "processors/LogAttribute.h"
#include "processors/PutFile.h"
diff --git a/extensions/libarchive/tests/MergeFileTests.cpp b/extensions/libarchive/tests/MergeFileTests.cpp
index 158d466c7..3da5b84df 100644
--- a/extensions/libarchive/tests/MergeFileTests.cpp
+++ b/extensions/libarchive/tests/MergeFileTests.cpp
@@ -30,7 +30,9 @@
#include "core/Processor.h"
#include "core/ProcessContext.h"
#include "core/ProcessSession.h"
+#include "core/ProcessSessionFactory.h"
#include "FlowController.h"
+#include "Connection.h"
#include "../../include/core/FlowFile.h"
#include "MergeContent.h"
#include "processors/LogAttribute.h"
@@ -41,7 +43,7 @@
#include "serialization/FlowFileV3Serializer.h"
#include "serialization/PayloadSerializer.h"
#include "unit/TestUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/span.h"
std::string FLOW_FILE;
@@ -637,9 +639,9 @@ TEST_CASE_METHOD(MergeTestController, "Test Merge File Attributes Keeping Only C
std::shared_ptr<core::FlowFile> flow = output_->poll(expiredFlowRecords);
auto attributes = flow->getAttributes();
- REQUIRE(attributes.find("tagUncommon") == attributes.end());
- REQUIRE(attributes.find("tagUnique1") == attributes.end());
- REQUIRE(attributes.find("tagUnique2") == attributes.end());
+ CHECK_FALSE(attributes.contains("tagUncommon"));
+ CHECK_FALSE(attributes.contains("tagUnique1"));
+ CHECK_FALSE(attributes.contains("tagUnique2"));
REQUIRE(attributes["tagCommon"] == "common");
REQUIRE(attributes["mime.type"] == "application/tar");
}
@@ -686,7 +688,7 @@ TEST_CASE_METHOD(MergeTestController, "Test Merge File Attributes Keeping All Un
std::shared_ptr<core::FlowFile> flow = output_->poll(expiredFlowRecords);
auto attributes = flow->getAttributes();
- REQUIRE(attributes.find("tagUncommon") == attributes.end());
+ CHECK_FALSE(attributes.contains("tagUncommon"));
REQUIRE(attributes["tagUnique1"] == "unique1");
REQUIRE(attributes["tagUnique2"] == "unique2");
REQUIRE(attributes["tagCommon"] == "common");
diff --git a/extensions/libarchive/tests/util/ArchiveTests.cpp b/extensions/libarchive/tests/util/ArchiveTests.cpp
index fb18e9ecf..93cc99e6a 100644
--- a/extensions/libarchive/tests/util/ArchiveTests.cpp
+++ b/extensions/libarchive/tests/util/ArchiveTests.cpp
@@ -28,7 +28,7 @@
#include "unit/TestBase.h"
#include "unit/Catch.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "SmartArchivePtrs.h"
@@ -83,7 +83,7 @@ void build_test_archive(const std::filesystem::path& path, const TAE_MAP_T& entr
}
for (const std::string& name : order) {
- TestArchiveEntry test_entry = entries.at(name);
+ const TestArchiveEntry& test_entry = entries.at(name);
std::cout << "Adding entry: " << name << std::endl;
diff --git a/extensions/llamacpp/processors/DefaultLlamaContext.cpp b/extensions/llamacpp/processors/DefaultLlamaContext.cpp
index 119f5a63b..b453110b8 100644
--- a/extensions/llamacpp/processors/DefaultLlamaContext.cpp
+++ b/extensions/llamacpp/processors/DefaultLlamaContext.cpp
@@ -16,7 +16,7 @@
*/
#include "DefaultLlamaContext.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "fmt/format.h"
#include "utils/ConfigurationUtils.h"
diff --git a/extensions/llamacpp/processors/RunLlamaCppInference.cpp b/extensions/llamacpp/processors/RunLlamaCppInference.cpp
index 89de32eb3..4b907e352 100644
--- a/extensions/llamacpp/processors/RunLlamaCppInference.cpp
+++ b/extensions/llamacpp/processors/RunLlamaCppInference.cpp
@@ -16,10 +16,10 @@
*/
#include "RunLlamaCppInference.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "rapidjson/document.h"
#include "rapidjson/error/en.h"
diff --git a/extensions/llamacpp/tests/RunLlamaCppInferenceTests.cpp b/extensions/llamacpp/tests/RunLlamaCppInferenceTests.cpp
index 29deb5b6b..4cfe0a25e 100644
--- a/extensions/llamacpp/tests/RunLlamaCppInferenceTests.cpp
+++ b/extensions/llamacpp/tests/RunLlamaCppInferenceTests.cpp
@@ -19,7 +19,7 @@
#include "unit/Catch.h"
#include "RunLlamaCppInference.h"
#include "unit/SingleProcessorTestController.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "unit/ProcessorUtils.h"
namespace org::apache::nifi::minifi::extensions::llamacpp::test {
diff --git a/extensions/lua/LuaInputStream.h b/extensions/lua/LuaInputStream.h
index a245ddb74..4b74944a5 100644
--- a/extensions/lua/LuaInputStream.h
+++ b/extensions/lua/LuaInputStream.h
@@ -21,7 +21,7 @@
#include <string>
#include "sol/sol.hpp"
-#include "io/InputStream.h"
+#include "minifi-cpp/io/InputStream.h"
namespace org::apache::nifi::minifi::extensions::lua {
diff --git a/extensions/lua/LuaLogger.h b/extensions/lua/LuaLogger.h
index 2412e74a0..9497f57eb 100644
--- a/extensions/lua/LuaLogger.h
+++ b/extensions/lua/LuaLogger.h
@@ -22,7 +22,6 @@
#include <memory>
#include "sol/sol.hpp"
-#include "core/StateManager.h"
namespace org::apache::nifi::minifi::extensions::lua {
diff --git a/extensions/lua/LuaOutputStream.h b/extensions/lua/LuaOutputStream.h
index 7b7b62583..28c83dda9 100644
--- a/extensions/lua/LuaOutputStream.h
+++ b/extensions/lua/LuaOutputStream.h
@@ -21,7 +21,7 @@
#include <string>
#include "sol/sol.hpp"
-#include "io/OutputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
namespace org::apache::nifi::minifi::extensions::lua {
diff --git a/extensions/lua/LuaScriptFlowFile.cpp b/extensions/lua/LuaScriptFlowFile.cpp
index 561fcc127..6476adde3 100644
--- a/extensions/lua/LuaScriptFlowFile.cpp
+++ b/extensions/lua/LuaScriptFlowFile.cpp
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "LuaScriptFlowFile.h"
@@ -56,20 +56,20 @@ bool LuaScriptFlowFile::setAttribute(const std::string& key, const std::string&
return flow_file_->setAttribute(key, value);
}
-bool LuaScriptFlowFile::updateAttribute(std::string key, std::string value) {
+bool LuaScriptFlowFile::updateAttribute(std::string_view key, const std::string& value) {
if (!flow_file_) {
throw std::runtime_error("Access of FlowFile after it has been released");
}
- return flow_file_->updateAttribute(std::move(key), std::move(value));
+ return flow_file_->updateAttribute(key, value);
}
-bool LuaScriptFlowFile::removeAttribute(std::string key) {
+bool LuaScriptFlowFile::removeAttribute(std::string_view key) {
if (!flow_file_) {
throw std::runtime_error("Access of FlowFile after it has been released");
}
- return flow_file_->removeAttribute(std::move(key));
+ return flow_file_->removeAttribute(key);
}
std::shared_ptr<core::FlowFile> LuaScriptFlowFile::getFlowFile() {
diff --git a/extensions/lua/LuaScriptFlowFile.h b/extensions/lua/LuaScriptFlowFile.h
index 91edd8b98..477f23a0f 100644
--- a/extensions/lua/LuaScriptFlowFile.h
+++ b/extensions/lua/LuaScriptFlowFile.h
@@ -21,7 +21,7 @@
#include <string>
#include <memory>
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
namespace org::apache::nifi::minifi::extensions::lua {
@@ -32,8 +32,8 @@ class LuaScriptFlowFile {
std::string getAttribute(const std::string &key);
bool setAttribute(const std::string &key, const std::string &value);
bool addAttribute(const std::string &key, const std::string &value);
- bool updateAttribute(std::string key, std::string value);
- bool removeAttribute(std::string key);
+ bool updateAttribute(std::string_view key, const std::string& value);
+ bool removeAttribute(std::string_view key);
std::shared_ptr<core::FlowFile> getFlowFile();
void releaseFlowFile();
diff --git a/extensions/lua/LuaScriptStateManager.h b/extensions/lua/LuaScriptStateManager.h
index a9e8ce47f..9ffaba14e 100644
--- a/extensions/lua/LuaScriptStateManager.h
+++ b/extensions/lua/LuaScriptStateManager.h
@@ -22,7 +22,7 @@
#include <memory>
#include "sol/sol.hpp"
-#include "core/StateManager.h"
+#include "minifi-cpp/core/StateManager.h"
namespace org::apache::nifi::minifi::extensions::lua {
diff --git a/extensions/mqtt/processors/AbstractMQTTProcessor.cpp b/extensions/mqtt/processors/AbstractMQTTProcessor.cpp
index c1616bf5d..3fc5e9f66 100644
--- a/extensions/mqtt/processors/AbstractMQTTProcessor.cpp
+++ b/extensions/mqtt/processors/AbstractMQTTProcessor.cpp
@@ -21,7 +21,7 @@
#include "utils/StringUtils.h"
#include "utils/ProcessorConfigUtils.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/mqtt/processors/AbstractMQTTProcessor.h b/extensions/mqtt/processors/AbstractMQTTProcessor.h
index 222777001..303c0f492 100644
--- a/extensions/mqtt/processors/AbstractMQTTProcessor.h
+++ b/extensions/mqtt/processors/AbstractMQTTProcessor.h
@@ -22,8 +22,9 @@
#include <utility>
#include <vector>
#include <shared_mutex>
+#include <future>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
#include "core/PropertyDefinitionBuilder.h"
diff --git a/extensions/mqtt/processors/ConsumeMQTT.cpp b/extensions/mqtt/processors/ConsumeMQTT.cpp
index a2f8be2a6..dd66c8913 100644
--- a/extensions/mqtt/processors/ConsumeMQTT.cpp
+++ b/extensions/mqtt/processors/ConsumeMQTT.cpp
@@ -23,7 +23,7 @@
#include <string>
#include <vector>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/StringUtils.h"
diff --git a/extensions/mqtt/processors/ConsumeMQTT.h b/extensions/mqtt/processors/ConsumeMQTT.h
index 5331763f7..384fdeed3 100644
--- a/extensions/mqtt/processors/ConsumeMQTT.h
+++ b/extensions/mqtt/processors/ConsumeMQTT.h
@@ -23,17 +23,17 @@
#include <unordered_map>
#include <utility>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/Core.h"
-#include "core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/logging/LoggerFactory.h"
#include "concurrentqueue.h"
#include "AbstractMQTTProcessor.h"
#include "utils/ArrayUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/mqtt/processors/PublishMQTT.cpp b/extensions/mqtt/processors/PublishMQTT.cpp
index 55f885b4f..23a8af251 100644
--- a/extensions/mqtt/processors/PublishMQTT.cpp
+++ b/extensions/mqtt/processors/PublishMQTT.cpp
@@ -24,7 +24,7 @@
#include "utils/StringUtils.h"
#include "utils/ProcessorConfigUtils.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "core/state/Value.h"
diff --git a/extensions/mqtt/processors/PublishMQTT.h b/extensions/mqtt/processors/PublishMQTT.h
index a84fea851..c59c4bd3f 100644
--- a/extensions/mqtt/processors/PublishMQTT.h
+++ b/extensions/mqtt/processors/PublishMQTT.h
@@ -23,16 +23,16 @@
#include <utility>
#include <vector>
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
#include "core/PropertyDefinitionBuilder.h"
#include "core/Core.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/logging/LoggerFactory.h"
#include "AbstractMQTTProcessor.h"
#include "utils/ArrayUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/ProcessorMetrics.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/opc/include/fetchopc.h b/extensions/opc/include/fetchopc.h
index db23f7aa2..c483a25f0 100644
--- a/extensions/opc/include/fetchopc.h
+++ b/extensions/opc/include/fetchopc.h
@@ -24,17 +24,17 @@
#include "opc.h"
#include "opcbase.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessSession.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/logging/LoggerFactory.h"
#include "utils/ArrayUtils.h"
#include "utils/Id.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "minifi-cpp/core/StateManager.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/opc/include/opc.h b/extensions/opc/include/opc.h
index 3f8ad07ee..dee0c3347 100644
--- a/extensions/opc/include/opc.h
+++ b/extensions/opc/include/opc.h
@@ -29,8 +29,8 @@
#include <optional>
#include "open62541/client.h"
-#include "core/logging/Logger.h"
-#include "Exception.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::opc {
@@ -123,7 +123,7 @@ struct NodeData {
UA_Variant* var_;
explicit NodeData(UA_Variant * var = nullptr) {
- var_ = var;
+ var_ = var; // NOLINT(clang-analyzer-optin.cplusplus.UninitializedObject)
}
void addVariant(UA_Variant * var) {
if (var_) {
diff --git a/extensions/opc/include/opcbase.h b/extensions/opc/include/opcbase.h
index 982399125..b3c02e18d 100644
--- a/extensions/opc/include/opcbase.h
+++ b/extensions/opc/include/opcbase.h
@@ -25,10 +25,10 @@
#include "opc.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "core/Core.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/opc/include/putopc.h b/extensions/opc/include/putopc.h
index 5f4c11506..d98ac23b9 100644
--- a/extensions/opc/include/putopc.h
+++ b/extensions/opc/include/putopc.h
@@ -24,12 +24,12 @@
#include "opc.h"
#include "opcbase.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessSession.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/logging/LoggerFactory.h"
#include "utils/ArrayUtils.h"
#include "utils/Id.h"
diff --git a/extensions/opc/src/fetchopc.cpp b/extensions/opc/src/fetchopc.cpp
index 7a992aa60..43ba7a6f8 100644
--- a/extensions/opc/src/fetchopc.cpp
+++ b/extensions/opc/src/fetchopc.cpp
@@ -21,7 +21,7 @@
#include <memory>
#include <string>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "opc.h"
diff --git a/extensions/opc/src/opc.cpp b/extensions/opc/src/opc.cpp
index a4574763d..f8e44f6d2 100644
--- a/extensions/opc/src/opc.cpp
+++ b/extensions/opc/src/opc.cpp
@@ -25,10 +25,10 @@
#include <array>
#include "utils/StringUtils.h"
-#include "core/logging/Logger.h"
-#include "Exception.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/Exception.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "open62541/client_highlevel.h"
#include "open62541/client_config_default.h"
@@ -160,7 +160,7 @@ Client::Client(const std::shared_ptr<core::logging::Logger>& logger, const std::
UA_ClientConfig *config_ptr = UA_Client_getConfig(client_);
config_ptr->logging = &minifi_ua_logger_;
- if (application_uri.length() > 0) {
+ if (!application_uri.empty()) {
UA_String_clear(&config_ptr->clientDescription.applicationUri);
config_ptr->clientDescription.applicationUri = UA_STRING_ALLOC(application_uri.c_str());
}
@@ -246,7 +246,6 @@ NodeData Client::getNodeData(const UA_ReferenceDescription *ref, const std::stri
request.timestampsToReturn = UA_TIMESTAMPSTORETURN_BOTH;
UA_ReadResponse response = UA_Client_Service_read(client_, request);
UA_DataValue *dv = response.results;
- auto server_timestamp = OPCDateTime2String(dv->serverTimestamp);
auto source_timestamp = OPCDateTime2String(dv->sourceTimestamp);
nodedata.attributes["Sourcetimestamp"] = source_timestamp;
UA_ReadResponse_clear(&response);
diff --git a/extensions/opc/src/opcbase.cpp b/extensions/opc/src/opcbase.cpp
index 7d7c7101c..e7ff5a73e 100644
--- a/extensions/opc/src/opcbase.cpp
+++ b/extensions/opc/src/opcbase.cpp
@@ -20,7 +20,7 @@
#include "opc.h"
#include "opcbase.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessSession.h"
#include "core/Core.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/opc/src/putopc.cpp b/extensions/opc/src/putopc.cpp
index 72a309162..1d6247571 100644
--- a/extensions/opc/src/putopc.cpp
+++ b/extensions/opc/src/putopc.cpp
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "opc.h"
diff --git a/extensions/opencv/CaptureRTSPFrame.cpp b/extensions/opencv/CaptureRTSPFrame.cpp
index e0d5eba17..cb165baf7 100644
--- a/extensions/opencv/CaptureRTSPFrame.cpp
+++ b/extensions/opencv/CaptureRTSPFrame.cpp
@@ -17,7 +17,7 @@
#include "CaptureRTSPFrame.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
diff --git a/extensions/opencv/CaptureRTSPFrame.h b/extensions/opencv/CaptureRTSPFrame.h
index aa8d7434b..244e22ad7 100644
--- a/extensions/opencv/CaptureRTSPFrame.h
+++ b/extensions/opencv/CaptureRTSPFrame.h
@@ -29,8 +29,8 @@
#include "core/ProcessorImpl.h"
#include "core/PropertyDefinitionBuilder.h"
#include "io/StreamPipe.h"
-#include "utils/gsl.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/opencv/MotionDetector.cpp b/extensions/opencv/MotionDetector.cpp
index 67dc3b979..b6728f455 100644
--- a/extensions/opencv/MotionDetector.cpp
+++ b/extensions/opencv/MotionDetector.cpp
@@ -21,7 +21,7 @@
#include <utility>
#include <vector>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/opencv/MotionDetector.h b/extensions/opencv/MotionDetector.h
index eeb053126..469bf5eac 100644
--- a/extensions/opencv/MotionDetector.h
+++ b/extensions/opencv/MotionDetector.h
@@ -24,10 +24,10 @@
#include "core/logging/LoggerFactory.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "opencv2/opencv.hpp"
#include "opencv2/imgproc.hpp"
diff --git a/extensions/pdh/PerformanceDataMonitor.cpp b/extensions/pdh/PerformanceDataMonitor.cpp
index 952c27706..6f8055a41 100644
--- a/extensions/pdh/PerformanceDataMonitor.cpp
+++ b/extensions/pdh/PerformanceDataMonitor.cpp
@@ -24,7 +24,7 @@
#include "utils/JsonCallback.h"
#include "utils/OpenTelemetryLogDataModelUtils.h"
#include "utils/ProcessorConfigUtils.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
diff --git a/extensions/pdh/PerformanceDataMonitor.h b/extensions/pdh/PerformanceDataMonitor.h
index 196ca3db9..274d4a977 100644
--- a/extensions/pdh/PerformanceDataMonitor.h
+++ b/extensions/pdh/PerformanceDataMonitor.h
@@ -26,9 +26,9 @@
#include "core/logging/LoggerFactory.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "rapidjson/stream.h"
#include "rapidjson/writer.h"
diff --git a/extensions/pdh/tests/PerformanceDataCounterTests.cpp b/extensions/pdh/tests/PerformanceDataCounterTests.cpp
index 969763e0d..9f3bcd8a6 100644
--- a/extensions/pdh/tests/PerformanceDataCounterTests.cpp
+++ b/extensions/pdh/tests/PerformanceDataCounterTests.cpp
@@ -20,7 +20,7 @@
#include "unit/Catch.h"
#include "PDHCounters.h"
#include "MemoryConsumptionCounter.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
using org::apache::nifi::minifi::processors::SinglePDHCounter;
using org::apache::nifi::minifi::processors::PDHCounterArray;
diff --git a/extensions/procfs/DiskStat.cpp b/extensions/procfs/DiskStat.cpp
index c0ac47200..adaafcb2d 100644
--- a/extensions/procfs/DiskStat.cpp
+++ b/extensions/procfs/DiskStat.cpp
@@ -17,7 +17,7 @@
#include "DiskStat.h"
#include <utility>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
using namespace std::literals::chrono_literals;
diff --git a/extensions/procfs/NetDev.cpp b/extensions/procfs/NetDev.cpp
index 3f8d394ae..b16958e30 100644
--- a/extensions/procfs/NetDev.cpp
+++ b/extensions/procfs/NetDev.cpp
@@ -16,7 +16,7 @@
*/
#include "NetDev.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
using namespace std::literals::chrono_literals;
diff --git a/extensions/procfs/ProcFs.h b/extensions/procfs/ProcFs.h
index c989ad77b..dfce7e60e 100644
--- a/extensions/procfs/ProcFs.h
+++ b/extensions/procfs/ProcFs.h
@@ -34,7 +34,7 @@
#include "DiskStat.h"
#include "core/logging/LoggerFactory.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::extensions::procfs {
diff --git a/extensions/procfs/ProcFsSerialization.h b/extensions/procfs/ProcFsSerialization.h
index 4becf9dcc..2bf786031 100644
--- a/extensions/procfs/ProcFsSerialization.h
+++ b/extensions/procfs/ProcFsSerialization.h
@@ -26,7 +26,7 @@
#include "MemInfo.h"
#include "NetDev.h"
#include "ProcessStat.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::extensions::procfs {
diff --git a/extensions/procfs/processors/ProcFsMonitor.cpp b/extensions/procfs/processors/ProcFsMonitor.cpp
index 5c4592e70..caac9582f 100644
--- a/extensions/procfs/processors/ProcFsMonitor.cpp
+++ b/extensions/procfs/processors/ProcFsMonitor.cpp
@@ -23,12 +23,12 @@
#include <unordered_map>
#include "core/Resource.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "../ProcFsJsonSerialization.h"
#include "utils/JsonCallback.h"
#include "utils/OpenTelemetryLogDataModelUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ProcessorConfigUtils.h"
using namespace std::literals::chrono_literals;
diff --git a/extensions/procfs/processors/ProcFsMonitor.h b/extensions/procfs/processors/ProcFsMonitor.h
index d20649771..f0d6548e6 100644
--- a/extensions/procfs/processors/ProcFsMonitor.h
+++ b/extensions/procfs/processors/ProcFsMonitor.h
@@ -26,11 +26,11 @@
#include "../ProcFs.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/logging/LoggerFactory.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "utils/Enum.h"
#include "rapidjson/stream.h"
diff --git a/extensions/procfs/tests/MemInfoTests.cpp b/extensions/procfs/tests/MemInfoTests.cpp
index 9a8c7164b..0c4d895fd 100644
--- a/extensions/procfs/tests/MemInfoTests.cpp
+++ b/extensions/procfs/tests/MemInfoTests.cpp
@@ -17,7 +17,7 @@
#include "unit/Catch.h"
#include "ProcFs.h"
-#include "utils/Literals.h"
+#include "minifi-cpp/utils/Literals.h"
#include "MockProcFs.h"
namespace org::apache::nifi::minifi::extensions::procfs::tests {
diff --git a/extensions/prometheus/PrometheusExposerWrapper.h b/extensions/prometheus/PrometheusExposerWrapper.h
index 362a854f7..6270e810b 100644
--- a/extensions/prometheus/PrometheusExposerWrapper.h
+++ b/extensions/prometheus/PrometheusExposerWrapper.h
@@ -21,8 +21,8 @@
#include <vector>
#include "MetricsExposer.h"
-#include "controllers/SSLContextServiceInterface.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "prometheus/exposer.h"
diff --git a/extensions/prometheus/PrometheusMetricsPublisher.h b/extensions/prometheus/PrometheusMetricsPublisher.h
index cd1f68443..91d9ba3c0 100644
--- a/extensions/prometheus/PrometheusMetricsPublisher.h
+++ b/extensions/prometheus/PrometheusMetricsPublisher.h
@@ -24,7 +24,7 @@
#include "core/state/MetricsPublisher.h"
#include "PublishedMetricGaugeCollection.h"
#include "core/Core.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "utils/Id.h"
#include "PrometheusExposerWrapper.h"
diff --git a/extensions/prometheus/PublishedMetricGaugeCollection.cpp b/extensions/prometheus/PublishedMetricGaugeCollection.cpp
index c55c5822b..63403badb 100644
--- a/extensions/prometheus/PublishedMetricGaugeCollection.cpp
+++ b/extensions/prometheus/PublishedMetricGaugeCollection.cpp
@@ -20,7 +20,7 @@
#include <algorithm>
#include "prometheus/client_metric.h"
-#include "core/state/PublishedMetricProvider.h"
+#include "minifi-cpp/core/state/PublishedMetricProvider.h"
#include "range/v3/range/conversion.hpp"
#include "range/v3/view/transform.hpp"
diff --git a/extensions/prometheus/PublishedMetricGaugeCollection.h b/extensions/prometheus/PublishedMetricGaugeCollection.h
index bafa6acaa..c4c8f9fb7 100644
--- a/extensions/prometheus/PublishedMetricGaugeCollection.h
+++ b/extensions/prometheus/PublishedMetricGaugeCollection.h
@@ -20,10 +20,10 @@
#include <vector>
#include <string>
-#include "core/state/PublishedMetricProvider.h"
+#include "minifi-cpp/core/state/PublishedMetricProvider.h"
#include "prometheus/collectable.h"
#include "prometheus/metric_family.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::extensions::prometheus {
diff --git a/extensions/python/ExecutePythonProcessor.cpp b/extensions/python/ExecutePythonProcessor.cpp
index 52c77383d..33480ab8f 100644
--- a/extensions/python/ExecutePythonProcessor.cpp
+++ b/extensions/python/ExecutePythonProcessor.cpp
@@ -22,7 +22,7 @@
#include <utility>
#include "PythonConfigState.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/Resource.h"
#include "range/v3/algorithm/find_if.hpp"
#include "range/v3/range/conversion.hpp"
diff --git a/extensions/python/ExecutePythonProcessor.h b/extensions/python/ExecutePythonProcessor.h
index 5f2d13b00..f16799d03 100644
--- a/extensions/python/ExecutePythonProcessor.h
+++ b/extensions/python/ExecutePythonProcessor.h
@@ -29,12 +29,12 @@
#include "concurrentqueue.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "PythonScriptEngine.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::extensions::python::processors {
diff --git a/extensions/python/PythonDependencyInstaller.h b/extensions/python/PythonDependencyInstaller.h
index 87a99b90c..50fe794ba 100644
--- a/extensions/python/PythonDependencyInstaller.h
+++ b/extensions/python/PythonDependencyInstaller.h
@@ -20,9 +20,9 @@
#include <memory>
#include <filesystem>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "properties/Configure.h"
+#include "minifi-cpp/properties/Configure.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/PythonProcessor.h b/extensions/python/PythonProcessor.h
index a367a7dde..0abe2be27 100644
--- a/extensions/python/PythonProcessor.h
+++ b/extensions/python/PythonProcessor.h
@@ -24,7 +24,7 @@
#include <optional>
#include "core/ProcessorImpl.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/PythonScriptEngine.h b/extensions/python/PythonScriptEngine.h
index 8b7348a9c..fa45c5259 100644
--- a/extensions/python/PythonScriptEngine.h
+++ b/extensions/python/PythonScriptEngine.h
@@ -34,7 +34,7 @@
#include "types/PyProcessSession.h"
#include "PythonScriptException.h"
#include "PythonInterpreter.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/tests/PythonManifestTests.cpp b/extensions/python/tests/PythonManifestTests.cpp
index 1afbfb751..303b2cb9f 100644
--- a/extensions/python/tests/PythonManifestTests.cpp
+++ b/extensions/python/tests/PythonManifestTests.cpp
@@ -19,14 +19,14 @@
#include <fstream>
-#include "agent/agent_version.h"
+#include "minifi-cpp/agent/agent_version.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
#include "unit/TestControllerWithFlow.h"
#include "unit/EmptyFlow.h"
#include "unit/TestUtils.h"
#include "c2/C2MetricsPublisher.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
using minifi::state::response::SerializedResponseNode;
using minifi::state::response::ValueNode;
diff --git a/extensions/python/types/PyInputStream.cpp b/extensions/python/types/PyInputStream.cpp
index a95e84e72..c7f4b9fc3 100644
--- a/extensions/python/types/PyInputStream.cpp
+++ b/extensions/python/types/PyInputStream.cpp
@@ -20,7 +20,7 @@
#include <vector>
#include "Types.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
extern "C" {
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyInputStream.h b/extensions/python/types/PyInputStream.h
index 73e4d41a1..a2a45ec21 100644
--- a/extensions/python/types/PyInputStream.h
+++ b/extensions/python/types/PyInputStream.h
@@ -20,7 +20,7 @@
#include <memory>
#include "../PythonBindings.h"
-#include "io/InputStream.h"
+#include "minifi-cpp/io/InputStream.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyLogger.cpp b/extensions/python/types/PyLogger.cpp
index 9ff69479d..78b9c3f26 100644
--- a/extensions/python/types/PyLogger.cpp
+++ b/extensions/python/types/PyLogger.cpp
@@ -16,7 +16,7 @@
*/
#include "PyLogger.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
extern "C" {
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyLogger.h b/extensions/python/types/PyLogger.h
index 16e04f288..9f456d571 100644
--- a/extensions/python/types/PyLogger.h
+++ b/extensions/python/types/PyLogger.h
@@ -19,7 +19,7 @@
#include <memory>
#include "../PythonBindings.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyOutputStream.h b/extensions/python/types/PyOutputStream.h
index c6cdc97be..a3a5e4305 100644
--- a/extensions/python/types/PyOutputStream.h
+++ b/extensions/python/types/PyOutputStream.h
@@ -21,7 +21,7 @@
#include <memory>
#include "../PythonBindings.h"
-#include "io/OutputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyProcessContext.cpp b/extensions/python/types/PyProcessContext.cpp
index d34de6603..3724e5bc9 100644
--- a/extensions/python/types/PyProcessContext.cpp
+++ b/extensions/python/types/PyProcessContext.cpp
@@ -22,8 +22,8 @@ a * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#include "PyStateManager.h"
#include "PyScriptFlowFile.h"
#include "core/ProcessorImpl.h"
-#include "controllers/RecordSetReader.h"
-#include "controllers/RecordSetWriter.h"
+#include "minifi-cpp/controllers/RecordSetReader.h"
+#include "minifi-cpp/controllers/RecordSetWriter.h"
extern "C" {
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyProcessContext.h b/extensions/python/types/PyProcessContext.h
index 82ad13abe..4423751e6 100644
--- a/extensions/python/types/PyProcessContext.h
+++ b/extensions/python/types/PyProcessContext.h
@@ -18,7 +18,7 @@
#include <memory>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "PySSLContextService.h"
#include "PyRecordSetReader.h"
#include "PyRecordSetWriter.h"
diff --git a/extensions/python/types/PyProcessSession.cpp b/extensions/python/types/PyProcessSession.cpp
index f2278b75d..ff20af314 100644
--- a/extensions/python/types/PyProcessSession.cpp
+++ b/extensions/python/types/PyProcessSession.cpp
@@ -23,7 +23,7 @@
#include "types/PyOutputStream.h"
#include "types/PyInputStream.h"
#include "range/v3/algorithm/remove_if.hpp"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyRecordSetReader.h b/extensions/python/types/PyRecordSetReader.h
index b0488ff5e..7bacc2422 100644
--- a/extensions/python/types/PyRecordSetReader.h
+++ b/extensions/python/types/PyRecordSetReader.h
@@ -18,7 +18,7 @@
#include <memory>
-#include "controllers/RecordSetReader.h"
+#include "minifi-cpp/controllers/RecordSetReader.h"
#include "../PythonBindings.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyRecordSetWriter.h b/extensions/python/types/PyRecordSetWriter.h
index 661173874..bf7494fbd 100644
--- a/extensions/python/types/PyRecordSetWriter.h
+++ b/extensions/python/types/PyRecordSetWriter.h
@@ -18,7 +18,7 @@
#include <memory>
-#include "controllers/RecordSetWriter.h"
+#include "minifi-cpp/controllers/RecordSetWriter.h"
#include "../PythonBindings.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PySSLContextService.h b/extensions/python/types/PySSLContextService.h
index 3fd5e7fec..d42607e89 100644
--- a/extensions/python/types/PySSLContextService.h
+++ b/extensions/python/types/PySSLContextService.h
@@ -19,7 +19,7 @@
#include <memory>
#include "../PythonBindings.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyScriptFlowFile.h b/extensions/python/types/PyScriptFlowFile.h
index 932444d8f..71c040754 100644
--- a/extensions/python/types/PyScriptFlowFile.h
+++ b/extensions/python/types/PyScriptFlowFile.h
@@ -18,7 +18,7 @@
#include <memory>
#include "../PythonBindings.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/PyStateManager.h b/extensions/python/types/PyStateManager.h
index b762a23da..8a9f07d76 100644
--- a/extensions/python/types/PyStateManager.h
+++ b/extensions/python/types/PyStateManager.h
@@ -18,7 +18,7 @@
#include <memory>
-#include "core/StateManager.h"
+#include "minifi-cpp/core/StateManager.h"
#include "../PythonBindings.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/python/types/Types.h b/extensions/python/types/Types.h
index 4118d03b0..98f114bab 100644
--- a/extensions/python/types/Types.h
+++ b/extensions/python/types/Types.h
@@ -22,7 +22,7 @@
#include <utility>
#include "../PyException.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::extensions::python {
diff --git a/extensions/rocksdb-repos/DatabaseContentRepository.cpp b/extensions/rocksdb-repos/DatabaseContentRepository.cpp
index 6bfa6cefa..ddb7b0dc0 100644
--- a/extensions/rocksdb-repos/DatabaseContentRepository.cpp
+++ b/extensions/rocksdb-repos/DatabaseContentRepository.cpp
@@ -23,7 +23,7 @@
#include <utility>
#include <vector>
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "RocksDbStream.h"
#include "core/Resource.h"
#include "core/TypedValues.h"
@@ -31,7 +31,7 @@
#include "database/StringAppender.h"
#include "encryption/RocksDbEncryptionProvider.h"
#include "utils/Locations.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::core::repository {
diff --git a/extensions/rocksdb-repos/DatabaseContentRepository.h b/extensions/rocksdb-repos/DatabaseContentRepository.h
index 8b430dce8..7dd24898a 100644
--- a/extensions/rocksdb-repos/DatabaseContentRepository.h
+++ b/extensions/rocksdb-repos/DatabaseContentRepository.h
@@ -26,9 +26,9 @@
#include "core/ContentRepository.h"
#include "core/BufferedContentSession.h"
#include "core/logging/LoggerFactory.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "database/RocksDatabase.h"
-#include "properties/Configure.h"
+#include "minifi-cpp/properties/Configure.h"
#include "utils/StoppableThread.h"
namespace org::apache::nifi::minifi::core::repository {
diff --git a/extensions/rocksdb-repos/FlowFileLoader.cpp b/extensions/rocksdb-repos/FlowFileLoader.cpp
index 8eb2c685d..07b413739 100644
--- a/extensions/rocksdb-repos/FlowFileLoader.cpp
+++ b/extensions/rocksdb-repos/FlowFileLoader.cpp
@@ -24,8 +24,8 @@
#include <utility>
#include "core/logging/LoggerFactory.h"
-#include "utils/gsl.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/FlowFileRecord.h"
namespace org::apache::nifi::minifi {
diff --git a/extensions/rocksdb-repos/FlowFileLoader.h b/extensions/rocksdb-repos/FlowFileLoader.h
index f18ab53fd..99160ed45 100644
--- a/extensions/rocksdb-repos/FlowFileLoader.h
+++ b/extensions/rocksdb-repos/FlowFileLoader.h
@@ -23,11 +23,11 @@
#include <memory>
#include "database/RocksDatabase.h"
-#include "utils/gsl.h"
-#include "core/ContentRepository.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/core/ContentRepository.h"
#include "minifi-cpp/SwapManager.h"
#include "utils/ThreadPool.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi {
diff --git a/extensions/rocksdb-repos/FlowFileRepository.cpp b/extensions/rocksdb-repos/FlowFileRepository.cpp
index a37bc2751..f955262a8 100644
--- a/extensions/rocksdb-repos/FlowFileRepository.cpp
+++ b/extensions/rocksdb-repos/FlowFileRepository.cpp
@@ -24,14 +24,14 @@
#include <utility>
#include <vector>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/Resource.h"
#include "core/TypedValues.h"
#include "rocksdb/options.h"
#include "rocksdb/slice.h"
#include "utils/Locations.h"
#include "utils/OptionalUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
using namespace std::literals::chrono_literals;
diff --git a/extensions/rocksdb-repos/FlowFileRepository.h b/extensions/rocksdb-repos/FlowFileRepository.h
index 164ef703d..f304bf6d0 100644
--- a/extensions/rocksdb-repos/FlowFileRepository.h
+++ b/extensions/rocksdb-repos/FlowFileRepository.h
@@ -37,7 +37,7 @@
#include "minifi-cpp/SwapManager.h"
#include "FlowFileLoader.h"
#include "range/v3/algorithm/all_of.hpp"
-#include "utils/Literals.h"
+#include "minifi-cpp/utils/Literals.h"
#include "utils/StoppableThread.h"
#include "RocksDbRepository.h"
diff --git a/extensions/rocksdb-repos/ProvenanceRepository.h b/extensions/rocksdb-repos/ProvenanceRepository.h
index 89b89dbe8..3984c9911 100644
--- a/extensions/rocksdb-repos/ProvenanceRepository.h
+++ b/extensions/rocksdb-repos/ProvenanceRepository.h
@@ -29,7 +29,7 @@
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
#include "minifi-cpp/provenance/Provenance.h"
-#include "utils/Literals.h"
+#include "minifi-cpp/utils/Literals.h"
#include "RocksDbRepository.h"
namespace org::apache::nifi::minifi::provenance {
diff --git a/extensions/rocksdb-repos/RocksDbStream.cpp b/extensions/rocksdb-repos/RocksDbStream.cpp
index 2f1dc2af9..1804f4caf 100644
--- a/extensions/rocksdb-repos/RocksDbStream.cpp
+++ b/extensions/rocksdb-repos/RocksDbStream.cpp
@@ -23,7 +23,7 @@
#include <vector>
#include <memory>
#include <string>
-#include <Exception.h>
+#include "minifi-cpp/Exception.h"
#include "io/validation.h"
namespace org::apache::nifi::minifi::io {
diff --git a/extensions/rocksdb-repos/controllers/RocksDbStateStorage.h b/extensions/rocksdb-repos/controllers/RocksDbStateStorage.h
index a02e455a0..da19fc641 100644
--- a/extensions/rocksdb-repos/controllers/RocksDbStateStorage.h
+++ b/extensions/rocksdb-repos/controllers/RocksDbStateStorage.h
@@ -23,9 +23,9 @@
#include "utils/AutoPersistor.h"
#include "controllers/keyvalue/KeyValueStateStorage.h"
#include "core/Core.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "../database/RocksDatabase.h"
diff --git a/extensions/rocksdb-repos/database/OpenRocksDb.h b/extensions/rocksdb-repos/database/OpenRocksDb.h
index 08527177d..b97fe880a 100644
--- a/extensions/rocksdb-repos/database/OpenRocksDb.h
+++ b/extensions/rocksdb-repos/database/OpenRocksDb.h
@@ -22,12 +22,12 @@
#include <string>
#include <vector>
#include <optional>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "rocksdb/db.h"
#include "rocksdb/utilities/checkpoint.h"
#include "WriteBatch.h"
-#include "core/RepositoryMetricsSource.h"
+#include "minifi-cpp/core/RepositoryMetricsSource.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::internal {
diff --git a/extensions/rocksdb-repos/database/RocksDatabase.h b/extensions/rocksdb-repos/database/RocksDatabase.h
index 175d0cb21..a1237ba1f 100644
--- a/extensions/rocksdb-repos/database/RocksDatabase.h
+++ b/extensions/rocksdb-repos/database/RocksDatabase.h
@@ -24,7 +24,7 @@
#include <unordered_map>
#include "rocksdb/db.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "RocksDbUtils.h"
#include "OpenRocksDb.h"
diff --git a/extensions/rocksdb-repos/database/RocksDbInstance.h b/extensions/rocksdb-repos/database/RocksDbInstance.h
index c29240219..ac0d1a50f 100644
--- a/extensions/rocksdb-repos/database/RocksDbInstance.h
+++ b/extensions/rocksdb-repos/database/RocksDbInstance.h
@@ -24,7 +24,7 @@
#include <unordered_map>
#include "RocksDbUtils.h"
#include "rocksdb/db.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::internal {
diff --git a/extensions/rocksdb-repos/database/RocksDbUtils.cpp b/extensions/rocksdb-repos/database/RocksDbUtils.cpp
index 2237767fc..ab25a26fc 100644
--- a/extensions/rocksdb-repos/database/RocksDbUtils.cpp
+++ b/extensions/rocksdb-repos/database/RocksDbUtils.cpp
@@ -19,8 +19,8 @@
#include <string>
-#include "Exception.h"
-#include "utils/Literals.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/utils/Literals.h"
namespace org::apache::nifi::minifi::internal {
diff --git a/extensions/rocksdb-repos/database/RocksDbUtils.h b/extensions/rocksdb-repos/database/RocksDbUtils.h
index 0deac2c85..627517577 100644
--- a/extensions/rocksdb-repos/database/RocksDbUtils.h
+++ b/extensions/rocksdb-repos/database/RocksDbUtils.h
@@ -27,7 +27,7 @@
#include "rocksdb/db.h"
#include "rocksdb/options.h"
#include "utils/GeneralUtils.h"
-#include "properties/Configure.h"
+#include "minifi-cpp/properties/Configure.h"
namespace org::apache::nifi::minifi::internal {
diff --git a/extensions/rocksdb-repos/encryption/RocksDbEncryptionProvider.h b/extensions/rocksdb-repos/encryption/RocksDbEncryptionProvider.h
index 5b8efe562..1dd4c90a3 100644
--- a/extensions/rocksdb-repos/encryption/RocksDbEncryptionProvider.h
+++ b/extensions/rocksdb-repos/encryption/RocksDbEncryptionProvider.h
@@ -23,7 +23,7 @@
#include "rocksdb/env_encryption.h"
#include "utils/crypto/EncryptionUtils.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "utils/crypto/EncryptionManager.h"
namespace org::apache::nifi::minifi::core::repository {
diff --git a/extensions/rocksdb-repos/tests/ContentSessionTests.cpp b/extensions/rocksdb-repos/tests/ContentSessionTests.cpp
index 1a58e4c39..f1e5d9d19 100644
--- a/extensions/rocksdb-repos/tests/ContentSessionTests.cpp
+++ b/extensions/rocksdb-repos/tests/ContentSessionTests.cpp
@@ -25,7 +25,7 @@
#include "VolatileContentRepository.h"
#include "DatabaseContentRepository.h"
#include "core/BufferedContentSession.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
#include "utils/ConfigurationUtils.h"
diff --git a/extensions/rocksdb-repos/tests/DBContentRepositoryTests.cpp b/extensions/rocksdb-repos/tests/DBContentRepositoryTests.cpp
index 7fc19ca4d..50195748b 100644
--- a/extensions/rocksdb-repos/tests/DBContentRepositoryTests.cpp
+++ b/extensions/rocksdb-repos/tests/DBContentRepositoryTests.cpp
@@ -21,14 +21,14 @@
#include "core/Core.h"
#include "DatabaseContentRepository.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "properties/Configure.h"
-#include "provenance/Provenance.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
#include "unit/ProvenanceTestHelper.h"
#include "unit/ContentRepositoryDependentTests.h"
#include "unit/TestUtils.h"
+#include "ResourceClaim.h"
class TestDatabaseContentRepository : public core::repository::DatabaseContentRepository {
public:
diff --git a/extensions/rocksdb-repos/tests/EncryptionTests.cpp b/extensions/rocksdb-repos/tests/EncryptionTests.cpp
index 754d12bd4..2408d8ebb 100644
--- a/extensions/rocksdb-repos/tests/EncryptionTests.cpp
+++ b/extensions/rocksdb-repos/tests/EncryptionTests.cpp
@@ -23,6 +23,7 @@
#include "repository/VolatileContentRepository.h"
#include "FlowFileRecord.h"
#include "utils/span.h"
+#include "Connection.h"
using core::repository::FlowFileRepository;
diff --git a/extensions/rocksdb-repos/tests/ProvenanceTests.cpp b/extensions/rocksdb-repos/tests/ProvenanceTests.cpp
index 21da1df27..ab70db15e 100644
--- a/extensions/rocksdb-repos/tests/ProvenanceTests.cpp
+++ b/extensions/rocksdb-repos/tests/ProvenanceTests.cpp
@@ -25,8 +25,7 @@
#include "core/repository/AtomicRepoEntries.h"
#include "core/repository/VolatileProvenanceRepository.h"
#include "core/RepositoryFactory.h"
-#include "FlowFileRecord.h"
-#include "provenance/Provenance.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "unit/ProvenanceTestHelper.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
@@ -37,7 +36,7 @@ using namespace std::literals::chrono_literals;
TEST_CASE("Test Provenance record create", "[Testprovenance::ProvenanceEventRecord]") {
auto record1 = std::make_shared<provenance::ProvenanceEventRecordImpl>(provenance::ProvenanceEventRecord::ProvenanceEventType::CREATE, "blah", "blahblah");
REQUIRE(record1->getAttributes().empty());
- REQUIRE(record1->getAlternateIdentifierUri().length() == 0);
+ REQUIRE(record1->getAlternateIdentifierUri().empty());
}
TEST_CASE("Test Provenance record serialization", "[Testprovenance::ProvenanceEventRecordSerializeDeser]") {
diff --git a/extensions/rocksdb-repos/tests/RepoTests.cpp b/extensions/rocksdb-repos/tests/RepoTests.cpp
index 4f377f574..138cc7954 100644
--- a/extensions/rocksdb-repos/tests/RepoTests.cpp
+++ b/extensions/rocksdb-repos/tests/RepoTests.cpp
@@ -25,15 +25,14 @@
#include "core/Core.h"
#include "core/repository/AtomicRepoEntries.h"
#include "core/RepositoryFactory.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "FlowFileRepository.h"
#include "ProvenanceRepository.h"
-#include "provenance/Provenance.h"
#include "properties/Configure.h"
#include "unit/ProvenanceTestHelper.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "unit/TestUtils.h"
#include "core/repository/VolatileFlowFileRepository.h"
#include "core/repository/VolatileProvenanceRepository.h"
@@ -41,6 +40,9 @@
#include "catch2/generators/catch_generators.hpp"
#include "core/repository/FileSystemRepository.h"
#include "core/Processor.h"
+#include "Connection.h"
+#include "core/ProcessContext.h"
+#include "ResourceClaim.h"
using namespace std::literals::chrono_literals;
diff --git a/extensions/rocksdb-repos/tests/SwapTests.cpp b/extensions/rocksdb-repos/tests/SwapTests.cpp
index 154922a4f..3c20b60ba 100644
--- a/extensions/rocksdb-repos/tests/SwapTests.cpp
+++ b/extensions/rocksdb-repos/tests/SwapTests.cpp
@@ -24,10 +24,13 @@
#include "unit/TestUtils.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
-#include "core/RelationshipDefinition.h"
+#include "core/ProcessSessionFactory.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "unit/ProvenanceTestHelper.h"
#include "core/repository/FileSystemRepository.h"
+#include "Connection.h"
+#include "core/ProcessContext.h"
namespace org::apache::nifi::minifi::test {
diff --git a/extensions/script/ExecuteScript.h b/extensions/script/ExecuteScript.h
index 1a75f2c89..8de1dc661 100644
--- a/extensions/script/ExecuteScript.h
+++ b/extensions/script/ExecuteScript.h
@@ -26,9 +26,9 @@
#include "concurrentqueue.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "ScriptExecutor.h"
#include "utils/Enum.h"
diff --git a/extensions/script/ScriptExecutor.h b/extensions/script/ScriptExecutor.h
index 1baea83f0..29a63c65a 100644
--- a/extensions/script/ScriptExecutor.h
+++ b/extensions/script/ScriptExecutor.h
@@ -21,7 +21,7 @@
#include <variant>
#include "core/Core.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
namespace org::apache::nifi::minifi::extensions::script {
diff --git a/extensions/sftp/client/SFTPClient.cpp b/extensions/sftp/client/SFTPClient.cpp
index 152f5cdd5..d590f7415 100644
--- a/extensions/sftp/client/SFTPClient.cpp
+++ b/extensions/sftp/client/SFTPClient.cpp
@@ -27,7 +27,7 @@
#include "utils/ConfigurationUtils.h"
#include "utils/StringUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "minifi-cpp/io/OutputStream.h"
#include "minifi-cpp/io/InputStream.h"
diff --git a/extensions/sftp/client/SFTPClient.h b/extensions/sftp/client/SFTPClient.h
index 1764f0042..117a0a083 100644
--- a/extensions/sftp/client/SFTPClient.h
+++ b/extensions/sftp/client/SFTPClient.h
@@ -28,8 +28,8 @@
#include <tuple>
#include <vector>
-#include "Exception.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "http/BaseHTTPClient.h"
#include "utils/Enum.h"
diff --git a/extensions/sftp/processors/FetchSFTP.cpp b/extensions/sftp/processors/FetchSFTP.cpp
index f9d4830dc..4ce4c41d0 100644
--- a/extensions/sftp/processors/FetchSFTP.cpp
+++ b/extensions/sftp/processors/FetchSFTP.cpp
@@ -22,8 +22,8 @@
#include <memory>
#include <utility>
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Relationship.h"
#include "core/Resource.h"
#include "io/BufferStream.h"
diff --git a/extensions/sftp/processors/FetchSFTP.h b/extensions/sftp/processors/FetchSFTP.h
index 510e780f7..3706b6106 100644
--- a/extensions/sftp/processors/FetchSFTP.h
+++ b/extensions/sftp/processors/FetchSFTP.h
@@ -22,11 +22,11 @@
#include "SFTPProcessorBase.h"
#include "utils/ByteArrayCallback.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
#include "core/Core.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extensions/sftp/processors/ListSFTP.cpp b/extensions/sftp/processors/ListSFTP.cpp
index e1677b327..82dd1b062 100644
--- a/extensions/sftp/processors/ListSFTP.cpp
+++ b/extensions/sftp/processors/ListSFTP.cpp
@@ -31,8 +31,8 @@
#include <utility>
#include <vector>
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Resource.h"
#include "io/BufferStream.h"
#include "rapidjson/ostreamwrapper.h"
@@ -384,7 +384,7 @@ bool ListSFTP::updateFromTrackingTimestampsCache(core::ProcessContext& /*context
return false;
}
for (const auto &kv : state_map) {
- if (kv.first.compare(0, strlen("id."), "id.") == 0) {
+ if (kv.first.starts_with("id.")) {
state_ids.emplace(kv.second);
}
}
@@ -420,7 +420,7 @@ void ListSFTP::listByTrackingTimestamps(
uint16_t port,
const std::string& username,
const std::string& remote_path,
- std::vector<Child>&& files) {
+ std::vector<Child> files) {
auto min_timestamp_to_list = last_listed_latest_entry_timestamp_;
/* Load state from cache file if needed */
@@ -676,7 +676,7 @@ void ListSFTP::listByTrackingEntities(
const std::string& username,
const std::string& remote_path,
std::chrono::milliseconds entity_tracking_time_window,
- std::vector<Child>&& files) {
+ std::vector<Child> files) {
/* Load state from cache file if needed */
if (!already_loaded_from_cache_) {
if (updateFromTrackingEntitiesCache(context, hostname, username, remote_path)) {
diff --git a/extensions/sftp/processors/ListSFTP.h b/extensions/sftp/processors/ListSFTP.h
index b8f8da831..7466f879b 100644
--- a/extensions/sftp/processors/ListSFTP.h
+++ b/extensions/sftp/processors/ListSFTP.h
@@ -32,7 +32,7 @@
#include "SFTPProcessorBase.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "utils/ArrayUtils.h"
@@ -279,7 +279,7 @@ class ListSFTP : public SFTPProcessorBase {
uint16_t port,
const std::string& username,
const std::string& remote_path,
- std::vector<Child>&& files);
+ std::vector<Child> files);
void listByTrackingEntities(
core::ProcessContext& context,
@@ -289,7 +289,7 @@ class ListSFTP : public SFTPProcessorBase {
const std::string& username,
const std::string& remote_path,
std::chrono::milliseconds entity_tracking_time_window,
- std::vector<Child>&& files);
+ std::vector<Child> files);
};
} // namespace org::apache::nifi::minifi::processors
diff --git a/extensions/sftp/processors/PutSFTP.cpp b/extensions/sftp/processors/PutSFTP.cpp
index 41cd0b8bf..4554f982e 100644
--- a/extensions/sftp/processors/PutSFTP.cpp
+++ b/extensions/sftp/processors/PutSFTP.cpp
@@ -23,15 +23,16 @@
#include <memory>
#include <utility>
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Resource.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "io/BufferStream.h"
#include "utils/ConfigurationUtils.h"
#include "utils/StringUtils.h"
#include "utils/file/FileUtils.h"
#include "utils/ProcessorConfigUtils.h"
+#include "io/validation.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/sftp/processors/PutSFTP.h b/extensions/sftp/processors/PutSFTP.h
index 92bc62411..8c3ac8333 100644
--- a/extensions/sftp/processors/PutSFTP.h
+++ b/extensions/sftp/processors/PutSFTP.h
@@ -26,15 +26,15 @@
#include "SFTPProcessorBase.h"
#include "utils/ByteArrayCallback.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
#include "core/Core.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/logging/LoggerFactory.h"
#include "utils/ArrayUtils.h"
#include "utils/Id.h"
diff --git a/extensions/sftp/processors/SFTPProcessorBase.cpp b/extensions/sftp/processors/SFTPProcessorBase.cpp
index 4587d94ef..c06cf285d 100644
--- a/extensions/sftp/processors/SFTPProcessorBase.cpp
+++ b/extensions/sftp/processors/SFTPProcessorBase.cpp
@@ -31,15 +31,16 @@
#include <utility>
#include <vector>
-#include "ResourceClaim.h"
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/ResourceClaim.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Relationship.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "io/BufferStream.h"
#include "utils/ByteArrayCallback.h"
#include "utils/StringUtils.h"
#include "utils/ProcessorConfigUtils.h"
+#include "io/validation.h"
namespace org::apache::nifi::minifi::processors {
@@ -184,9 +185,7 @@ void SFTPProcessorBase::keepaliveThreadFunc() {
connection.first.hostname,
connection.first.port,
seconds_to_next);
- if (seconds_to_next < min_wait) {
- min_wait = seconds_to_next;
- }
+ min_wait = std::min(min_wait, seconds_to_next);
} else {
logger_->log_debug("Failed to send keepalive to {}@{}:{}",
connection.first.username,
@@ -196,9 +195,7 @@ void SFTPProcessorBase::keepaliveThreadFunc() {
}
/* Avoid busy loops */
- if (min_wait < 1) {
- min_wait = 1;
- }
+ min_wait = std::max(min_wait, 1);
logger_->log_trace("Keepalive thread is going to sleep for {} s", min_wait);
keepalive_cv_.wait_for(lock, std::chrono::seconds(min_wait), [this] {
diff --git a/extensions/sftp/processors/SFTPProcessorBase.h b/extensions/sftp/processors/SFTPProcessorBase.h
index d68ce7aa9..ad0fc88f5 100644
--- a/extensions/sftp/processors/SFTPProcessorBase.h
+++ b/extensions/sftp/processors/SFTPProcessorBase.h
@@ -26,13 +26,13 @@
#include <thread>
#include <vector>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "utils/Id.h"
#include "../client/SFTPClient.h"
diff --git a/extensions/sftp/tests/ListSFTPTests.cpp b/extensions/sftp/tests/ListSFTPTests.cpp
index d3ee16d9c..59a658503 100644
--- a/extensions/sftp/tests/ListSFTPTests.cpp
+++ b/extensions/sftp/tests/ListSFTPTests.cpp
@@ -39,7 +39,7 @@
#include "unit/Catch.h"
#include "utils/file/FileUtils.h"
#include "core/Core.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/ProcessGroup.h"
#include "FlowController.h"
#include "properties/Configure.h"
diff --git a/extensions/sftp/tests/ListThenFetchSFTPTests.cpp b/extensions/sftp/tests/ListThenFetchSFTPTests.cpp
index 8e38f13da..cd821bdd3 100644
--- a/extensions/sftp/tests/ListThenFetchSFTPTests.cpp
+++ b/extensions/sftp/tests/ListThenFetchSFTPTests.cpp
@@ -35,7 +35,7 @@
#include "unit/TestBase.h"
#include "unit/Catch.h"
#include "utils/file/FileUtils.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/ProcessGroup.h"
#include "FlowController.h"
#include "unit/ProvenanceTestHelper.h"
@@ -158,7 +158,7 @@ class ListThenFetchSFTPTestsFixture {
}
void createFileWithModificationTimeDiff(const std::string& relative_path, const std::string& content, std::chrono::seconds modification_timediff = -5min) const {
- return createFile(relative_path, content, std::chrono::file_clock::now() + modification_timediff);
+ createFile(relative_path, content, std::chrono::file_clock::now() + modification_timediff);
}
enum TestWhere {
diff --git a/extensions/sftp/tests/PutSFTPTests.cpp b/extensions/sftp/tests/PutSFTPTests.cpp
index cb7c29bf6..db33284a2 100644
--- a/extensions/sftp/tests/PutSFTPTests.cpp
+++ b/extensions/sftp/tests/PutSFTPTests.cpp
@@ -38,11 +38,11 @@
#include "unit/TestBase.h"
#include "unit/Catch.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "date/date.h"
#include "utils/file/FileUtils.h"
#include "core/Core.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/ProcessGroup.h"
#include "FlowController.h"
#include "unit/ProvenanceTestHelper.h"
diff --git a/extensions/sftp/tests/tools/SFTPTestServer.h b/extensions/sftp/tests/tools/SFTPTestServer.h
index 421582134..49b99a4f0 100644
--- a/extensions/sftp/tests/tools/SFTPTestServer.h
+++ b/extensions/sftp/tests/tools/SFTPTestServer.h
@@ -26,7 +26,7 @@
#include <sys/types.h>
#endif
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
std::filesystem::path get_sftp_test_dir();
diff --git a/extensions/smb/FetchSmb.h b/extensions/smb/FetchSmb.h
index 044c51c0c..06519882e 100644
--- a/extensions/smb/FetchSmb.h
+++ b/extensions/smb/FetchSmb.h
@@ -25,10 +25,10 @@
#include "SmbConnectionControllerService.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/Property.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/logging/LoggerFactory.h"
#include "utils/Enum.h"
#include "utils/ListingStateManager.h"
diff --git a/extensions/smb/ListSmb.h b/extensions/smb/ListSmb.h
index 52cc3566c..d570891b4 100644
--- a/extensions/smb/ListSmb.h
+++ b/extensions/smb/ListSmb.h
@@ -25,10 +25,10 @@
#include "SmbConnectionControllerService.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/Property.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/Property.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/logging/LoggerFactory.h"
#include "utils/Enum.h"
#include "utils/ListingStateManager.h"
diff --git a/extensions/smb/PutSmb.cpp b/extensions/smb/PutSmb.cpp
index fadd10c9e..d1313f7e0 100644
--- a/extensions/smb/PutSmb.cpp
+++ b/extensions/smb/PutSmb.cpp
@@ -17,7 +17,7 @@
*/
#include "PutSmb.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ProcessorConfigUtils.h"
#include "utils/OsUtils.h"
#include "utils/file/FileWriterCallback.h"
diff --git a/extensions/smb/SmbConnectionControllerService.cpp b/extensions/smb/SmbConnectionControllerService.cpp
index 8a61a5a79..3a9c930a5 100644
--- a/extensions/smb/SmbConnectionControllerService.cpp
+++ b/extensions/smb/SmbConnectionControllerService.cpp
@@ -20,6 +20,7 @@
#include "core/Resource.h"
#include "utils/OsUtils.h"
#include "utils/expected.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::extensions::smb {
diff --git a/extensions/smb/SmbConnectionControllerService.h b/extensions/smb/SmbConnectionControllerService.h
index 274376d48..a1ddcb2a0 100644
--- a/extensions/smb/SmbConnectionControllerService.h
+++ b/extensions/smb/SmbConnectionControllerService.h
@@ -23,11 +23,11 @@
#include "Windows.h"
#include "winnetwk.h"
-#include "core/ProcessContext.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "core/controller/ControllerService.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "utils/Enum.h"
#include "utils/expected.h"
diff --git a/extensions/smb/tests/utils/MockSmbConnectionControllerService.h b/extensions/smb/tests/utils/MockSmbConnectionControllerService.h
index 22a53363b..bc158df48 100644
--- a/extensions/smb/tests/utils/MockSmbConnectionControllerService.h
+++ b/extensions/smb/tests/utils/MockSmbConnectionControllerService.h
@@ -19,7 +19,6 @@
#include <utility>
#include <string>
#include "../../SmbConnectionControllerService.h"
-#include "core/controller/ControllerService.h"
#include "utils/OsUtils.h"
#include "utils/file/FileUtils.h"
#include "ListSmb.h"
diff --git a/extensions/splunk/PutSplunkHTTP.cpp b/extensions/splunk/PutSplunkHTTP.cpp
index 4abe8ee7a..953966e4e 100644
--- a/extensions/splunk/PutSplunkHTTP.cpp
+++ b/extensions/splunk/PutSplunkHTTP.cpp
@@ -21,7 +21,7 @@
#include <vector>
#include "SplunkAttributes.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "http/BaseHTTPClient.h"
diff --git a/extensions/splunk/PutSplunkHTTP.h b/extensions/splunk/PutSplunkHTTP.h
index eb694dcb5..2f0282408 100644
--- a/extensions/splunk/PutSplunkHTTP.h
+++ b/extensions/splunk/PutSplunkHTTP.h
@@ -23,12 +23,12 @@
#include "SplunkHECProcessor.h"
#include "http/HTTPClient.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/ArrayUtils.h"
#include "utils/ResourceQueue.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::extensions::splunk {
diff --git a/extensions/splunk/QuerySplunkIndexingStatus.cpp b/extensions/splunk/QuerySplunkIndexingStatus.cpp
index 819a44422..d74007cfc 100644
--- a/extensions/splunk/QuerySplunkIndexingStatus.cpp
+++ b/extensions/splunk/QuerySplunkIndexingStatus.cpp
@@ -22,7 +22,7 @@
#include <utility>
#include "SplunkAttributes.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "http/HTTPClient.h"
diff --git a/extensions/splunk/QuerySplunkIndexingStatus.h b/extensions/splunk/QuerySplunkIndexingStatus.h
index 1973735da..185d6617d 100644
--- a/extensions/splunk/QuerySplunkIndexingStatus.h
+++ b/extensions/splunk/QuerySplunkIndexingStatus.h
@@ -22,12 +22,12 @@
#include <utility>
#include "SplunkHECProcessor.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/ArrayUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "http/HTTPClient.h"
#include "rapidjson/stringbuffer.h"
diff --git a/extensions/splunk/SplunkHECProcessor.cpp b/extensions/splunk/SplunkHECProcessor.cpp
index 4427668aa..06308153a 100644
--- a/extensions/splunk/SplunkHECProcessor.cpp
+++ b/extensions/splunk/SplunkHECProcessor.cpp
@@ -19,7 +19,7 @@
#include <utility>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "http/HTTPClient.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/splunk/SplunkHECProcessor.h b/extensions/splunk/SplunkHECProcessor.h
index dbc58ebf5..25a78be28 100644
--- a/extensions/splunk/SplunkHECProcessor.h
+++ b/extensions/splunk/SplunkHECProcessor.h
@@ -20,10 +20,10 @@
#include <string>
#include <utility>
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/Core.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "http/HTTPClient.h"
#include "minifi-cpp/core/PropertyValidator.h"
diff --git a/extensions/splunk/tests/MockSplunkHEC.h b/extensions/splunk/tests/MockSplunkHEC.h
index 13bce3990..854153468 100644
--- a/extensions/splunk/tests/MockSplunkHEC.h
+++ b/extensions/splunk/tests/MockSplunkHEC.h
@@ -23,7 +23,7 @@
#include <vector>
#include <CivetServer.h>
#include "integration/CivetLibrary.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "rapidjson/document.h"
#include "rapidjson/writer.h"
diff --git a/extensions/sql/data/JSONSQLWriter.cpp b/extensions/sql/data/JSONSQLWriter.cpp
index ac609dbe7..05375a4ae 100644
--- a/extensions/sql/data/JSONSQLWriter.cpp
+++ b/extensions/sql/data/JSONSQLWriter.cpp
@@ -20,7 +20,7 @@
#include "rapidjson/writer.h"
#include "rapidjson/stringbuffer.h"
#include "rapidjson/prettywriter.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::sql {
diff --git a/extensions/sql/data/SQLRowsetProcessor.cpp b/extensions/sql/data/SQLRowsetProcessor.cpp
index c4194847d..01c997487 100644
--- a/extensions/sql/data/SQLRowsetProcessor.cpp
+++ b/extensions/sql/data/SQLRowsetProcessor.cpp
@@ -18,14 +18,10 @@
#include "SQLRowsetProcessor.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "utils/StringUtils.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace sql {
+namespace org::apache::nifi::minifi::sql {
SQLRowsetProcessor::SQLRowsetProcessor(std::unique_ptr<Rowset> rowset, std::vector<std::reference_wrapper<SQLRowSubscriber>> row_subscribers)
: rowset_(std::move(rowset)), row_subscribers_(std::move(row_subscribers)) {
@@ -104,11 +100,11 @@ void SQLRowsetProcessor::addRow(const Row& row, size_t rowCount) {
case DataType::DATE: {
const std::tm when = row.getDate(i);
- char value[128];
- if (!std::strftime(value, sizeof(value), "%Y-%m-%d %H:%M:%S", &when))
+ std::array<char, 128> value{};
+ if (!std::strftime(value.data(), value.size(), "%Y-%m-%d %H:%M:%S", &when))
throw minifi::Exception(PROCESSOR_EXCEPTION, "SQLRowsetProcessor: !strftime.");
- processColumn(name, std::string(value));
+ processColumn(name, std::string(value.data()));
}
break;
default: {
@@ -123,9 +119,4 @@ void SQLRowsetProcessor::addRow(const Row& row, size_t rowCount) {
}
}
-} /* namespace sql */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
-
+} // namespace org::apache::nifi::minifi::sql
diff --git a/extensions/sql/data/SociConnectors.h b/extensions/sql/data/SociConnectors.h
index 62e17194b..d7d4f739e 100644
--- a/extensions/sql/data/SociConnectors.h
+++ b/extensions/sql/data/SociConnectors.h
@@ -24,9 +24,9 @@
#include <string>
#include <ctime>
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "data/DatabaseConnectors.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::sql {
diff --git a/extensions/sql/processors/ExecuteSQL.cpp b/extensions/sql/processors/ExecuteSQL.cpp
index 6327e33b4..0adf68d49 100644
--- a/extensions/sql/processors/ExecuteSQL.cpp
+++ b/extensions/sql/processors/ExecuteSQL.cpp
@@ -21,10 +21,10 @@
#include <utility>
#include "io/StreamPipe.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "utils/ProcessorConfigUtils.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/sql/processors/ExecuteSQL.h b/extensions/sql/processors/ExecuteSQL.h
index 716fb9a35..9cc315f10 100644
--- a/extensions/sql/processors/ExecuteSQL.h
+++ b/extensions/sql/processors/ExecuteSQL.h
@@ -23,13 +23,13 @@
#include <string>
#include "core/ProcessSession.h"
-#include "core/ProcessContext.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "SQLProcessor.h"
#include "FlowFileSource.h"
#include "utils/ArrayUtils.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/sql/processors/FlowFileSource.h b/extensions/sql/processors/FlowFileSource.h
index bb24a77e3..0a75e8f1d 100644
--- a/extensions/sql/processors/FlowFileSource.h
+++ b/extensions/sql/processors/FlowFileSource.h
@@ -21,7 +21,7 @@
#include <vector>
#include <memory>
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "utils/Enum.h"
diff --git a/extensions/sql/processors/PutSQL.cpp b/extensions/sql/processors/PutSQL.cpp
index 63f0b41ea..b603200db 100644
--- a/extensions/sql/processors/PutSQL.cpp
+++ b/extensions/sql/processors/PutSQL.cpp
@@ -21,10 +21,10 @@
#include <utility>
#include "io/BufferStream.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/sql/processors/PutSQL.h b/extensions/sql/processors/PutSQL.h
index 0c4550747..0bd7159a6 100644
--- a/extensions/sql/processors/PutSQL.h
+++ b/extensions/sql/processors/PutSQL.h
@@ -24,10 +24,10 @@
#include "core/ProcessSession.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "SQLProcessor.h"
#include "utils/ArrayUtils.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/sql/processors/QueryDatabaseTable.cpp b/extensions/sql/processors/QueryDatabaseTable.cpp
index 6c5f66b3d..3f63d7f6f 100644
--- a/extensions/sql/processors/QueryDatabaseTable.cpp
+++ b/extensions/sql/processors/QueryDatabaseTable.cpp
@@ -22,10 +22,10 @@
#include <algorithm>
#include "io/BufferStream.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "data/MaxCollector.h"
#include "utils/StringUtils.h"
#include "utils/ProcessorConfigUtils.h"
@@ -143,7 +143,7 @@ bool QueryDatabaseTable::loadMaxValuesFromStoredState(const std::unordered_map<s
}
}
for (auto& column : max_value_columns_) {
- if (new_max_values.find(column) == new_max_values.end()) {
+ if (!new_max_values.contains(column)) {
logger_->log_info("New maximum-value column \"{}\" specified, resetting state.", column.str());
return false;
}
diff --git a/extensions/sql/processors/QueryDatabaseTable.h b/extensions/sql/processors/QueryDatabaseTable.h
index 930d9b51f..c148fe974 100644
--- a/extensions/sql/processors/QueryDatabaseTable.h
+++ b/extensions/sql/processors/QueryDatabaseTable.h
@@ -30,9 +30,9 @@
#include "FlowFileSource.h"
#include "SQLProcessor.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/StateManager.h"
+#include "minifi-cpp/core/StateManager.h"
#include "data/SQLColumnIdentifier.h"
#include "utils/ArrayUtils.h"
diff --git a/extensions/sql/processors/SQLProcessor.cpp b/extensions/sql/processors/SQLProcessor.cpp
index 8c88c535d..87cc9470f 100644
--- a/extensions/sql/processors/SQLProcessor.cpp
+++ b/extensions/sql/processors/SQLProcessor.cpp
@@ -20,10 +20,10 @@
#include <vector>
#include <memory>
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "utils/ProcessorConfigUtils.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/sql/processors/SQLProcessor.h b/extensions/sql/processors/SQLProcessor.h
index 2cd34194d..96fc68332 100644
--- a/extensions/sql/processors/SQLProcessor.h
+++ b/extensions/sql/processors/SQLProcessor.h
@@ -23,7 +23,7 @@
#include "core/Core.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "utils/Enum.h"
diff --git a/extensions/sql/services/DatabaseService.cpp b/extensions/sql/services/DatabaseService.cpp
index d29a68bf8..1ccae3b63 100644
--- a/extensions/sql/services/DatabaseService.cpp
+++ b/extensions/sql/services/DatabaseService.cpp
@@ -22,7 +22,7 @@
#include "core/controller/ControllerService.h"
#include "DatabaseService.h"
#include "io/validation.h"
-#include "properties/Configure.h"
+#include "minifi-cpp/properties/Configure.h"
namespace org::apache::nifi::minifi::sql::controllers {
diff --git a/extensions/sql/services/DatabaseService.h b/extensions/sql/services/DatabaseService.h
index 0679d476e..03a5df71a 100644
--- a/extensions/sql/services/DatabaseService.h
+++ b/extensions/sql/services/DatabaseService.h
@@ -23,7 +23,7 @@
#include "core/logging/LoggerFactory.h"
#include "core/controller/ControllerService.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "data/DatabaseConnectors.h"
diff --git a/extensions/sql/tests/FlowFileMatcher.h b/extensions/sql/tests/FlowFileMatcher.h
index 9733ae989..c7bf61443 100644
--- a/extensions/sql/tests/FlowFileMatcher.h
+++ b/extensions/sql/tests/FlowFileMatcher.h
@@ -27,7 +27,7 @@
#include "unit/TestBase.h"
#include "unit/Catch.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
struct AttributeValue {
explicit AttributeValue(std::string value)
diff --git a/extensions/sql/tests/SQLTestPlan.h b/extensions/sql/tests/SQLTestPlan.h
index 6bca65306..1068190e7 100644
--- a/extensions/sql/tests/SQLTestPlan.h
+++ b/extensions/sql/tests/SQLTestPlan.h
@@ -29,6 +29,8 @@
#include "unit/TestBase.h"
#include "unit/Catch.h"
#include "processors/SQLProcessor.h"
+#include "FlowFileRecord.h"
+#include "ResourceClaim.h"
#ifdef MINIFI_USE_REAL_ODBC_TEST_DRIVER
static const std::string ODBC_SERVICE = "ODBCService";
diff --git a/extensions/standard-processors/controllers/InMemoryKeyValueStorage.h b/extensions/standard-processors/controllers/InMemoryKeyValueStorage.h
index 1ca503689..ffe0b11a0 100644
--- a/extensions/standard-processors/controllers/InMemoryKeyValueStorage.h
+++ b/extensions/standard-processors/controllers/InMemoryKeyValueStorage.h
@@ -22,7 +22,7 @@
#include <unordered_map>
#include <utility>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::controllers {
diff --git a/extensions/standard-processors/controllers/JsonRecordSetWriter.h b/extensions/standard-processors/controllers/JsonRecordSetWriter.h
index 97553f37b..dfb126b6d 100644
--- a/extensions/standard-processors/controllers/JsonRecordSetWriter.h
+++ b/extensions/standard-processors/controllers/JsonRecordSetWriter.h
@@ -18,7 +18,7 @@
#include "core/PropertyDefinitionBuilder.h"
#include "controllers/RecordSetWriter.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/ProcessSession.h"
#include "utils/Enum.h"
#include "rapidjson/document.h"
diff --git a/extensions/standard-processors/controllers/PersistentMapStateStorage.h b/extensions/standard-processors/controllers/PersistentMapStateStorage.h
index bfb5fbe7a..e1a59d13e 100644
--- a/extensions/standard-processors/controllers/PersistentMapStateStorage.h
+++ b/extensions/standard-processors/controllers/PersistentMapStateStorage.h
@@ -24,13 +24,13 @@
#include "utils/AutoPersistor.h"
#include "core/Core.h"
-#include "properties/Configure.h"
#include "InMemoryKeyValueStorage.h"
#include "controllers/keyvalue/KeyValueStateStorage.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
+#include "minifi-cpp/properties/Configure.h"
#include "minifi-cpp/core/PropertyValidator.h"
namespace org::apache::nifi::minifi::controllers {
diff --git a/extensions/standard-processors/controllers/VolatileMapStateStorage.h b/extensions/standard-processors/controllers/VolatileMapStateStorage.h
index e5572cf38..d3b8c6b4d 100644
--- a/extensions/standard-processors/controllers/VolatileMapStateStorage.h
+++ b/extensions/standard-processors/controllers/VolatileMapStateStorage.h
@@ -23,10 +23,10 @@
#include <utility>
#include "core/Core.h"
-#include "properties/Configure.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/properties/Configure.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "controllers/keyvalue/KeyValueStateStorage.h"
#include "InMemoryKeyValueStorage.h"
diff --git a/extensions/standard-processors/controllers/XMLReader.cpp b/extensions/standard-processors/controllers/XMLReader.cpp
index 56749b258..88cebe7ba 100644
--- a/extensions/standard-processors/controllers/XMLReader.cpp
+++ b/extensions/standard-processors/controllers/XMLReader.cpp
@@ -22,7 +22,7 @@
#include "core/Resource.h"
#include "utils/TimeUtil.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::standard {
diff --git a/extensions/standard-processors/controllers/XMLReader.h b/extensions/standard-processors/controllers/XMLReader.h
index 44b045cf1..383be487d 100644
--- a/extensions/standard-processors/controllers/XMLReader.h
+++ b/extensions/standard-processors/controllers/XMLReader.h
@@ -18,7 +18,7 @@
#include "controllers/RecordSetReader.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "pugixml.hpp"
diff --git a/extensions/standard-processors/controllers/XMLRecordSetWriter.cpp b/extensions/standard-processors/controllers/XMLRecordSetWriter.cpp
index 8241f5ab3..b98cbb67b 100644
--- a/extensions/standard-processors/controllers/XMLRecordSetWriter.cpp
+++ b/extensions/standard-processors/controllers/XMLRecordSetWriter.cpp
@@ -17,7 +17,7 @@
#include "XMLRecordSetWriter.h"
#include "core/Resource.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "utils/TimeUtil.h"
#include "utils/ParsingUtils.h"
#include "utils/GeneralUtils.h"
diff --git a/extensions/standard-processors/controllers/XMLRecordSetWriter.h b/extensions/standard-processors/controllers/XMLRecordSetWriter.h
index e9d27b995..6b1456113 100644
--- a/extensions/standard-processors/controllers/XMLRecordSetWriter.h
+++ b/extensions/standard-processors/controllers/XMLRecordSetWriter.h
@@ -18,7 +18,7 @@
#include "controllers/RecordSetWriter.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
#include "pugixml.hpp"
diff --git a/extensions/standard-processors/modbus/FetchModbusTcp.cpp b/extensions/standard-processors/modbus/FetchModbusTcp.cpp
index e6667ab49..1969d7ea0 100644
--- a/extensions/standard-processors/modbus/FetchModbusTcp.cpp
+++ b/extensions/standard-processors/modbus/FetchModbusTcp.cpp
@@ -17,7 +17,7 @@
#include "FetchModbusTcp.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "io/validation.h"
diff --git a/extensions/standard-processors/modbus/FetchModbusTcp.h b/extensions/standard-processors/modbus/FetchModbusTcp.h
index e7ce18ef6..68fe9cffd 100644
--- a/extensions/standard-processors/modbus/FetchModbusTcp.h
+++ b/extensions/standard-processors/modbus/FetchModbusTcp.h
@@ -16,8 +16,8 @@
*/
#pragma once
-#include "controllers/RecordSetWriter.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/RecordSetWriter.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/ProcessorImpl.h"
#include "core/PropertyDefinitionBuilder.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extensions/standard-processors/processors/AppendHostInfo.cpp b/extensions/standard-processors/processors/AppendHostInfo.cpp
index 652cab0cc..501fcac0a 100644
--- a/extensions/standard-processors/processors/AppendHostInfo.cpp
+++ b/extensions/standard-processors/processors/AppendHostInfo.cpp
@@ -27,9 +27,9 @@
#include <string>
#include <regex>
#include <algorithm>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/Resource.h"
#include "utils/net/NetworkInterfaceInfo.h"
#include "utils/net/DNS.h"
diff --git a/extensions/standard-processors/processors/AppendHostInfo.h b/extensions/standard-processors/processors/AppendHostInfo.h
index f55d6e839..ed1cedfb0 100644
--- a/extensions/standard-processors/processors/AppendHostInfo.h
+++ b/extensions/standard-processors/processors/AppendHostInfo.h
@@ -26,14 +26,14 @@
#include <string>
#include <utility>
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/PropertyDefinitionBuilder.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/AttributeRollingWindow.cpp b/extensions/standard-processors/processors/AttributeRollingWindow.cpp
index e3108d32c..1eecb36c2 100644
--- a/extensions/standard-processors/processors/AttributeRollingWindow.cpp
+++ b/extensions/standard-processors/processors/AttributeRollingWindow.cpp
@@ -18,7 +18,7 @@
#include <algorithm>
#include <numeric>
#include "fmt/format.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/expected.h"
diff --git a/extensions/standard-processors/processors/AttributeRollingWindow.h b/extensions/standard-processors/processors/AttributeRollingWindow.h
index 4f89cb665..6743bc68a 100644
--- a/extensions/standard-processors/processors/AttributeRollingWindow.h
+++ b/extensions/standard-processors/processors/AttributeRollingWindow.h
@@ -24,13 +24,12 @@
#include <string_view>
#include "core/AbstractProcessor.h"
-#include "core/Annotation.h"
+#include "minifi-cpp/core/Annotation.h"
#include "core/logging/LoggerFactory.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "RollingWindow.h"
-#include "core/StateManager.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/AttributesToJSON.cpp b/extensions/standard-processors/processors/AttributesToJSON.cpp
index db91ee6a7..866c3b1df 100644
--- a/extensions/standard-processors/processors/AttributesToJSON.cpp
+++ b/extensions/standard-processors/processors/AttributesToJSON.cpp
@@ -26,7 +26,7 @@
#include "utils/ProcessorConfigUtils.h"
#include "range/v3/algorithm/find.hpp"
#include "core/ProcessSession.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Resource.h"
namespace org::apache::nifi::minifi::processors {
@@ -38,11 +38,11 @@ void AttributesToJSON::initialize() {
void AttributesToJSON::onSchedule(core::ProcessContext& context, core::ProcessSessionFactory&) {
attribute_list_ = context.getProperty(AttributesList)
- | utils::transform([](const auto attributes_list_str) { return utils::string::splitAndTrimRemovingEmpty(attributes_list_str, ","); })
+ | utils::transform([](const auto& attributes_list_str) { return utils::string::splitAndTrimRemovingEmpty(attributes_list_str, ","); })
| utils::valueOrElse([] { return std::vector<std::string>{}; });
attributes_regular_expression_ = context.getProperty(AttributesRegularExpression)
- | utils::transform([](const auto s) { return utils::Regex{s}; })
+ | utils::transform([](auto s) { return utils::Regex{std::move(s)}; })
| utils::toOptional();
write_destination_ = utils::parseEnumProperty<attributes_to_json::WriteDestination>(context, Destination);
diff --git a/extensions/standard-processors/processors/AttributesToJSON.h b/extensions/standard-processors/processors/AttributesToJSON.h
index 4e8fbeab6..aadcf1d3b 100644
--- a/extensions/standard-processors/processors/AttributesToJSON.h
+++ b/extensions/standard-processors/processors/AttributesToJSON.h
@@ -28,16 +28,16 @@
#include <vector>
#include "rapidjson/document.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/logging/LoggerFactory.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "io/StreamPipe.h"
#include "utils/Enum.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/RegexUtils.h"
namespace org::apache::nifi::minifi::processors::attributes_to_json {
diff --git a/extensions/standard-processors/processors/ConvertRecord.h b/extensions/standard-processors/processors/ConvertRecord.h
index 7247c3ed3..daf1ffe27 100644
--- a/extensions/standard-processors/processors/ConvertRecord.h
+++ b/extensions/standard-processors/processors/ConvertRecord.h
@@ -23,7 +23,7 @@
#include "core/AbstractProcessor.h"
#include "core/ProcessSession.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "controllers/RecordSetReader.h"
#include "controllers/RecordSetWriter.h"
diff --git a/extensions/standard-processors/processors/DefragmentText.cpp b/extensions/standard-processors/processors/DefragmentText.cpp
index e5c85dc77..6b051682b 100644
--- a/extensions/standard-processors/processors/DefragmentText.cpp
+++ b/extensions/standard-processors/processors/DefragmentText.cpp
@@ -20,12 +20,12 @@
#include <vector>
#include <utility>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "serialization/PayloadSerializer.h"
#include "TextFragmentUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/StringUtils.h"
#include "utils/ProcessorConfigUtils.h"
@@ -52,7 +52,7 @@ void DefragmentText::onSchedule(core::ProcessContext& context, core::ProcessSess
pattern_location_ = utils::parseEnumProperty<defragment_text::PatternLocation>(context, PatternLoc);
pattern_ = context.getProperty(Pattern)
- | utils::transform([](const auto pattern_str) { return utils::Regex{pattern_str}; })
+ | utils::transform([](auto pattern_str) { return utils::Regex{std::move(pattern_str)}; })
| utils::orThrow("Pattern property missing or invalid");
}
diff --git a/extensions/standard-processors/processors/DefragmentText.h b/extensions/standard-processors/processors/DefragmentText.h
index 300224970..5d1ccbcca 100644
--- a/extensions/standard-processors/processors/DefragmentText.h
+++ b/extensions/standard-processors/processors/DefragmentText.h
@@ -25,9 +25,9 @@
#include "core/ProcessorImpl.h"
#include "core/FlowFileStore.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "utils/Enum.h"
#include "serialization/PayloadSerializer.h"
diff --git a/extensions/standard-processors/processors/EvaluateJsonPath.h b/extensions/standard-processors/processors/EvaluateJsonPath.h
index ddf312cc3..681a4b3b6 100644
--- a/extensions/standard-processors/processors/EvaluateJsonPath.h
+++ b/extensions/standard-processors/processors/EvaluateJsonPath.h
@@ -20,12 +20,10 @@
#include <string_view>
#include <array>
-#include "core/logging/LoggerFactory.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "jsoncons/json.hpp"
diff --git a/extensions/standard-processors/processors/ExtractText.cpp b/extensions/standard-processors/processors/ExtractText.cpp
index 238860d6c..0cba55b81 100644
--- a/extensions/standard-processors/processors/ExtractText.cpp
+++ b/extensions/standard-processors/processors/ExtractText.cpp
@@ -26,13 +26,13 @@
#include <string>
#include <utility>
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ConfigurationUtils.h"
#include "utils/RegexUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ProcessorConfigUtils.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/ExtractText.h b/extensions/standard-processors/processors/ExtractText.h
index 2c878502f..fdf17e5e1 100644
--- a/extensions/standard-processors/processors/ExtractText.h
+++ b/extensions/standard-processors/processors/ExtractText.h
@@ -27,12 +27,12 @@
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "utils/Export.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/FetchFile.h b/extensions/standard-processors/processors/FetchFile.h
index 7ec2e495e..d46acad11 100644
--- a/extensions/standard-processors/processors/FetchFile.h
+++ b/extensions/standard-processors/processors/FetchFile.h
@@ -22,9 +22,9 @@
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/Enum.h"
#include "core/logging/LoggerFactory.h"
#include "utils/LogUtils.h"
diff --git a/extensions/standard-processors/processors/GenerateFlowFile.cpp b/extensions/standard-processors/processors/GenerateFlowFile.cpp
index 7ff2ee3ac..1b68aac0d 100644
--- a/extensions/standard-processors/processors/GenerateFlowFile.cpp
+++ b/extensions/standard-processors/processors/GenerateFlowFile.cpp
@@ -30,7 +30,7 @@
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/OptionalUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ProcessorConfigUtils.h"
#include "minifi-cpp/core/ProcessorDescriptor.h"
diff --git a/extensions/standard-processors/processors/GenerateFlowFile.h b/extensions/standard-processors/processors/GenerateFlowFile.h
index 83b6d299c..07804fd9f 100644
--- a/extensions/standard-processors/processors/GenerateFlowFile.h
+++ b/extensions/standard-processors/processors/GenerateFlowFile.h
@@ -26,14 +26,14 @@
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/ProcessContext.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
-#include "utils/gsl.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/GetFile.cpp b/extensions/standard-processors/processors/GetFile.cpp
index 53a8d4d6f..f325b4cc3 100644
--- a/extensions/standard-processors/processors/GetFile.cpp
+++ b/extensions/standard-processors/processors/GetFile.cpp
@@ -23,7 +23,7 @@
#include <string>
#include "ListFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "core/TypedValues.h"
diff --git a/extensions/standard-processors/processors/GetFile.h b/extensions/standard-processors/processors/GetFile.h
index d255ba39f..f58518c03 100644
--- a/extensions/standard-processors/processors/GetFile.h
+++ b/extensions/standard-processors/processors/GetFile.h
@@ -25,15 +25,15 @@
#include <utility>
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "core/ProcessorMetrics.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/GetTCP.cpp b/extensions/standard-processors/processors/GetTCP.cpp
index 221573572..5e1ef25ec 100644
--- a/extensions/standard-processors/processors/GetTCP.cpp
+++ b/extensions/standard-processors/processors/GetTCP.cpp
@@ -24,11 +24,11 @@
#include "asio/detached.hpp"
#include "asio/read_until.hpp"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/StringUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/net/AsioCoro.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/standard-processors/processors/GetTCP.h b/extensions/standard-processors/processors/GetTCP.h
index 65cf67f02..4d91b9cd3 100644
--- a/extensions/standard-processors/processors/GetTCP.h
+++ b/extensions/standard-processors/processors/GetTCP.h
@@ -24,21 +24,21 @@
#include <vector>
#include <atomic>
#include <asio/io_context.hpp>
-#include "utils/Literals.h"
+#include "minifi-cpp/utils/Literals.h"
#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "core/Core.h"
#include "concurrentqueue.h"
#include "utils/ThreadPool.h"
#include "core/logging/LoggerFactory.h"
-#include "controllers/SSLContextServiceInterface.h"
-#include "utils/gsl.h"
-#include "utils/Export.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/net/AsioSocketUtils.h"
#include "utils/net/Message.h"
diff --git a/extensions/standard-processors/processors/HashContent.cpp b/extensions/standard-processors/processors/HashContent.cpp
index b7d199d78..f48afc0b3 100644
--- a/extensions/standard-processors/processors/HashContent.cpp
+++ b/extensions/standard-processors/processors/HashContent.cpp
@@ -24,9 +24,9 @@
#include <utility>
#include "HashContent.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/Resource.h"
#include "range/v3/view.hpp"
diff --git a/extensions/standard-processors/processors/HashContent.h b/extensions/standard-processors/processors/HashContent.h
index fadb2af09..3b32d1b52 100644
--- a/extensions/standard-processors/processors/HashContent.h
+++ b/extensions/standard-processors/processors/HashContent.h
@@ -33,12 +33,12 @@
#include <utility>
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/ProcessSession.h"
#include "utils/StringUtils.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
using HashReturnType = std::pair<std::string, int64_t>;
diff --git a/extensions/standard-processors/processors/InvokeHTTP.cpp b/extensions/standard-processors/processors/InvokeHTTP.cpp
index 1e037730d..e652a00c6 100644
--- a/extensions/standard-processors/processors/InvokeHTTP.cpp
+++ b/extensions/standard-processors/processors/InvokeHTTP.cpp
@@ -25,15 +25,15 @@
#include <utility>
#include <vector>
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Resource.h"
#include "io/BufferStream.h"
#include "range/v3/algorithm/any_of.hpp"
#include "range/v3/view/filter.hpp"
#include "utils/OptionalUtils.h"
#include "utils/ProcessorConfigUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
using namespace std::literals::chrono_literals;
diff --git a/extensions/standard-processors/processors/InvokeHTTP.h b/extensions/standard-processors/processors/InvokeHTTP.h
index cec9a2fd3..12162c023 100644
--- a/extensions/standard-processors/processors/InvokeHTTP.h
+++ b/extensions/standard-processors/processors/InvokeHTTP.h
@@ -27,19 +27,19 @@
#include <list>
#include "core/Core.h"
-#include "core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/logging/LoggerFactory.h"
#include "utils/Id.h"
#include "utils/ResourceQueue.h"
#include "http/HTTPClient.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/Enum.h"
#include "utils/RegexUtils.h"
diff --git a/extensions/standard-processors/processors/JoltTransformJSON.h b/extensions/standard-processors/processors/JoltTransformJSON.h
index a21bc0df9..13ea3eef1 100644
--- a/extensions/standard-processors/processors/JoltTransformJSON.h
+++ b/extensions/standard-processors/processors/JoltTransformJSON.h
@@ -20,9 +20,9 @@
#include <string>
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "utils/Enum.h"
#include "utils/Searcher.h"
diff --git a/extensions/standard-processors/processors/ListFile.cpp b/extensions/standard-processors/processors/ListFile.cpp
index 66618ad33..77616a156 100644
--- a/extensions/standard-processors/processors/ListFile.cpp
+++ b/extensions/standard-processors/processors/ListFile.cpp
@@ -19,7 +19,7 @@
#include <filesystem>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
#include "utils/StringUtils.h"
diff --git a/extensions/standard-processors/processors/ListFile.h b/extensions/standard-processors/processors/ListFile.h
index 929d55e05..34d5bffb4 100644
--- a/extensions/standard-processors/processors/ListFile.h
+++ b/extensions/standard-processors/processors/ListFile.h
@@ -22,11 +22,11 @@
#include <string>
#include <utility>
-#include "core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extensions/standard-processors/processors/ListenSyslog.cpp b/extensions/standard-processors/processors/ListenSyslog.cpp
index 3742329fe..83aeae98d 100644
--- a/extensions/standard-processors/processors/ListenSyslog.cpp
+++ b/extensions/standard-processors/processors/ListenSyslog.cpp
@@ -17,8 +17,8 @@
#include "ListenSyslog.h"
-#include "controllers/SSLContextServiceInterface.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/standard-processors/processors/ListenSyslog.h b/extensions/standard-processors/processors/ListenSyslog.h
index 5fb06dba2..caf8236a8 100644
--- a/extensions/standard-processors/processors/ListenSyslog.h
+++ b/extensions/standard-processors/processors/ListenSyslog.h
@@ -23,14 +23,14 @@
#include <memory>
#include <regex>
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "NetworkListenerProcessor.h"
#include "core/logging/LoggerFactory.h"
-#include "core/OutputAttributeDefinition.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/net/Ssl.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/ListenTCP.cpp b/extensions/standard-processors/processors/ListenTCP.cpp
index 2aefc6320..cc5d2beef 100644
--- a/extensions/standard-processors/processors/ListenTCP.cpp
+++ b/extensions/standard-processors/processors/ListenTCP.cpp
@@ -16,8 +16,8 @@
*/
#include "ListenTCP.h"
-#include "controllers/SSLContextServiceInterface.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/standard-processors/processors/ListenTCP.h b/extensions/standard-processors/processors/ListenTCP.h
index d57058e1b..25efd3fa6 100644
--- a/extensions/standard-processors/processors/ListenTCP.h
+++ b/extensions/standard-processors/processors/ListenTCP.h
@@ -21,12 +21,12 @@
#include <utility>
#include "NetworkListenerProcessor.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/Core.h"
-#include "core/OutputAttributeDefinition.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/logging/LoggerFactory.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "utils/Enum.h"
diff --git a/extensions/standard-processors/processors/ListenUDP.cpp b/extensions/standard-processors/processors/ListenUDP.cpp
index d6f81cd63..d917ddf0d 100644
--- a/extensions/standard-processors/processors/ListenUDP.cpp
+++ b/extensions/standard-processors/processors/ListenUDP.cpp
@@ -16,7 +16,7 @@
*/
#include "ListenUDP.h"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/standard-processors/processors/ListenUDP.h b/extensions/standard-processors/processors/ListenUDP.h
index a5b075e31..b6a706ec9 100644
--- a/extensions/standard-processors/processors/ListenUDP.h
+++ b/extensions/standard-processors/processors/ListenUDP.h
@@ -20,12 +20,12 @@
#include <string>
#include "NetworkListenerProcessor.h"
-#include "core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/LogAttribute.cpp b/extensions/standard-processors/processors/LogAttribute.cpp
index 7cfe0db3d..66cd7c040 100644
--- a/extensions/standard-processors/processors/LogAttribute.cpp
+++ b/extensions/standard-processors/processors/LogAttribute.cpp
@@ -27,7 +27,7 @@
#include <sstream>
#include <iostream>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/TimeUtil.h"
diff --git a/extensions/standard-processors/processors/LogAttribute.h b/extensions/standard-processors/processors/LogAttribute.h
index 55bc6c938..169de29ad 100644
--- a/extensions/standard-processors/processors/LogAttribute.h
+++ b/extensions/standard-processors/processors/LogAttribute.h
@@ -26,14 +26,14 @@
#include "core/Core.h"
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/NetworkListenerProcessor.h b/extensions/standard-processors/processors/NetworkListenerProcessor.h
index 624dfa591..fc9d4d7eb 100644
--- a/extensions/standard-processors/processors/NetworkListenerProcessor.h
+++ b/extensions/standard-processors/processors/NetworkListenerProcessor.h
@@ -21,10 +21,10 @@
#include <utility>
#include "core/ProcessorImpl.h"
-#include "core/logging/Logger.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "utils/net/Server.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/PutFile.cpp b/extensions/standard-processors/processors/PutFile.cpp
index d7a518ddb..2bd822399 100644
--- a/extensions/standard-processors/processors/PutFile.cpp
+++ b/extensions/standard-processors/processors/PutFile.cpp
@@ -29,9 +29,9 @@
#include "utils/file/FileUtils.h"
#include "utils/file/FileWriterCallback.h"
#include "utils/ProcessorConfigUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/Resource.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
namespace org::apache::nifi::minifi::processors {
@@ -82,7 +82,8 @@ void PutFile::onTrigger(core::ProcessContext& context, core::ProcessSession& ses
auto dest_path = getDestinationPath(context, flow_file);
if (!dest_path) {
- return session.transfer(flow_file, Failure);
+ session.transfer(flow_file, Failure);
+ return;
}
logger_->log_trace("PutFile writing file {} into directory {}", dest_path->filename(), dest_path->parent_path());
@@ -90,15 +91,18 @@ void PutFile::onTrigger(core::ProcessContext& context, core::ProcessSession& ses
if (directoryIsFull(dest_path->parent_path())) {
logger_->log_warn("Routing to failure because the output directory {} has at least {} files, which exceeds the "
"configured max number of files", dest_path->parent_path(), *max_dest_files_);
- return session.transfer(flow_file, Failure);
+ session.transfer(flow_file, Failure);
+ return;
}
if (utils::file::exists(*dest_path)) {
logger_->log_info("Destination file {} exists; applying Conflict Resolution Strategy: {}", dest_path->string(), magic_enum::enum_name(conflict_resolution_strategy_));
if (conflict_resolution_strategy_ == FileExistsResolutionStrategy::fail) {
- return session.transfer(flow_file, Failure);
+ session.transfer(flow_file, Failure);
+ return;
} else if (conflict_resolution_strategy_ == FileExistsResolutionStrategy::ignore) {
- return session.transfer(flow_file, Success);
+ session.transfer(flow_file, Success);
+ return;
}
}
diff --git a/extensions/standard-processors/processors/PutFile.h b/extensions/standard-processors/processors/PutFile.h
index 9b2de8570..186e64720 100644
--- a/extensions/standard-processors/processors/PutFile.h
+++ b/extensions/standard-processors/processors/PutFile.h
@@ -21,16 +21,16 @@
#include <utility>
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
#include "utils/Id.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/Enum.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/PutTCP.cpp b/extensions/standard-processors/processors/PutTCP.cpp
index a6c55b0d7..941c3f62f 100644
--- a/extensions/standard-processors/processors/PutTCP.cpp
+++ b/extensions/standard-processors/processors/PutTCP.cpp
@@ -20,12 +20,12 @@
#include <tuple>
#include <utility>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "range/v3/range/conversion.hpp"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/net/AsioCoro.h"
#include "utils/net/AsioSocketUtils.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/standard-processors/processors/PutTCP.h b/extensions/standard-processors/processors/PutTCP.h
index 69768bb72..c3b146906 100644
--- a/extensions/standard-processors/processors/PutTCP.h
+++ b/extensions/standard-processors/processors/PutTCP.h
@@ -25,16 +25,16 @@
#include <utility>
#include <vector>
-#include "io/InputStream.h"
+#include "minifi-cpp/io/InputStream.h"
#include "core/ProcessorImpl.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "asio/io_context.hpp"
#include "asio/ssl/context.hpp"
-#include "controllers/SSLContextServiceInterface.h"
+#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/Core.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "utils/StringUtils.h" // for string <=> on libc++
#include "utils/net/AsioSocketUtils.h"
diff --git a/extensions/standard-processors/processors/PutUDP.cpp b/extensions/standard-processors/processors/PutUDP.cpp
index f06c112c0..aa4b1eb63 100644
--- a/extensions/standard-processors/processors/PutUDP.cpp
+++ b/extensions/standard-processors/processors/PutUDP.cpp
@@ -18,9 +18,9 @@
#include "range/v3/range/conversion.hpp"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/expected.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "core/logging/LoggerFactory.h"
@@ -90,7 +90,7 @@ void PutUDP::onTrigger(core::ProcessContext& context, core::ProcessSession& sess
for (const auto& resolver_entry : resolved_query) {
error.clear();
udp::socket socket(io_context);
- socket.open(resolver_entry.endpoint().protocol(), error);
+ std::ignore = socket.open(resolver_entry.endpoint().protocol(), error);
if (error) {
logger->log_debug("opening {} socket failed due to {} ", resolver_entry.endpoint().protocol() == udp::v4() ? "IPv4" : "IPv6", error.message());
continue;
diff --git a/extensions/standard-processors/processors/PutUDP.h b/extensions/standard-processors/processors/PutUDP.h
index b8fbbd584..94abccf4d 100644
--- a/extensions/standard-processors/processors/PutUDP.h
+++ b/extensions/standard-processors/processors/PutUDP.h
@@ -22,10 +22,10 @@
#include <vector>
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
-#include "utils/Export.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::core::logging { class Logger; }
diff --git a/extensions/standard-processors/processors/ReplaceText.h b/extensions/standard-processors/processors/ReplaceText.h
index 2d3dde34f..40b2676e4 100644
--- a/extensions/standard-processors/processors/ReplaceText.h
+++ b/extensions/standard-processors/processors/ReplaceText.h
@@ -21,16 +21,16 @@
#include <string>
#include <utility>
-#include "core/Annotation.h"
+#include "minifi-cpp/core/Annotation.h"
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "utils/Enum.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/RetryFlowFile.h b/extensions/standard-processors/processors/RetryFlowFile.h
index 197ecbb13..b144af28c 100644
--- a/extensions/standard-processors/processors/RetryFlowFile.h
+++ b/extensions/standard-processors/processors/RetryFlowFile.h
@@ -26,17 +26,17 @@
#include <vector>
#include "core/Core.h"
-#include "core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/logging/LoggerFactory.h"
#include "utils/OptionalUtils.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/RouteOnAttribute.h b/extensions/standard-processors/processors/RouteOnAttribute.h
index 92fd057f8..b916b23c5 100644
--- a/extensions/standard-processors/processors/RouteOnAttribute.h
+++ b/extensions/standard-processors/processors/RouteOnAttribute.h
@@ -25,9 +25,9 @@
#include <utility>
#include "core/ProcessorImpl.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extensions/standard-processors/processors/RouteText.cpp b/extensions/standard-processors/processors/RouteText.cpp
index 5d005f6fb..fee76d588 100644
--- a/extensions/standard-processors/processors/RouteText.cpp
+++ b/extensions/standard-processors/processors/RouteText.cpp
@@ -22,7 +22,7 @@
#include <utility>
#include <vector>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extensions/standard-processors/processors/RouteText.h b/extensions/standard-processors/processors/RouteText.h
index d176f7a2c..688cbda55 100644
--- a/extensions/standard-processors/processors/RouteText.h
+++ b/extensions/standard-processors/processors/RouteText.h
@@ -23,14 +23,14 @@
#include <string>
#include <memory>
-#include "core/OutputAttributeDefinition.h"
+#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "utils/Enum.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/RegexUtils.h"
namespace org::apache::nifi::minifi::processors::route_text {
diff --git a/extensions/standard-processors/processors/SegmentContent.cpp b/extensions/standard-processors/processors/SegmentContent.cpp
index 8cc2421bc..74e071779 100644
--- a/extensions/standard-processors/processors/SegmentContent.cpp
+++ b/extensions/standard-processors/processors/SegmentContent.cpp
@@ -18,8 +18,8 @@
#include "SegmentContent.h"
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ConfigurationUtils.h"
diff --git a/extensions/standard-processors/processors/SegmentContent.h b/extensions/standard-processors/processors/SegmentContent.h
index 203deb2b3..fcc20decd 100644
--- a/extensions/standard-processors/processors/SegmentContent.h
+++ b/extensions/standard-processors/processors/SegmentContent.h
@@ -22,13 +22,13 @@
#include <string_view>
#include <utility>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessSession.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
-#include "utils/Export.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/SplitContent.cpp b/extensions/standard-processors/processors/SplitContent.cpp
index ac1dd5d79..b9d3f9713 100644
--- a/extensions/standard-processors/processors/SplitContent.cpp
+++ b/extensions/standard-processors/processors/SplitContent.cpp
@@ -20,13 +20,13 @@
#include <range/v3/view/split.hpp>
-#include "core/FlowFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ConfigurationUtils.h"
#include "utils/ProcessorConfigUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::processors {
void SplitContent::initialize() {
diff --git a/extensions/standard-processors/processors/SplitContent.h b/extensions/standard-processors/processors/SplitContent.h
index 8c26e7b7d..fa05c3d9a 100644
--- a/extensions/standard-processors/processors/SplitContent.h
+++ b/extensions/standard-processors/processors/SplitContent.h
@@ -21,14 +21,14 @@
#include <optional>
#include <string_view>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessSession.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "utils/Export.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/SplitJson.h b/extensions/standard-processors/processors/SplitJson.h
index ff386c187..289ef16a6 100644
--- a/extensions/standard-processors/processors/SplitJson.h
+++ b/extensions/standard-processors/processors/SplitJson.h
@@ -21,12 +21,10 @@
#include <array>
#include <optional>
-#include "core/logging/LoggerFactory.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "jsoncons/json.hpp"
diff --git a/extensions/standard-processors/processors/SplitRecord.h b/extensions/standard-processors/processors/SplitRecord.h
index 510a8f44c..5057d7e1c 100644
--- a/extensions/standard-processors/processors/SplitRecord.h
+++ b/extensions/standard-processors/processors/SplitRecord.h
@@ -16,16 +16,16 @@
*/
#pragma once
-#include "core/Annotation.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/Annotation.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "minifi-cpp/core/ProcessSessionFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
-#include "core/logging/Logger.h"
-#include "controllers/RecordSetReader.h"
-#include "controllers/RecordSetWriter.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/controllers/RecordSetReader.h"
+#include "minifi-cpp/controllers/RecordSetWriter.h"
#include "core/AbstractProcessor.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/SplitText.cpp b/extensions/standard-processors/processors/SplitText.cpp
index 9a9823c5d..60dc02442 100644
--- a/extensions/standard-processors/processors/SplitText.cpp
+++ b/extensions/standard-processors/processors/SplitText.cpp
@@ -20,12 +20,12 @@
#include <algorithm>
#include "SplitText.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "utils/ConfigurationUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ProcessorConfigUtils.h"
#include "io/StreamPipe.h"
@@ -401,7 +401,7 @@ void SplitText::onSchedule(core::ProcessContext& context, core::ProcessSessionFa
split_text_config_.line_split_count = utils::parseU64Property(context, LineSplitCount);
logger_->log_debug("SplitText line split count: {}", split_text_config_.line_split_count);
if (const auto max_fragment_data_size_value = utils::parseOptionalDataSizeProperty(context, MaximumFragmentSize)) {
- split_text_config_.maximum_fragment_size = *max_fragment_data_size_value;
+ split_text_config_.maximum_fragment_size = max_fragment_data_size_value;
logger_->log_debug("SplitText maximum fragment size: {}", split_text_config_.maximum_fragment_size.value());
}
if (split_text_config_.maximum_fragment_size && split_text_config_.maximum_fragment_size.value() == 0) {
diff --git a/extensions/standard-processors/processors/SplitText.h b/extensions/standard-processors/processors/SplitText.h
index 1be15c901..7915fd637 100644
--- a/extensions/standard-processors/processors/SplitText.h
+++ b/extensions/standard-processors/processors/SplitText.h
@@ -27,10 +27,10 @@
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "utils/Export.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/expected.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/TailFile.cpp b/extensions/standard-processors/processors/TailFile.cpp
index f5ae3c837..d2ca3e7f0 100644
--- a/extensions/standard-processors/processors/TailFile.cpp
+++ b/extensions/standard-processors/processors/TailFile.cpp
@@ -37,7 +37,7 @@
#include "utils/ProcessorConfigUtils.h"
#include "TextFragmentUtils.h"
#include "TailFile.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/RegexUtils.h"
diff --git a/extensions/standard-processors/processors/TailFile.h b/extensions/standard-processors/processors/TailFile.h
index 006404428..69c388e18 100644
--- a/extensions/standard-processors/processors/TailFile.h
+++ b/extensions/standard-processors/processors/TailFile.h
@@ -27,17 +27,17 @@
#include <vector>
#include <optional>
-#include "controllers/AttributeProviderService.h"
+#include "minifi-cpp/controllers/AttributeProviderService.h"
#include "core/Core.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/logging/LoggerFactory.h"
#include "utils/Enum.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/RegexUtils.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/TextFragmentUtils.h b/extensions/standard-processors/processors/TextFragmentUtils.h
index ed024b24c..7e647b016 100644
--- a/extensions/standard-processors/processors/TextFragmentUtils.h
+++ b/extensions/standard-processors/processors/TextFragmentUtils.h
@@ -18,7 +18,7 @@
#pragma once
#include <string>
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::processors::textfragmentutils {
constexpr const char* BASE_NAME_ATTRIBUTE = "TextFragmentAttribute.base_name";
diff --git a/extensions/standard-processors/processors/UpdateAttribute.cpp b/extensions/standard-processors/processors/UpdateAttribute.cpp
index 1076bad24..12ae58a5a 100644
--- a/extensions/standard-processors/processors/UpdateAttribute.cpp
+++ b/extensions/standard-processors/processors/UpdateAttribute.cpp
@@ -25,7 +25,7 @@
#include "core/PropertyDefinitionBuilder.h"
#include "core/Resource.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/processors/UpdateAttribute.h b/extensions/standard-processors/processors/UpdateAttribute.h
index df885ef35..eaba6f069 100644
--- a/extensions/standard-processors/processors/UpdateAttribute.h
+++ b/extensions/standard-processors/processors/UpdateAttribute.h
@@ -26,8 +26,8 @@
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
diff --git a/extensions/standard-processors/tests/integration/InvokeHTTPTests.cpp b/extensions/standard-processors/tests/integration/InvokeHTTPTests.cpp
index 29e03ed83..d4e94b62f 100644
--- a/extensions/standard-processors/tests/integration/InvokeHTTPTests.cpp
+++ b/extensions/standard-processors/tests/integration/InvokeHTTPTests.cpp
@@ -24,10 +24,10 @@
#include "core/Core.h"
#include "http/HTTPClient.h"
#include "InvokeHTTP.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "unit/ProvenanceTestHelper.h"
#include "core/Processor.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "processors/LogAttribute.h"
#include "unit/SingleProcessorTestController.h"
diff --git a/extensions/standard-processors/tests/integration/ProcessGroupTest.cpp b/extensions/standard-processors/tests/integration/ProcessGroupTest.cpp
index f647c47c9..e642399b9 100644
--- a/extensions/standard-processors/tests/integration/ProcessGroupTest.cpp
+++ b/extensions/standard-processors/tests/integration/ProcessGroupTest.cpp
@@ -17,7 +17,7 @@
*/
#include <string>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "FlowController.h"
#include "unit/TestBase.h"
#include "processors/GenerateFlowFile.h"
diff --git a/extensions/standard-processors/tests/integration/VerifyInvokeHTTP.h b/extensions/standard-processors/tests/integration/VerifyInvokeHTTP.h
index 8b6a428b3..0f6c74a03 100644
--- a/extensions/standard-processors/tests/integration/VerifyInvokeHTTP.h
+++ b/extensions/standard-processors/tests/integration/VerifyInvokeHTTP.h
@@ -28,7 +28,7 @@
#include "processors/LogAttribute.h"
#include "controllers/SSLContextService.h"
#include "core/state/ProcessorController.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "integration/HTTPIntegrationBase.h"
#include "unit/Catch.h"
#include "unit/ProvenanceTestHelper.h"
diff --git a/extensions/standard-processors/tests/unit/AttributeRollingWindowTests.cpp b/extensions/standard-processors/tests/unit/AttributeRollingWindowTests.cpp
index ba3680c4b..13fb7f93b 100644
--- a/extensions/standard-processors/tests/unit/AttributeRollingWindowTests.cpp
+++ b/extensions/standard-processors/tests/unit/AttributeRollingWindowTests.cpp
@@ -20,7 +20,7 @@
#include "unit/Catch.h"
#include "AttributeRollingWindow.h"
#include "unit/SingleProcessorTestController.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "unit/TestUtils.h"
namespace org::apache::nifi::minifi::test {
diff --git a/extensions/standard-processors/tests/unit/ControllerServiceTests.cpp b/extensions/standard-processors/tests/unit/ControllerServiceTests.cpp
index d1bb4cf7d..4b08faef5 100644
--- a/extensions/standard-processors/tests/unit/ControllerServiceTests.cpp
+++ b/extensions/standard-processors/tests/unit/ControllerServiceTests.cpp
@@ -24,8 +24,8 @@
#include "properties/Configure.h"
#include "GetFile.h"
#include "core/Core.h"
-#include "Exception.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "unit/MockClasses.h"
#include "unit/ProvenanceTestHelper.h"
#include "core/Processor.h"
diff --git a/extensions/standard-processors/tests/unit/ExtractTextTests.cpp b/extensions/standard-processors/tests/unit/ExtractTextTests.cpp
index 07c8eb099..b75fb51b3 100644
--- a/extensions/standard-processors/tests/unit/ExtractTextTests.cpp
+++ b/extensions/standard-processors/tests/unit/ExtractTextTests.cpp
@@ -30,9 +30,9 @@
#include "repository/VolatileContentRepository.h"
#include "unit/TestUtils.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/Processor.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "GetFile.h"
diff --git a/extensions/standard-processors/tests/unit/FetchFileTests.cpp b/extensions/standard-processors/tests/unit/FetchFileTests.cpp
index a8f1939a6..03e993319 100644
--- a/extensions/standard-processors/tests/unit/FetchFileTests.cpp
+++ b/extensions/standard-processors/tests/unit/FetchFileTests.cpp
@@ -23,7 +23,7 @@
#include "unit/TestBase.h"
#include "unit/Catch.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/Processor.h"
#include "processors/FetchFile.h"
#include "unit/TestUtils.h"
diff --git a/extensions/standard-processors/tests/unit/GetTCPTests.cpp b/extensions/standard-processors/tests/unit/GetTCPTests.cpp
index 5274b3f84..a071c9148 100644
--- a/extensions/standard-processors/tests/unit/GetTCPTests.cpp
+++ b/extensions/standard-processors/tests/unit/GetTCPTests.cpp
@@ -24,7 +24,7 @@
#include "utils/net/AsioSocketUtils.h"
#include "controllers/SSLContextService.h"
#include "range/v3/algorithm/contains.hpp"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
using GetTCP = org::apache::nifi::minifi::processors::GetTCP;
diff --git a/extensions/standard-processors/tests/unit/ListFileTests.cpp b/extensions/standard-processors/tests/unit/ListFileTests.cpp
index c27b13f1f..bb4f80b53 100644
--- a/extensions/standard-processors/tests/unit/ListFileTests.cpp
+++ b/extensions/standard-processors/tests/unit/ListFileTests.cpp
@@ -21,7 +21,7 @@
#include "unit/TestBase.h"
#include "unit/SingleProcessorTestController.h"
#include "unit/Catch.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/Processor.h"
#include "processors/LogAttribute.h"
#include "processors/ListFile.h"
diff --git a/extensions/standard-processors/tests/unit/ProcessorTests.cpp b/extensions/standard-processors/tests/unit/ProcessorTests.cpp
index 727af353b..70c8ea4e2 100644
--- a/extensions/standard-processors/tests/unit/ProcessorTests.cpp
+++ b/extensions/standard-processors/tests/unit/ProcessorTests.cpp
@@ -39,18 +39,20 @@
#include "unit/ProvenanceTestHelper.h"
#include "utils/file/FileUtils.h"
#include "core/Core.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/Processor.h"
#include "core/ProcessContext.h"
#include "core/ProcessSession.h"
+#include "core/ProcessSessionFactory.h"
#include "core/reporting/SiteToSiteProvenanceReportingTask.h"
#include "core/Resource.h"
-#include "utils/gsl.h"
-#include "utils/PropertyExceptions.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/utils/PropertyExceptions.h"
#include "unit/TestUtils.h"
#include "io/BufferStream.h"
#include "fmt/format.h"
#include "processors/TailFile.h"
+#include "Connection.h"
TEST_CASE("Test Creation of GetFile", "[getfileCreate]") {
TestController testController;
diff --git a/extensions/standard-processors/tests/unit/PutFileTests.cpp b/extensions/standard-processors/tests/unit/PutFileTests.cpp
index d257780a0..ea9b4d65b 100644
--- a/extensions/standard-processors/tests/unit/PutFileTests.cpp
+++ b/extensions/standard-processors/tests/unit/PutFileTests.cpp
@@ -31,10 +31,10 @@
#include "processors/PutFile.h"
#include "unit/ProvenanceTestHelper.h"
#include "core/Core.h"
-#include "core/FlowFile.h"
+#include "minifi-cpp/core/FlowFile.h"
#include "core/Processor.h"
#include "core/reporting/SiteToSiteProvenanceReportingTask.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
TEST_CASE("Test Creation of PutFile", "[getfileCreate]") {
TestController testController;
diff --git a/extensions/standard-processors/tests/unit/PutUDPTests.cpp b/extensions/standard-processors/tests/unit/PutUDPTests.cpp
index dca54600d..361252aa4 100644
--- a/extensions/standard-processors/tests/unit/PutUDPTests.cpp
+++ b/extensions/standard-processors/tests/unit/PutUDPTests.cpp
@@ -23,7 +23,7 @@
#include "unit/SingleProcessorTestController.h"
#include "unit/Catch.h"
#include "PutUDP.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "utils/net/UdpServer.h"
#include "utils/expected.h"
#include "utils/StringUtils.h"
diff --git a/extensions/standard-processors/tests/unit/ReplaceTextTests.cpp b/extensions/standard-processors/tests/unit/ReplaceTextTests.cpp
index 72d0a55b1..1aef75816 100644
--- a/extensions/standard-processors/tests/unit/ReplaceTextTests.cpp
+++ b/extensions/standard-processors/tests/unit/ReplaceTextTests.cpp
@@ -20,6 +20,7 @@
#include "ReplaceText.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
+#include "FlowFileRecord.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/standard-processors/tests/unit/RouteTextTests.cpp b/extensions/standard-processors/tests/unit/RouteTextTests.cpp
index 918898224..9b503fd30 100644
--- a/extensions/standard-processors/tests/unit/RouteTextTests.cpp
+++ b/extensions/standard-processors/tests/unit/RouteTextTests.cpp
@@ -21,6 +21,7 @@
#include "unit/Catch.h"
#include "processors/RouteText.h"
#include "unit/TestUtils.h"
+#include "Connection.h"
namespace processors = minifi::processors;
@@ -94,7 +95,7 @@ struct RouteTextController : public TestController {
}
verifyOutputRelationship(rel, files);
}
- if (patterns.find("original") == patterns.end()) {
+ if (!patterns.contains("original")) {
// expectations on "original" were implicit
verifyOutputRelationship("original", all);
}
diff --git a/extensions/standard-processors/tests/unit/SegmentContentTests.cpp b/extensions/standard-processors/tests/unit/SegmentContentTests.cpp
index 841085896..bb74db80d 100644
--- a/extensions/standard-processors/tests/unit/SegmentContentTests.cpp
+++ b/extensions/standard-processors/tests/unit/SegmentContentTests.cpp
@@ -18,7 +18,7 @@
#include <random>
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "catch2/generators/catch_generators.hpp"
#include "processors/SegmentContent.h"
#include "range/v3/algorithm/equal.hpp"
diff --git a/extensions/standard-processors/tests/unit/SplitContentTests.cpp b/extensions/standard-processors/tests/unit/SplitContentTests.cpp
index b5ed5ce42..57a13e5c7 100644
--- a/extensions/standard-processors/tests/unit/SplitContentTests.cpp
+++ b/extensions/standard-processors/tests/unit/SplitContentTests.cpp
@@ -16,7 +16,7 @@
* limitations under the License.
*/
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "catch2/generators/catch_generators.hpp"
#include "processors/SplitContent.h"
#include "unit/Catch.h"
diff --git a/extensions/standard-processors/tests/unit/SplitTextTests.cpp b/extensions/standard-processors/tests/unit/SplitTextTests.cpp
index 92a223249..53c437627 100644
--- a/extensions/standard-processors/tests/unit/SplitTextTests.cpp
+++ b/extensions/standard-processors/tests/unit/SplitTextTests.cpp
@@ -16,7 +16,7 @@
* limitations under the License.
*/
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "unit/TestBase.h"
#include "unit/Catch.h"
#include "processors/SplitText.h"
diff --git a/extensions/standard-processors/tests/unit/TailFileTests.cpp b/extensions/standard-processors/tests/unit/TailFileTests.cpp
index 941d962a2..6f4844575 100644
--- a/extensions/standard-processors/tests/unit/TailFileTests.cpp
+++ b/extensions/standard-processors/tests/unit/TailFileTests.cpp
@@ -30,7 +30,7 @@
#include "TextFragmentUtils.h"
#include "catch2/generators/catch_generators.hpp"
#include "core/Core.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Processor.h"
#include "core/Resource.h"
@@ -41,6 +41,7 @@
#include "unit/TestUtils.h"
#include "utils/StringUtils.h"
#include "utils/file/FileUtils.h"
+#include "controllers/AttributeProviderService.h"
using namespace std::literals::chrono_literals;
diff --git a/extensions/standard-processors/tests/unit/YamlConnectionParserTest.cpp b/extensions/standard-processors/tests/unit/YamlConnectionParserTest.cpp
index 73ab1f4e3..3884d8cc5 100644
--- a/extensions/standard-processors/tests/unit/YamlConnectionParserTest.cpp
+++ b/extensions/standard-processors/tests/unit/YamlConnectionParserTest.cpp
@@ -24,6 +24,7 @@
#include "unit/Catch.h"
#include "unit/TestUtils.h"
#include "core/yaml/YamlNode.h"
+#include "Connection.h"
using namespace std::literals::chrono_literals;
@@ -146,7 +147,6 @@ TEST_CASE("Connections components are parsed from yaml", "[YamlConfiguration]")
CHECK_THROWS(StructuredConnectionParser(connection_node, "test_node", parent_ptr, logger));
}
SECTION("With a configuration that lists keys but has no assigned values") {
- std::string serialized_yaml;
SECTION("Single relationship name left empty") {
YAML::Node yaml_node = YAML::Load(std::string {
"source name: \n"
diff --git a/extensions/standard-processors/utils/JoltUtils.cpp b/extensions/standard-processors/utils/JoltUtils.cpp
index b06a61210..bf9392527 100644
--- a/extensions/standard-processors/utils/JoltUtils.cpp
+++ b/extensions/standard-processors/utils/JoltUtils.cpp
@@ -17,7 +17,7 @@
#include "JoltUtils.h"
#include "rapidjson/error/en.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::utils::jolt {
@@ -284,7 +284,7 @@ std::optional<std::vector<std::string_view>> Spec::Regex::match(std::string_view
}
// first fragment is at the beginning of the string
- if (str.substr(0, fragments.front().size()) != fragments.front()) {
+ if (!str.starts_with(fragments.front())) {
return std::nullopt;
}
auto it = str.begin() + fragments.front().size();
@@ -833,9 +833,9 @@ void putValue(const Spec::Context& ctx, const Spec::Destination& dest, const rap
member_value = inner_member_value.value();
} else {
auto sub_path = toString(ctx, val_ref->second);
- ctx.log([&] (auto logger) {
+ ctx.log([&] (const auto& logger) {
logger->log_trace("Could not find member at @({},{} as {}) from {}", val_ref->first, sub_path.first, sub_path.second, ctx.path());
- }, [] (auto) {});
+ }, [] (const auto&) {});
// do not write anything and do not throw
return;
}
@@ -1009,9 +1009,9 @@ void Spec::Pattern::process(const Value& val, const Context& ctx, const rapidjso
}
bool Spec::Pattern::processMember(const Context& ctx, std::string_view name, const rapidjson::Value& member, rapidjson::Document& output) const {
- auto on_exit = ctx.log([&] (auto logger) {
+ auto on_exit = ctx.log([&] (const auto& logger) {
logger->log_trace("Processing member '{}' of {}", name, ctx.path());
- }, [&] (auto logger) {
+ }, [&] (const auto& logger) {
logger->log_trace("Finished processing member '{}' of {}", name, ctx.path());
});
if (auto it = literal_indices.find(std::string{name}); it != literal_indices.end()) {
@@ -1078,9 +1078,9 @@ void Spec::Pattern::processObject(const Context& ctx, const rapidjson::Value &in
}
void Spec::Pattern::process(const Context& ctx, const rapidjson::Value &input, rapidjson::Document &output) const {
- auto on_exit = ctx.log([&] (auto logger) {
+ auto on_exit = ctx.log([&] (const auto& logger) {
logger->log_trace("Processing node at {}", ctx.path());
- }, [&] (auto logger) {
+ }, [&] (const auto& logger) {
logger->log_trace("Finished processing node at {}", ctx.path());
});
for (auto& [val_ref, dest] : values) {
@@ -1096,16 +1096,17 @@ void Spec::Pattern::process(const Context& ctx, const rapidjson::Value &input, r
Context sub_ctx = ctx.extend(ctx.matches, ctx.node);
process(dest, sub_ctx, value.value(), output);
} else {
- ctx.log([&, path_ptr = &path] (auto logger) {
+ ctx.log([&, path_ptr = &path] (const auto& logger) {
auto path_str = toString(ctx, *path_ptr);
logger->log_trace("Failed to resolve value path {} (evaled as {}) at {} (triggered from {}): {}", path_str.first, path_str.second, target->path(), ctx.path(), value.error());
- }, [&] (auto) {});
+ }, [] (const auto&) {});
// pass, non-existent member is not an error
}
}
for (auto& [key, dest] : keys) {
auto key_str = ctx.find(key.first)->matches.at(key.second);
- putValue(ctx.extend({key_str}, nullptr), dest, rapidjson::Value{key_str.data(), gsl::narrow<rapidjson::SizeType>(key_str.size()), output.GetAllocator()}, output);
+ putValue(ctx.extend({key_str}, nullptr), dest,
+ rapidjson::Value{key_str.data(), gsl::narrow<rapidjson::SizeType>(key_str.size()), output.GetAllocator()}, output); // NOLINT(bugprone-suspicious-stringview-data-usage)
}
for (auto& [value, dest] : defaults) {
Context sub_ctx = ctx.extend({value}, nullptr);
diff --git a/extensions/standard-processors/utils/JoltUtils.h b/extensions/standard-processors/utils/JoltUtils.h
index 8395391ed..62bbaa50a 100644
--- a/extensions/standard-processors/utils/JoltUtils.h
+++ b/extensions/standard-processors/utils/JoltUtils.h
@@ -27,8 +27,8 @@
#include <compare>
#include <concepts>
-#include "core/logging/Logger.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/utils/gsl.h"
#include "rapidjson/document.h"
#include "utils/expected.h"
#include "utils/StringUtils.h"
diff --git a/extensions/systemd/ConsumeJournald.cpp b/extensions/systemd/ConsumeJournald.cpp
index 9bc804c97..8fbe4356a 100644
--- a/extensions/systemd/ConsumeJournald.cpp
+++ b/extensions/systemd/ConsumeJournald.cpp
@@ -24,7 +24,7 @@
#include "fmt/format.h"
#include "utils/GeneralUtils.h"
#include "utils/OptionalUtils.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
@@ -78,7 +78,7 @@ void ConsumeJournald::onSchedule(core::ProcessContext& context, core::ProcessSes
return process_old_messages ? journal.seekHead() : journal.seekTail();
};
worker_->enqueue([this, &seek_default] {
- const auto cursor = state_manager_->get() | utils::transform([](std::unordered_map<std::string, std::string>&& m) { return m.at(CURSOR_KEY); });
+ const auto cursor = state_manager_->get() | utils::transform([](const std::unordered_map<std::string, std::string>& m) { return m.at(CURSOR_KEY); });
if (!cursor) {
seek_default(*journal_);
} else {
diff --git a/extensions/systemd/ConsumeJournald.h b/extensions/systemd/ConsumeJournald.h
index 32de33253..d658d2015 100644
--- a/extensions/systemd/ConsumeJournald.h
+++ b/extensions/systemd/ConsumeJournald.h
@@ -29,15 +29,15 @@
#include <utility>
#include <vector>
-#include "core/StateManager.h"
+#include "minifi-cpp/core/StateManager.h"
#include "core/ProcessorImpl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "libwrapper/LibWrapper.h"
#include "utils/Deleters.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/FifoExecutor.h"
namespace org::apache::nifi::minifi::extensions::systemd {
diff --git a/extensions/systemd/libwrapper/DlopenWrapper.cpp b/extensions/systemd/libwrapper/DlopenWrapper.cpp
index 4f4131923..87892a437 100644
--- a/extensions/systemd/libwrapper/DlopenWrapper.cpp
+++ b/extensions/systemd/libwrapper/DlopenWrapper.cpp
@@ -18,8 +18,8 @@
#include <dlfcn.h>
-#include "Exception.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/StringUtils.h"
struct sd_journal;
diff --git a/extensions/systemd/libwrapper/LibWrapper.cpp b/extensions/systemd/libwrapper/LibWrapper.cpp
index c405b5ede..47b3e040a 100644
--- a/extensions/systemd/libwrapper/LibWrapper.cpp
+++ b/extensions/systemd/libwrapper/LibWrapper.cpp
@@ -18,16 +18,10 @@
#include "LibWrapper.h"
#include "DlopenWrapper.h"
-namespace org { namespace apache { namespace nifi { namespace minifi { namespace extensions { namespace systemd { namespace libwrapper {
+namespace org::apache::nifi::minifi::extensions::systemd::libwrapper {
std::unique_ptr<LibWrapper> createLibWrapper() {
return std::make_unique<DlopenWrapper>();
}
-} // namespace libwrapper
-} // namespace systemd
-} // namespace extensions
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::extensions::systemd::libwrapper
diff --git a/extensions/systemd/libwrapper/LibWrapper.h b/extensions/systemd/libwrapper/LibWrapper.h
index d7e7b7c26..164710c4f 100644
--- a/extensions/systemd/libwrapper/LibWrapper.h
+++ b/extensions/systemd/libwrapper/LibWrapper.h
@@ -21,9 +21,9 @@
#include <memory>
#include "../Common.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
-namespace org { namespace apache { namespace nifi { namespace minifi { namespace extensions { namespace systemd { namespace libwrapper {
+namespace org::apache::nifi::minifi::extensions::systemd::libwrapper {
struct Journal {
virtual int seekHead() noexcept = 0;
@@ -48,10 +48,4 @@ struct LibWrapper {
std::unique_ptr<LibWrapper> createLibWrapper();
-} // namespace libwrapper
-} // namespace systemd
-} // namespace extensions
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::extensions::systemd::libwrapper
diff --git a/extensions/systemd/tests/ConsumeJournaldTest.cpp b/extensions/systemd/tests/ConsumeJournaldTest.cpp
index 3bed22c00..35d66f536 100644
--- a/extensions/systemd/tests/ConsumeJournaldTest.cpp
+++ b/extensions/systemd/tests/ConsumeJournaldTest.cpp
@@ -24,7 +24,7 @@
#include "unit/Catch.h"
#include "ConsumeJournald.h"
#include "libwrapper/LibWrapper.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/StringUtils.h"
#include "unit/TestUtils.h"
@@ -90,7 +90,7 @@ struct TestJournal final : libwrapper::Journal {
}
int getCursor(gsl::owner<char*>* const cursor_out) noexcept override {
- *cursor_out = gsl::owner<char*>(strdup(std::to_string(consumed).c_str()));
+ *cursor_out = gsl::owner<char*>(strdup(std::to_string(consumed).c_str())); // NOLINT(readability-redundant-casting)
return *cursor_out ? 0 : -ENOMEM;
}
diff --git a/extensions/test-processors/KamikazeProcessor.cpp b/extensions/test-processors/KamikazeProcessor.cpp
index eeabe97aa..94ff074fb 100644
--- a/extensions/test-processors/KamikazeProcessor.cpp
+++ b/extensions/test-processors/KamikazeProcessor.cpp
@@ -21,8 +21,8 @@
#include <string>
-#include "Exception.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/Exception.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Resource.h"
#include "utils/ProcessorConfigUtils.h"
diff --git a/extensions/test-processors/KamikazeProcessor.h b/extensions/test-processors/KamikazeProcessor.h
index 085fc48d9..8fa5f7425 100644
--- a/extensions/test-processors/KamikazeProcessor.h
+++ b/extensions/test-processors/KamikazeProcessor.h
@@ -21,10 +21,10 @@
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "core/Core.h"
#pragma once
diff --git a/extensions/windows-event-log/ConsumeWindowsEventLog.cpp b/extensions/windows-event-log/ConsumeWindowsEventLog.cpp
index cb62bc03c..f524f1d9b 100644
--- a/extensions/windows-event-log/ConsumeWindowsEventLog.cpp
+++ b/extensions/windows-event-log/ConsumeWindowsEventLog.cpp
@@ -33,13 +33,13 @@
#include "wel/JSONUtils.h"
#include "wel/WindowsError.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/Deleters.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/RegexUtils.h"
#include "utils/StringUtils.h"
#include "utils/UnicodeConversion.h"
diff --git a/extensions/windows-event-log/ConsumeWindowsEventLog.h b/extensions/windows-event-log/ConsumeWindowsEventLog.h
index b2760c1d0..14606cd61 100644
--- a/extensions/windows-event-log/ConsumeWindowsEventLog.h
+++ b/extensions/windows-event-log/ConsumeWindowsEventLog.h
@@ -34,19 +34,19 @@
#include "core/Core.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "core/RelationshipDefinition.h"
-#include "core/StateManager.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
+#include "minifi-cpp/core/StateManager.h"
#include "utils/OsUtils.h"
#include "wel/WindowsEventLog.h"
#include "wel/EventPath.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "concurrentqueue.h"
#include "pugixml.hpp"
#include "utils/Enum.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/RegexUtils.h"
namespace org::apache::nifi::minifi::wel {
diff --git a/extensions/windows-event-log/TailEventLog.cpp b/extensions/windows-event-log/TailEventLog.cpp
index d39c012cb..faa8db833 100644
--- a/extensions/windows-event-log/TailEventLog.cpp
+++ b/extensions/windows-event-log/TailEventLog.cpp
@@ -26,12 +26,12 @@
#include <memory>
#include "io/BufferStream.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/Resource.h"
#include "utils/OsUtils.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "utils/ProcessorConfigUtils.h"
namespace org::apache::nifi::minifi::processors {
diff --git a/extensions/windows-event-log/TailEventLog.h b/extensions/windows-event-log/TailEventLog.h
index c5bd991b2..9ba18378e 100644
--- a/extensions/windows-event-log/TailEventLog.h
+++ b/extensions/windows-event-log/TailEventLog.h
@@ -25,12 +25,12 @@
#include <Windows.h>
#include "core/Core.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
namespace org {
namespace apache {
diff --git a/extensions/windows-event-log/tests/BookmarkTests.cpp b/extensions/windows-event-log/tests/BookmarkTests.cpp
index cd1f4edf5..e154c9955 100644
--- a/extensions/windows-event-log/tests/BookmarkTests.cpp
+++ b/extensions/windows-event-log/tests/BookmarkTests.cpp
@@ -20,7 +20,7 @@
#include "unit/TestBase.h"
#include "unit/Catch.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "wel/Bookmark.h"
#include "wel/UniqueEvtHandle.h"
#include "CWELTestUtils.h"
diff --git a/extensions/windows-event-log/tests/CWELTestUtils.h b/extensions/windows-event-log/tests/CWELTestUtils.h
index 65cd39816..e7a223aa0 100644
--- a/extensions/windows-event-log/tests/CWELTestUtils.h
+++ b/extensions/windows-event-log/tests/CWELTestUtils.h
@@ -32,7 +32,7 @@
#include "unit/TestUtils.h"
#include "utils/UnicodeConversion.h"
#include "utils/file/FileUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
core::Relationship Success{"success", "Everything is fine"};
diff --git a/extensions/windows-event-log/wel/Bookmark.h b/extensions/windows-event-log/wel/Bookmark.h
index 36ffe6eaf..668e0e581 100644
--- a/extensions/windows-event-log/wel/Bookmark.h
+++ b/extensions/windows-event-log/wel/Bookmark.h
@@ -24,9 +24,9 @@
#include <memory>
#include <type_traits>
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "utils/expected.h"
#include "EventPath.h"
#include "UniqueEvtHandle.h"
diff --git a/extensions/windows-event-log/wel/EventPath.h b/extensions/windows-event-log/wel/EventPath.h
index 8a02d5a00..8358c713b 100644
--- a/extensions/windows-event-log/wel/EventPath.h
+++ b/extensions/windows-event-log/wel/EventPath.h
@@ -23,7 +23,7 @@
#include <string>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::wel {
diff --git a/extensions/windows-event-log/wel/JSONUtils.cpp b/extensions/windows-event-log/wel/JSONUtils.cpp
index 9ae103468..a90f090a6 100644
--- a/extensions/windows-event-log/wel/JSONUtils.cpp
+++ b/extensions/windows-event-log/wel/JSONUtils.cpp
@@ -26,7 +26,7 @@
#include "rapidjson/writer.h"
#include "rapidjson/stringbuffer.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/StringUtils.h"
namespace org::apache::nifi::minifi::wel {
diff --git a/extensions/windows-event-log/wel/MetadataWalker.h b/extensions/windows-event-log/wel/MetadataWalker.h
index b9da6c677..cb6740739 100644
--- a/extensions/windows-event-log/wel/MetadataWalker.h
+++ b/extensions/windows-event-log/wel/MetadataWalker.h
@@ -34,7 +34,7 @@
#include "core/Core.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "WindowsEventLog.h"
#include "concurrentqueue.h"
diff --git a/extensions/windows-event-log/wel/WindowsEventLog.cpp b/extensions/windows-event-log/wel/WindowsEventLog.cpp
index ad554e615..d929534e3 100644
--- a/extensions/windows-event-log/wel/WindowsEventLog.cpp
+++ b/extensions/windows-event-log/wel/WindowsEventLog.cpp
@@ -25,7 +25,7 @@
#include <string>
#include "utils/Deleters.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/UnicodeConversion.h"
#include "UniqueEvtHandle.h"
diff --git a/extensions/windows-event-log/wel/WindowsEventLog.h b/extensions/windows-event-log/wel/WindowsEventLog.h
index b73c54573..95ac9bc50 100644
--- a/extensions/windows-event-log/wel/WindowsEventLog.h
+++ b/extensions/windows-event-log/wel/WindowsEventLog.h
@@ -35,7 +35,7 @@
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
#include "utils/OsUtils.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "UniqueEvtHandle.h"
#include "pugixml.hpp"
diff --git a/extensions/windows-event-log/wel/XMLString.h b/extensions/windows-event-log/wel/XMLString.h
index cb42218c4..b8d53117c 100644
--- a/extensions/windows-event-log/wel/XMLString.h
+++ b/extensions/windows-event-log/wel/XMLString.h
@@ -30,7 +30,7 @@
#include "core/Core.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "FlowFileRecord.h"
+#include "minifi-cpp/FlowFileRecord.h"
#include "utils/OsUtils.h"
#include "concurrentqueue.h"
diff --git a/generateVersion.bat b/generateVersion.bat
index d2512510e..8b11dd7ca 100644
--- a/generateVersion.bat
+++ b/generateVersion.bat
@@ -47,7 +47,7 @@ for %%i in (%extensions%) do (
(
echo #include ^<string^>
echo #include ^<vector^>
- echo #include "agent/agent_version.h"
+ echo #include "minifi-cpp/agent/agent_version.h"
echo namespace org {
echo namespace apache {
@@ -72,7 +72,7 @@ for %%i in (%extensions%) do (
)>> "%out_dir%/agent_version.cpp"
)
-
+
(
echo extensions.push_back^("minifi-system"^);
echo }
@@ -87,7 +87,7 @@ for %%i in (%extensions%) do (
goto :EOF
- rem see license regarding the following snippet of code taken from
+ rem see license regarding the following snippet of code taken from
rem https://github.com/ritchielawrence/batchfunctionlibrary
:GetUnixTime
diff --git a/generateVersion.sh b/generateVersion.sh
index 029b81bf1..78ceb2687 100755
--- a/generateVersion.sh
+++ b/generateVersion.sh
@@ -58,7 +58,7 @@ cat >"$out_dir/agent_version.cpp" <<EOF
#include <string>
#include <vector>
-#include "agent/agent_version.h"
+#include "minifi-cpp/agent/agent_version.h"
namespace org {
namespace apache {
diff --git a/libminifi/include/Connection.h b/libminifi/include/Connection.h
index 114c33a90..f3048c8fa 100644
--- a/libminifi/include/Connection.h
+++ b/libminifi/include/Connection.h
@@ -30,12 +30,13 @@
#include <utility>
#include "core/Core.h"
#include "core/Connectable.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/Relationship.h"
-#include "core/FlowFile.h"
-#include "core/Repository.h"
+#include "minifi-cpp/core/FlowFile.h"
+#include "minifi-cpp/core/Repository.h"
#include "utils/FlowFileQueue.h"
#include "minifi-cpp/Connection.h"
+#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi {
diff --git a/libminifi/include/CronDrivenSchedulingAgent.h b/libminifi/include/CronDrivenSchedulingAgent.h
index 7d422e785..d08ac5a4f 100644
--- a/libminifi/include/CronDrivenSchedulingAgent.h
+++ b/libminifi/include/CronDrivenSchedulingAgent.h
@@ -25,10 +25,10 @@
#include <string>
#include <utility>
-#include "core/logging/Logger.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/Processor.h"
-#include "core/ProcessSessionFactory.h"
+#include "minifi-cpp/core/ProcessSessionFactory.h"
#include "utils/Cron.h"
#include "ThreadedSchedulingAgent.h"
diff --git a/libminifi/include/EventDrivenSchedulingAgent.h b/libminifi/include/EventDrivenSchedulingAgent.h
index 2a42a6933..060fff588 100644
--- a/libminifi/include/EventDrivenSchedulingAgent.h
+++ b/libminifi/include/EventDrivenSchedulingAgent.h
@@ -25,10 +25,10 @@
constexpr auto DEFAULT_TIME_SLICE = std::chrono::milliseconds(500);
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/Processor.h"
-#include "core/ProcessContext.h"
-#include "core/ProcessSessionFactory.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessSessionFactory.h"
#include "ThreadedSchedulingAgent.h"
namespace org::apache::nifi::minifi {
diff --git a/libminifi/include/FlowController.h b/libminifi/include/FlowController.h
index 0d55db725..069a80692 100644
--- a/libminifi/include/FlowController.h
+++ b/libminifi/include/FlowController.h
@@ -32,32 +32,27 @@
#include <utility>
#include <vector>
-#include "Connection.h"
-#include "core/controller/ControllerServiceNode.h"
-#include "core/controller/ControllerServiceProvider.h"
+#include "minifi-cpp/core/controller/ControllerServiceProvider.h"
#include "core/controller/ForwardingControllerServiceProvider.h"
#include "core/FlowConfiguration.h"
-#include "core/logging/Logger.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessGroup.h"
#include "core/Processor.h"
#include "core/ProcessSession.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/Relationship.h"
#include "core/state/nodes/FlowInformation.h"
-#include "core/state/nodes/MetricsBase.h"
+#include "minifi-cpp/core/state/nodes/MetricsBase.h"
#include "core/state/UpdateController.h"
#include "c2/C2Agent.h"
#include "CronDrivenSchedulingAgent.h"
#include "EventDrivenSchedulingAgent.h"
-#include "FlowFileRecord.h"
#include "properties/Configure.h"
#include "TimerDrivenSchedulingAgent.h"
#include "utils/Id.h"
#include "utils/file/FileSystem.h"
#include "utils/file/AssetManager.h"
-#include "core/state/nodes/ResponseNodeLoader.h"
-#include "core/state/MetricsPublisher.h"
#include "core/state/MetricsPublisherStore.h"
#include "RootProcessGroupWrapper.h"
#include "c2/ControllerSocketProtocol.h"
diff --git a/libminifi/include/FlowFileRecord.h b/libminifi/include/FlowFileRecord.h
index 260453ae3..667da06a4 100644
--- a/libminifi/include/FlowFileRecord.h
+++ b/libminifi/include/FlowFileRecord.h
@@ -30,13 +30,11 @@
#include <sstream>
#include <fstream>
#include <set>
-#include "core/ContentRepository.h"
+#include "minifi-cpp/core/ContentRepository.h"
#include "core/FlowFile.h"
#include "utils/TimeUtil.h"
#include "core/logging/LoggerFactory.h"
-#include "ResourceClaim.h"
-#include "Connection.h"
-#include "io/OutputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
#include "io/StreamPipe.h"
#include "minifi-cpp/FlowFileRecord.h"
diff --git a/libminifi/include/RemoteProcessGroupPort.h b/libminifi/include/RemoteProcessGroupPort.h
index 1f4538c00..a1572b939 100644
--- a/libminifi/include/RemoteProcessGroupPort.h
+++ b/libminifi/include/RemoteProcessGroupPort.h
@@ -28,16 +28,15 @@
#include "http/BaseHTTPClient.h"
#include "concurrentqueue.h"
-#include "FlowFileRecord.h"
#include "core/ProcessorImpl.h"
#include "core/ProcessSession.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
-#include "core/RelationshipDefinition.h"
+#include "minifi-cpp/core/RelationshipDefinition.h"
#include "sitetosite/SiteToSiteClient.h"
#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "core/logging/LoggerFactory.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "core/ClassLoader.h"
namespace org::apache::nifi::minifi {
diff --git a/libminifi/include/ResourceClaim.h b/libminifi/include/ResourceClaim.h
index 6db004811..63ef7e5e1 100644
--- a/libminifi/include/ResourceClaim.h
+++ b/libminifi/include/ResourceClaim.h
@@ -25,7 +25,7 @@
#include <mutex>
#include <atomic>
#include "core/Core.h"
-#include "core/StreamManager.h"
+#include "minifi-cpp/core/StreamManager.h"
#include "properties/Configure.h"
#include "utils/Id.h"
diff --git a/libminifi/include/RootProcessGroupWrapper.h b/libminifi/include/RootProcessGroupWrapper.h
index 2dc6c3a5d..e69585cdf 100644
--- a/libminifi/include/RootProcessGroupWrapper.h
+++ b/libminifi/include/RootProcessGroupWrapper.h
@@ -28,10 +28,9 @@
#include "core/ProcessGroup.h"
#include "utils/Id.h"
#include "core/state/ProcessorController.h"
-#include "core/state/MetricsPublisher.h"
#include "core/state/MetricsPublisherStore.h"
-#include "utils/gsl.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/utils/gsl.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "c2/ControllerSocketProtocol.h"
namespace org::apache::nifi::minifi {
diff --git a/libminifi/include/SchedulingAgent.h b/libminifi/include/SchedulingAgent.h
index f50ddc571..eeea76bcb 100644
--- a/libminifi/include/SchedulingAgent.h
+++ b/libminifi/include/SchedulingAgent.h
@@ -38,12 +38,10 @@
#include "core/Core.h"
#include "core/logging/LoggerFactory.h"
#include "properties/Configure.h"
-#include "FlowFileRecord.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/Processor.h"
-#include "core/ProcessContext.h"
-#include "core/controller/ControllerServiceProvider.h"
-#include "core/controller/ControllerServiceNode.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/core/controller/ControllerServiceProvider.h"
constexpr std::chrono::milliseconds SCHEDULING_WATCHDOG_CHECK_PERIOD = std::chrono::seconds(1);
constexpr std::chrono::milliseconds SCHEDULING_WATCHDOG_DEFAULT_ALERT_PERIOD = std::chrono::seconds(5);
diff --git a/libminifi/include/ThreadedSchedulingAgent.h b/libminifi/include/ThreadedSchedulingAgent.h
index a831a3377..7a3ad2299 100644
--- a/libminifi/include/ThreadedSchedulingAgent.h
+++ b/libminifi/include/ThreadedSchedulingAgent.h
@@ -26,8 +26,8 @@
#include "properties/Configure.h"
#include "core/logging/LoggerFactory.h"
#include "core/Processor.h"
-#include "core/Repository.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/Repository.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "SchedulingAgent.h"
namespace org::apache::nifi::minifi {
diff --git a/libminifi/include/TimerDrivenSchedulingAgent.h b/libminifi/include/TimerDrivenSchedulingAgent.h
index b91522f96..99073ce99 100644
--- a/libminifi/include/TimerDrivenSchedulingAgent.h
+++ b/libminifi/include/TimerDrivenSchedulingAgent.h
@@ -21,10 +21,10 @@
#include <memory>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "core/Processor.h"
-#include "core/ProcessContext.h"
-#include "core/Repository.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/core/Repository.h"
#include "ThreadedSchedulingAgent.h"
namespace org::apache::nifi::minifi {
diff --git a/libminifi/include/agent/build_description.h b/libminifi/include/agent/build_description.h
index 6de800ea5..85d96741f 100644
--- a/libminifi/include/agent/build_description.h
+++ b/libminifi/include/agent/build_description.h
@@ -23,13 +23,12 @@
#include <utility>
#include <vector>
#include "agent/agent_docs.h"
-#include "core/controller/ControllerService.h"
#include "core/ClassLoader.h"
#include "core/expect.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/Relationship.h"
#include "core/Processor.h"
-#include "core/Annotation.h"
+#include "minifi-cpp/core/Annotation.h"
#include "io/validation.h"
#include "minifi-cpp/agent/build_description.h"
diff --git a/libminifi/include/c2/C2Agent.h b/libminifi/include/c2/C2Agent.h
index eb9702cb6..8a27f41ec 100644
--- a/libminifi/include/c2/C2Agent.h
+++ b/libminifi/include/c2/C2Agent.h
@@ -29,7 +29,7 @@
#include <utility>
#include <vector>
-#include "core/state/nodes/MetricsBase.h"
+#include "minifi-cpp/core/state/nodes/MetricsBase.h"
#include "core/state/UpdateController.h"
#include "controllers/UpdatePolicyControllerService.h"
#include "C2Payload.h"
diff --git a/libminifi/include/c2/C2MetricsPublisher.h b/libminifi/include/c2/C2MetricsPublisher.h
index 4472a6de4..432e09c7b 100644
--- a/libminifi/include/c2/C2MetricsPublisher.h
+++ b/libminifi/include/c2/C2MetricsPublisher.h
@@ -27,14 +27,12 @@
#include <functional>
#include "c2/C2Agent.h"
-#include "core/controller/ControllerServiceProvider.h"
#include "properties/Configure.h"
-#include "core/logging/Logger.h"
-#include "core/state/nodes/MetricsBase.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/core/state/nodes/MetricsBase.h"
#include "core/ProcessGroup.h"
#include "core/Core.h"
#include "utils/file/FileSystem.h"
-#include "core/state/nodes/ResponseNodeLoader.h"
#include "utils/Id.h"
#include "core/state/MetricsPublisher.h"
diff --git a/libminifi/include/c2/C2Payload.h b/libminifi/include/c2/C2Payload.h
index 62a0971c5..43b28cba6 100644
--- a/libminifi/include/c2/C2Payload.h
+++ b/libminifi/include/c2/C2Payload.h
@@ -27,7 +27,7 @@
#include "core/state/Value.h"
#include "core/state/UpdateController.h"
#include "utils/Enum.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/span.h"
#include "rapidjson/document.h"
diff --git a/libminifi/include/c2/C2Protocol.h b/libminifi/include/c2/C2Protocol.h
index d7b016fb4..18c7e9894 100644
--- a/libminifi/include/c2/C2Protocol.h
+++ b/libminifi/include/c2/C2Protocol.h
@@ -24,7 +24,7 @@
#include <vector>
#include "C2Payload.h"
-#include "core/controller/ControllerServiceProvider.h"
+#include "minifi-cpp/core/controller/ControllerServiceProvider.h"
#include "properties/Configure.h"
#include "core/Connectable.h"
namespace org::apache::nifi::minifi::c2 {
diff --git a/libminifi/include/c2/C2Utils.h b/libminifi/include/c2/C2Utils.h
index f49b83b6c..7389e489e 100644
--- a/libminifi/include/c2/C2Utils.h
+++ b/libminifi/include/c2/C2Utils.h
@@ -24,7 +24,7 @@
#include "properties/Configure.h"
#include "utils/StringUtils.h"
-#include "io/ArchiveStream.h"
+#include "minifi-cpp/io/ArchiveStream.h"
#include "utils/expected.h"
#include "io/BufferStream.h"
diff --git a/libminifi/include/c2/ControllerSocketProtocol.h b/libminifi/include/c2/ControllerSocketProtocol.h
index abb15cb31..1ed31759e 100644
--- a/libminifi/include/c2/ControllerSocketProtocol.h
+++ b/libminifi/include/c2/ControllerSocketProtocol.h
@@ -23,10 +23,10 @@
#include <mutex>
#include <atomic>
-#include "io/BaseStream.h"
+#include "minifi-cpp/io/BaseStream.h"
#include "core/logging/LoggerFactory.h"
#include "core/state/nodes/StateMonitor.h"
-#include "core/controller/ControllerServiceProvider.h"
+#include "minifi-cpp/core/controller/ControllerServiceProvider.h"
#include "ControllerSocketReporter.h"
#include "utils/MinifiConcurrentQueue.h"
#include "asio/ip/tcp.hpp"
diff --git a/libminifi/include/c2/HeartbeatLogger.h b/libminifi/include/c2/HeartbeatLogger.h
index cd2c4b062..d8930a33d 100644
--- a/libminifi/include/c2/HeartbeatLogger.h
+++ b/libminifi/include/c2/HeartbeatLogger.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "HeartbeatReporter.h"
#include "c2/protocols/RESTProtocol.h"
diff --git a/libminifi/include/c2/HeartbeatReporter.h b/libminifi/include/c2/HeartbeatReporter.h
index 648add6d1..b9b85a109 100644
--- a/libminifi/include/c2/HeartbeatReporter.h
+++ b/libminifi/include/c2/HeartbeatReporter.h
@@ -24,7 +24,7 @@
#include "C2Protocol.h"
#include "C2Payload.h"
-#include "core/controller/ControllerServiceProvider.h"
+#include "minifi-cpp/core/controller/ControllerServiceProvider.h"
#include "properties/Configure.h"
#include "core/Connectable.h"
diff --git a/libminifi/include/c2/PayloadSerializer.h b/libminifi/include/c2/PayloadSerializer.h
index e9ca060b9..097aa9773 100644
--- a/libminifi/include/c2/PayloadSerializer.h
+++ b/libminifi/include/c2/PayloadSerializer.h
@@ -26,10 +26,10 @@
#include "core/state/Value.h"
#include "c2/C2Protocol.h"
-#include "io/OutputStream.h"
-#include "io/InputStream.h"
+#include "minifi-cpp/io/OutputStream.h"
+#include "minifi-cpp/io/InputStream.h"
#include "io/BufferStream.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org {
namespace apache {
diff --git a/libminifi/include/c2/protocols/RESTProtocol.h b/libminifi/include/c2/protocols/RESTProtocol.h
index 069c4966c..8f45f7de2 100644
--- a/libminifi/include/c2/protocols/RESTProtocol.h
+++ b/libminifi/include/c2/protocols/RESTProtocol.h
@@ -24,7 +24,7 @@
#include "c2/C2Payload.h"
#include "c2/HeartbeatJsonSerializer.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/logging/LoggerFactory.h"
namespace org::apache::nifi::minifi::c2 {
diff --git a/libminifi/include/controllers/NetworkPrioritizerService.h b/libminifi/include/controllers/NetworkPrioritizerService.h
index 0c4a5204b..fcb08c10a 100644
--- a/libminifi/include/controllers/NetworkPrioritizerService.h
+++ b/libminifi/include/controllers/NetworkPrioritizerService.h
@@ -27,12 +27,11 @@
#include "io/validation.h"
#include "core/controller/ControllerService.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
-#include "ThreadManagementService.h"
#include "io/NetworkPrioritizer.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::controllers {
diff --git a/libminifi/include/controllers/SSLContextService.h b/libminifi/include/controllers/SSLContextService.h
index 8d7e3d738..db5f19b26 100644
--- a/libminifi/include/controllers/SSLContextService.h
+++ b/libminifi/include/controllers/SSLContextService.h
@@ -35,7 +35,7 @@
#include "openssl/pkcs12.h"
#include "openssl/ssl.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "core/controller/ControllerService.h"
#include "core/logging/LoggerFactory.h"
@@ -43,7 +43,7 @@
#include "minifi-cpp/controllers/SSLContextServiceInterface.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "utils/ConfigurationUtils.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "utils/StringUtils.h"
#include "utils/tls/CertificateUtils.h"
#include "utils/tls/ExtendedKeyUsage.h"
diff --git a/libminifi/include/controllers/UpdatePolicyControllerService.h b/libminifi/include/controllers/UpdatePolicyControllerService.h
index 61e72f38e..a4e6eebd8 100644
--- a/libminifi/include/controllers/UpdatePolicyControllerService.h
+++ b/libminifi/include/controllers/UpdatePolicyControllerService.h
@@ -26,11 +26,11 @@
#include "io/validation.h"
#include "core/controller/ControllerService.h"
#include "core/logging/LoggerFactory.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/PropertyValidator.h"
#include "core/state/UpdatePolicy.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
namespace org::apache::nifi::minifi::controllers {
diff --git a/libminifi/include/core/FlowConfiguration.h b/libminifi/include/core/FlowConfiguration.h
index 7347c12e6..2005d90aa 100644
--- a/libminifi/include/core/FlowConfiguration.h
+++ b/libminifi/include/core/FlowConfiguration.h
@@ -26,16 +26,15 @@
#include <filesystem>
#include "core/Core.h"
-#include "Connection.h"
+#include "minifi-cpp/Connection.h"
#include "RemoteProcessGroupPort.h"
-#include "core/controller/ControllerServiceNode.h"
+#include "minifi-cpp/core/controller/ControllerServiceNode.h"
#include "core/controller/StandardControllerServiceProvider.h"
-#include "provenance/Provenance.h"
#include "core/reporting/SiteToSiteProvenanceReportingTask.h"
#include "core/Processor.h"
#include "core/logging/LoggerFactory.h"
-#include "core/ProcessContext.h"
+#include "minifi-cpp/core/ProcessContext.h"
#include "core/ProcessSession.h"
#include "core/ProcessGroup.h"
#include "core/state/nodes/FlowInformation.h"
diff --git a/libminifi/include/core/FlowFile.h b/libminifi/include/core/FlowFile.h
index feb89b42e..2c2b3c583 100644
--- a/libminifi/include/core/FlowFile.h
+++ b/libminifi/include/core/FlowFile.h
@@ -27,16 +27,14 @@
#include <vector>
#include "utils/TimeUtil.h"
-#include "ResourceClaim.h"
-#include "core/Connectable.h"
+#include "minifi-cpp/ResourceClaim.h"
+#include "core/Core.h"
#include "WeakReference.h"
-#include "utils/Export.h"
+#include "minifi-cpp/utils/Export.h"
#include "minifi-cpp/core/FlowFile.h"
namespace org::apache::nifi::minifi::core {
-class Connectable;
-
class FlowFileImpl : public CoreComponentImpl, public ReferenceContainerImpl, public virtual FlowFile {
public:
FlowFileImpl();
diff --git a/libminifi/include/core/ForwardingContentSession.h b/libminifi/include/core/ForwardingContentSession.h
index b4b3f65cc..620c71fa3 100644
--- a/libminifi/include/core/ForwardingContentSession.h
+++ b/libminifi/include/core/ForwardingContentSession.h
@@ -20,8 +20,9 @@
#include <unordered_set>
#include <memory>
-#include "ResourceClaim.h"
-#include "io/BaseStream.h"
+#include "minifi-cpp/ResourceClaim.h"
+#include "minifi-cpp/io/BaseStream.h"
+#include "minifi-cpp/core/ContentRepository.h"
#include "core/ContentSession.h"
namespace org::apache::nifi::minifi::core {
diff --git a/libminifi/include/core/ParameterContext.h b/libminifi/include/core/ParameterContext.h
index 0d4c78643..08139913f 100644
--- a/libminifi/include/core/ParameterContext.h
+++ b/libminifi/include/core/ParameterContext.h
@@ -22,7 +22,7 @@
#include <optional>
#include "core/Core.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::core {
diff --git a/libminifi/include/core/ParameterTokenParser.h b/libminifi/include/core/ParameterTokenParser.h
index 065e443eb..2b1c09428 100644
--- a/libminifi/include/core/ParameterTokenParser.h
+++ b/libminifi/include/core/ParameterTokenParser.h
@@ -24,7 +24,7 @@
#include <optional>
#include "ParameterContext.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "utils/crypto/EncryptionProvider.h"
namespace org::apache::nifi::minifi::core {
diff --git a/libminifi/include/core/ProcessGroup.h b/libminifi/include/core/ProcessGroup.h
index fc6b8ec89..9e8fba8ce 100644
--- a/libminifi/include/core/ProcessGroup.h
+++ b/libminifi/include/core/ProcessGroup.h
@@ -30,13 +30,13 @@
#include <tuple>
#include "core/Processor.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "TimerDrivenSchedulingAgent.h"
#include "EventDrivenSchedulingAgent.h"
#include "CronDrivenSchedulingAgent.h"
#include "Port.h"
-#include "core/logging/Logger.h"
-#include "controller/ControllerServiceNode.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/core/controller/ControllerServiceNode.h"
#include "controller/ControllerServiceNodeMap.h"
#include "utils/Id.h"
#include "http/BaseHTTPClient.h"
diff --git a/libminifi/include/core/ProcessSession.h b/libminifi/include/core/ProcessSession.h
index 0a761ba23..8116466c0 100644
--- a/libminifi/include/core/ProcessSession.h
+++ b/libminifi/include/core/ProcessSession.h
@@ -30,14 +30,14 @@
#include <unordered_map>
#include <unordered_set>
-#include "core/ProcessContext.h"
-#include "FlowFileRecord.h"
-#include "Exception.h"
+#include "minifi-cpp/core/ProcessContext.h"
+#include "minifi-cpp/Exception.h"
#include "core/logging/LoggerFactory.h"
#include "FlowFile.h"
#include "WeakReference.h"
#include "provenance/Provenance.h"
-#include "utils/gsl.h"
+#include "core/Relationship.h"
+#include "minifi-cpp/utils/gsl.h"
#include "minifi-cpp/core/ProcessorMetrics.h"
#include "minifi-cpp/core/ProcessSession.h"
diff --git a/libminifi/include/core/ProcessSessionReadCallback.h b/libminifi/include/core/ProcessSessionReadCallback.h
index 55389ac45..715f4155e 100644
--- a/libminifi/include/core/ProcessSessionReadCallback.h
+++ b/libminifi/include/core/ProcessSessionReadCallback.h
@@ -24,7 +24,7 @@
#include "core/logging/LoggerFactory.h"
#include "FlowFileRecord.h"
-#include "io/InputStream.h"
+#include "minifi-cpp/io/InputStream.h"
namespace org::apache::nifi::minifi::core {
class ProcessSessionReadCallback {
diff --git a/libminifi/include/core/Processor.h b/libminifi/include/core/Processor.h
index 9daec72c1..9dc850859 100644
--- a/libminifi/include/core/Processor.h
+++ b/libminifi/include/core/Processor.h
@@ -32,14 +32,14 @@
#include "core/ConfigurableComponentImpl.h"
#include "core/Connectable.h"
-#include "core/Property.h"
+#include "minifi-cpp/core/Property.h"
#include "core/Core.h"
#include "minifi-cpp/core/Annotation.h"
#include "minifi-cpp/core/DynamicProperty.h"
#include "minifi-cpp/core/Scheduling.h"
#include "minifi-cpp/core/state/nodes/MetricsBase.h"
#include "minifi-cpp/core/ProcessorMetrics.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/Id.h"
#include "minifi-cpp/core/OutputAttributeDefinition.h"
#include "Processor.h"
diff --git a/libminifi/include/core/RepositoryFactory.h b/libminifi/include/core/RepositoryFactory.h
index 3eda7b0ea..67c308aef 100644
--- a/libminifi/include/core/RepositoryFactory.h
+++ b/libminifi/include/core/RepositoryFactory.h
@@ -21,8 +21,8 @@
#include <memory>
#include <string>
-#include "core/ContentRepository.h"
-#include "core/Repository.h"
+#include "minifi-cpp/core/ContentRepository.h"
+#include "minifi-cpp/core/Repository.h"
#include "core/Core.h"
namespace org::apache::nifi::minifi::core {
diff --git a/libminifi/include/core/SerializableComponent.h b/libminifi/include/core/SerializableComponent.h
index e1e9c8a98..e7ecb4138 100644
--- a/libminifi/include/core/SerializableComponent.h
+++ b/libminifi/include/core/SerializableComponent.h
@@ -21,9 +21,7 @@
#include <utility>
#include "core/Core.h"
-#include "utils/gsl.h"
-#include "io/InputStream.h"
-#include "io/OutputStream.h"
+#include "minifi-cpp/utils/gsl.h"
#include "minifi-cpp/core/SerializableComponent.h"
namespace org::apache::nifi::minifi::core {
diff --git a/libminifi/include/core/controller/ControllerServiceLookup.h b/libminifi/include/core/controller/ControllerServiceLookup.h
deleted file mode 100644
index 2539b90bd..000000000
--- a/libminifi/include/core/controller/ControllerServiceLookup.h
+++ /dev/null
@@ -1,21 +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.
- */
-
-#pragma once
-
-#include "minifi-cpp/core/controller/ControllerServiceLookup.h"
diff --git a/libminifi/include/core/controller/ControllerServiceNode.h b/libminifi/include/core/controller/ControllerServiceNode.h
index 874cfdc43..5a188bef0 100644
--- a/libminifi/include/core/controller/ControllerServiceNode.h
+++ b/libminifi/include/core/controller/ControllerServiceNode.h
@@ -24,14 +24,14 @@
#include "core/Core.h"
#include "core/ConfigurableComponentImpl.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "minifi-cpp/core/controller/ControllerServiceNode.h"
-#include "core/PropertyDefinition.h"
+#include "minifi-cpp/core/PropertyDefinition.h"
#include "core/PropertyDefinitionBuilder.h"
#include "properties/Configure.h"
#include "minifi-cpp/core/controller/ControllerService.h"
#include "io/validation.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
namespace org::apache::nifi::minifi::core::controller {
diff --git a/libminifi/include/core/controller/ControllerServiceNodeMap.h b/libminifi/include/core/controller/ControllerServiceNodeMap.h
index 27a47e104..84f954a0a 100644
--- a/libminifi/include/core/controller/ControllerServiceNodeMap.h
+++ b/libminifi/include/core/controller/ControllerServiceNodeMap.h
@@ -22,7 +22,7 @@
#include <vector>
#include <map>
#include <string>
-#include "ControllerServiceNode.h"
+#include "minifi-cpp/core/controller/ControllerServiceNode.h"
#include "io/validation.h"
namespace org::apache::nifi::minifi::core {
diff --git a/libminifi/include/core/controller/ControllerServiceProvider.h b/libminifi/include/core/controller/ControllerServiceProvider.h
index d72444a81..e700b6d81 100644
--- a/libminifi/include/core/controller/ControllerServiceProvider.h
+++ b/libminifi/include/core/controller/ControllerServiceProvider.h
@@ -27,9 +27,9 @@
#include "minifi-cpp/core/controller/ControllerServiceProvider.h"
#include "core/Core.h"
-#include "ControllerServiceLookup.h"
+#include "minifi-cpp/core/controller/ControllerServiceLookup.h"
#include "core/ConfigurableComponentImpl.h"
-#include "ControllerServiceNode.h"
+#include "minifi-cpp/core/controller/ControllerServiceNode.h"
#include "ControllerServiceNodeMap.h"
#include "core/ClassLoader.h"
#include "utils/Monitors.h"
diff --git a/libminifi/include/core/controller/ForwardingControllerServiceProvider.h b/libminifi/include/core/controller/ForwardingControllerServiceProvider.h
index 09d91b00f..edf350bbe 100644
--- a/libminifi/include/core/controller/ForwardingControllerServiceProvider.h
+++ b/libminifi/include/core/controller/ForwardingControllerServiceProvider.h
@@ -23,7 +23,7 @@
#include <string>
#include "ControllerServiceProvider.h"
-#include "ControllerServiceNode.h"
+#include "minifi-cpp/core/controller/ControllerServiceNode.h"
namespace org::apache::nifi::minifi::core::controller {
diff --git a/libminifi/include/core/extension/ExtensionManager.h b/libminifi/include/core/extension/ExtensionManager.h
index 25a99e199..e8b316fac 100644
--- a/libminifi/include/core/extension/ExtensionManager.h
+++ b/libminifi/include/core/extension/ExtensionManager.h
@@ -21,7 +21,7 @@
#include <string>
#include <vector>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "Module.h"
#include "properties/Configure.h"
#include "minifi-cpp/core/extension/ExtensionManager.h"
diff --git a/libminifi/include/core/extension/Module.h b/libminifi/include/core/extension/Module.h
index 6b4941b76..f531b4114 100644
--- a/libminifi/include/core/extension/Module.h
+++ b/libminifi/include/core/extension/Module.h
@@ -21,10 +21,10 @@
#include <string>
#include <vector>
-#include "core/logging/Logger.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/core/logging/Logger.h"
+#include "minifi-cpp/utils/gsl.h"
#include "properties/Configure.h"
-#include "core/extension/Extension.h"
+#include "minifi-cpp/core/extension/Extension.h"
namespace org {
namespace apache {
diff --git a/libminifi/include/core/extension/Utils.h b/libminifi/include/core/extension/Utils.h
index 623f4b42a..d6e5e11bb 100644
--- a/libminifi/include/core/extension/Utils.h
+++ b/libminifi/include/core/extension/Utils.h
@@ -26,7 +26,7 @@
#include <string>
#include <utility>
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/StringUtils.h"
#include "utils/file/FileUtils.h"
#include "utils/file/PathUtils.h"
diff --git a/libminifi/include/core/flow/Node.h b/libminifi/include/core/flow/Node.h
index ed32d8843..f127288b7 100644
--- a/libminifi/include/core/flow/Node.h
+++ b/libminifi/include/core/flow/Node.h
@@ -26,7 +26,7 @@
#include <utility>
#include "nonstd/expected.hpp"
#include "utils/StringUtils.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
namespace org::apache::nifi::minifi::core::flow {
diff --git a/libminifi/include/core/flow/StructuredConfiguration.h b/libminifi/include/core/flow/StructuredConfiguration.h
index 95da310ea..b335a4f94 100644
--- a/libminifi/include/core/flow/StructuredConfiguration.h
+++ b/libminifi/include/core/flow/StructuredConfiguration.h
@@ -26,7 +26,7 @@
#include "core/FlowConfiguration.h"
#include "core/logging/LoggerConfiguration.h"
#include "minifi-cpp/core/ProcessorConfig.h"
-#include "Exception.h"
+#include "minifi-cpp/Exception.h"
#include "io/validation.h"
#include "sitetosite/SiteToSite.h"
#include "utils/Id.h"
diff --git a/libminifi/include/core/flow/StructuredConnectionParser.h b/libminifi/include/core/flow/StructuredConnectionParser.h
index 730fade25..3f6faca56 100644
--- a/libminifi/include/core/flow/StructuredConnectionParser.h
+++ b/libminifi/include/core/flow/StructuredConnectionParser.h
@@ -26,7 +26,7 @@
#include "core/logging/LoggerFactory.h"
#include "core/flow/Node.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "core/flow/FlowSchema.h"
namespace org::apache::nifi::minifi::core::flow {
diff --git a/libminifi/include/core/json/JsonNode.h b/libminifi/include/core/json/JsonNode.h
index 0d874cd05..7751ba6e0 100644
--- a/libminifi/include/core/json/JsonNode.h
+++ b/libminifi/include/core/json/JsonNode.h
@@ -24,7 +24,7 @@
#include "core/flow/Node.h"
#include "rapidjson/document.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ValueCaster.h"
namespace org::apache::nifi::minifi::core {
diff --git a/libminifi/include/core/logging/LoggerBase.h b/libminifi/include/core/logging/LoggerBase.h
index a0132d87b..d9a4c4815 100644
--- a/libminifi/include/core/logging/LoggerBase.h
+++ b/libminifi/include/core/logging/LoggerBase.h
@@ -29,7 +29,7 @@
#include "spdlog/common.h"
#include "spdlog/logger.h"
-#include "utils/gsl.h"
+#include "minifi-cpp/utils/gsl.h"
#include "utils/ConfigurationUtils.h"
#include "utils/Enum.h"
#include "utils/GeneralUtils.h"
diff --git a/libminifi/include/core/logging/LoggerFactory.h b/libminifi/include/core/logging/LoggerFactory.h
deleted file mode 100644
index c3ea5a8d8..000000000
--- a/libminifi/include/core/logging/LoggerFactory.h
+++ /dev/null
@@ -1,43 +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.
- */
-
-#pragma once
-
-#include <string_view>
-#include <memory>
-
-#include "minifi-cpp/core/logging/LoggerFactory.h"
-#include "core/logging/Logger.h"
-#include "core/Core.h"
-
-namespace org::apache::nifi::minifi::core::logging {
-
-template<typename T>
-class LoggerFactory : public LoggerFactoryBase {
- public:
- static std::shared_ptr<Logger> getLogger() {
- static std::shared_ptr<Logger> logger = getAliasedLogger(core::className<T>());
- return logger;
- }
-
- static std::shared_ptr<Logger> getLogger(const utils::Identifier& uuid) {
- return getAliasedLogger(core::className<T>(), uuid);
- }
-};
-
-} // namespace org::apache::nifi::minifi::core::logging
diff --git a/libminifi/include/core/logging/internal/ActiveCompressor.h b/libminifi/include/core/logging/internal/ActiveCompressor.h
index 045d3e0fb..c4de395b5 100644
--- a/libminifi/include/core/logging/internal/ActiveCompressor.h
+++ b/libminifi/include/core/logging/internal/ActiveCompressor.h
@@ -22,15 +22,9 @@
#include <utility>
#include "LogBuffer.h"
#include "LogCompressor.h"
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace logging {
-namespace internal {
+namespace org::apache::nifi::minifi::core::logging::internal {
class ActiveCompressor {
public:
@@ -63,10 +57,4 @@ class ActiveCompressor {
std::unique_ptr<LogCompressor> compressor_;
};
-} // namespace internal
-} // namespace logging
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::logging::internal
diff --git a/libminifi/include/core/logging/internal/CompressionManager.h b/libminifi/include/core/logging/internal/CompressionManager.h
index b881a5a3f..669480905 100644
--- a/libminifi/include/core/logging/internal/CompressionManager.h
+++ b/libminifi/include/core/logging/internal/CompressionManager.h
@@ -26,11 +26,11 @@
#include <string>
#include <vector>
-#include "core/logging/Logger.h"
+#include "minifi-cpp/core/logging/Logger.h"
#include "LogCompressorSink.h"
#include "core/logging/LoggerProperties.h"
-#include "io/InputStream.h"
-#include "utils/Literals.h"
+#include "minifi-cpp/io/InputStream.h"
+#include "minifi-cpp/utils/Literals.h"
class LoggerTestAccessor;
diff --git a/libminifi/include/core/logging/internal/LogCompressor.h b/libminifi/include/core/logging/internal/LogCompressor.h
index 9bc722ecc..15ace8c06 100644
--- a/libminifi/include/core/logging/internal/LogCompressor.h
... 3023 lines suppressed ...
(nifi-minifi-cpp) 03/04: MINIFICPP-2643 Fix clang tidy issues
Posted by sz...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
szaszm pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/nifi-minifi-cpp.git
commit e8c9a7c426fefc7517899ec52b2502da70ccc7e5
Author: Gabor Gyimesi <ga...@gmail.com>
AuthorDate: Fri Oct 17 17:16:49 2025 +0200
MINIFICPP-2643 Fix clang tidy issues
Closes #2040
Signed-off-by: Marton Szasz <sz...@apache.org>
---
.clang-tidy | 1 -
core-framework/include/core/ClassLoader.h | 2 +-
core-framework/include/core/ObjectFactory.h | 32 ++++++++++-----------
core-framework/include/core/extension/Extension.h | 14 ++-------
core-framework/include/io/BufferStream.h | 12 ++------
core-framework/include/utils/CollectionUtils.h | 12 ++------
core-framework/include/utils/IntervalSwitch.h | 12 ++------
core-framework/include/utils/JsonCallback.h | 12 ++------
core-framework/include/utils/MapUtils.h | 14 ++-------
core-framework/include/utils/StringUtils.h | 6 ++--
core-framework/include/utils/TryMoveCall.h | 12 ++------
.../include/utils/crypto/ciphers/Aes256Ecb.h | 14 ++-------
.../include/utils/requirements/Container.h | 12 ++------
.../utils/requirements/EqualityComparable.h | 12 ++------
.../utils/requirements/LegacyForwardIterator.h | 12 ++------
.../utils/requirements/LegacyInputIterator.h | 12 ++------
.../include/utils/requirements/LegacyIterator.h | 12 ++------
.../include/utils/requirements/Swappable.h | 12 ++------
core-framework/src/utils/FifoExecutor.cpp | 2 +-
.../src/utils/crypto/ciphers/Aes256Ecb.cpp | 4 +--
core-framework/src/utils/net/AsioSocketUtils.cpp | 2 +-
.../src/utils/net/NetworkInterfaceInfo.cpp | 6 ++--
encrypt-config/ConfigFile.h | 13 ++-------
encrypt-config/ConfigFileEncryptor.cpp | 12 ++------
encrypt-config/ConfigFileEncryptor.h | 12 ++------
encrypt-config/Utils.h | 12 ++------
.../include/serialization/FlowFileSerializer.h | 10 ++-----
.../include/serialization/FlowFileV3Serializer.h | 10 ++-----
.../include/serialization/PayloadSerializer.h | 10 ++-----
extension-framework/src/utils/net/TcpServer.cpp | 2 +-
extensions/aws/AWSCredentialsProvider.h | 12 ++------
extensions/aws/utils/AWSInitializer.h | 14 ++-------
.../azure/processors/FetchAzureBlobStorage.cpp | 5 ++--
extensions/expression-language/Driver.h | 12 ++------
extensions/expression-language/Expression.cpp | 5 ++--
extensions/expression-language/Parser.yy | 12 ++------
extensions/pdh/MemoryConsumptionCounter.h | 12 ++------
extensions/pdh/PDHCounters.cpp | 12 ++------
extensions/pdh/PDHCounters.h | 12 ++------
extensions/pdh/PerformanceDataCounter.h | 12 ++------
extensions/pdh/PerformanceDataMonitor.cpp | 12 ++------
extensions/pdh/PerformanceDataMonitor.h | 12 ++------
extensions/procfs/ProcessStat.cpp | 4 +--
extensions/python/PythonBindings.cpp | 4 +--
extensions/rocksdb-repos/ProvenanceRepository.cpp | 1 -
extensions/rocksdb-repos/RocksDbStream.h | 12 ++------
extensions/rocksdb-repos/database/WriteBatch.cpp | 12 ++------
extensions/rocksdb-repos/database/WriteBatch.h | 13 ++-------
extensions/sftp/tests/tools/SFTPTestServer.cpp | 4 +--
extensions/sql/data/SQLRowSubscriber.h | 12 ++------
extensions/systemd/Common.h | 9 ++----
extensions/windows-event-log/TailEventLog.h | 12 ++------
extensions/windows-event-log/wel/JSONUtils.h | 20 ++++---------
extensions/windows-event-log/wel/XMLString.h | 13 ++-------
generateVersion.bat | 10 ++-----
generateVersion.sh | 10 ++-----
libminifi/include/c2/C2Protocol.h | 5 +---
libminifi/include/c2/C2Trigger.h | 5 +---
libminifi/include/c2/HeartbeatReporter.h | 5 +---
libminifi/include/c2/PayloadSerializer.h | 17 ++---------
libminifi/include/c2/protocols/RESTProtocol.h | 5 +---
.../include/controllers/ThreadManagementService.h | 5 +---
libminifi/include/core/extension/Executable.h | 14 ++-------
libminifi/include/core/extension/Module.h | 14 ++-------
.../include/core/logging/WindowsEventLogSink.h | 16 ++---------
.../core/logging/internal/CompressionManager.h | 16 ++---------
.../include/core/logging/internal/LogBuffer.h | 16 ++---------
libminifi/include/core/state/UpdatePolicy.h | 21 ++++----------
libminifi/include/io/AtomicEntryStream.h | 17 ++---------
libminifi/include/io/NetworkPrioritizer.h | 17 ++---------
libminifi/include/properties/Decryptor.h | 10 ++-----
libminifi/include/utils/StagingQueue.h | 12 ++------
libminifi/include/utils/file/FileSystem.h | 14 ++-------
libminifi/include/utils/tls/DistinguishedName.h | 14 ++-------
libminifi/include/utils/tls/TLSUtils.h | 14 ++-------
libminifi/src/c2/HeartbeatJsonSerializer.cpp | 3 +-
libminifi/src/c2/PayloadSerializer.cpp | 12 ++------
.../controllers/UpdatePolicyControllerService.cpp | 2 --
libminifi/src/core/ClassLoader.cpp | 14 ++++-----
libminifi/src/core/ParameterContext.cpp | 2 +-
libminifi/src/core/ProcessGroup.cpp | 2 +-
libminifi/src/core/ProcessSessionFactory.cpp | 12 ++------
libminifi/src/core/flow/CheckRequiredField.cpp | 4 +--
libminifi/src/core/logging/WindowsEventLogSink.cpp | 16 ++---------
.../src/core/logging/internal/LogCompressor.cpp | 17 ++---------
.../src/core/state/nodes/DeviceInformation.cpp | 3 +-
.../src/core/state/nodes/RepositoryMetrics.cpp | 2 +-
libminifi/src/io/AtomicEntryStream.cpp | 33 ----------------------
libminifi/src/utils/tls/DistinguishedName.cpp | 2 +-
.../integration/OnScheduleErrorHandlingTests.cpp | 2 +-
.../integration/ConnectionCountingServer.cpp | 6 ++--
.../libtest/integration/HTTPIntegrationBase.cpp | 4 ++-
libminifi/test/libtest/unit/TestBase.cpp | 2 +-
libminifi/test/libtest/unit/TestBase.h | 2 +-
libminifi/test/libtest/unit/TestUtils.cpp | 2 +-
libminifi/test/libtest/unit/TestUtils.h | 2 +-
libminifi/test/schema-tests/SchemaTests.cpp | 2 +-
libminifi/test/unit/BackTraceTests.cpp | 2 +-
libminifi/test/unit/CertificateUtilsTests.cpp | 2 +-
libminifi/test/unit/CronTests.cpp | 2 ++
libminifi/test/unit/HTTPStreamingCallbackTests.cpp | 2 +-
libminifi/test/unit/IdTests.cpp | 1 +
libminifi/test/unit/MapUtilsTests.cpp | 4 +--
libminifi/test/unit/NetworkInterfaceInfoTests.cpp | 2 +-
libminifi/test/unit/RegexUtilsTests.cpp | 1 -
libminifi/test/unit/SiteToSiteTests.cpp | 5 ++--
libminifi/test/unit/StringUtilsTests.cpp | 20 ++++++-------
libminifi/test/unit/TimeUtilTests.cpp | 6 ++--
.../minifi-cpp/core/AgentIdentificationProvider.h | 12 ++------
minifi-api/include/minifi-cpp/core/Annotation.h | 14 ++-------
minifi-api/include/minifi-cpp/core/ClassLoader.h | 4 +--
minifi-api/include/minifi-cpp/core/ObjectFactory.h | 4 +--
.../include/minifi-cpp/core/TraceableResource.h | 12 ++------
minifi-api/include/minifi-cpp/io/OutputStream.h | 12 ++------
114 files changed, 235 insertions(+), 831 deletions(-)
diff --git a/.clang-tidy b/.clang-tidy
index 3e7311914..9349f5989 100644
--- a/.clang-tidy
+++ b/.clang-tidy
@@ -244,7 +244,6 @@ Checks: >
modernize-use-starts-ends-with,
modernize-use-std-format,
modernize-use-std-numbers,
- modernize-use-std-print,
performance-noexcept-destructor,
performance-noexcept-swap,
readability-ambiguous-smartptr-reset-call,
diff --git a/core-framework/include/core/ClassLoader.h b/core-framework/include/core/ClassLoader.h
index 1f1cb70a1..7786502be 100644
--- a/core-framework/include/core/ClassLoader.h
+++ b/core-framework/include/core/ClassLoader.h
@@ -37,7 +37,7 @@ std::unique_ptr<T> ClassLoader::instantiate(const std::string &class_name, const
}
template<class T>
-T *ClassLoader::instantiateRaw(const std::string &class_name, const std::string &name) {
+gsl::owner<T*> ClassLoader::instantiateRaw(const std::string &class_name, const std::string &name) {
return dynamic_cast<T*>(instantiateRaw(class_name, name, [] (CoreComponent* obj) -> bool {
return dynamic_cast<T*>(obj) != nullptr;
}));
diff --git a/core-framework/include/core/ObjectFactory.h b/core-framework/include/core/ObjectFactory.h
index 434caee9e..e321a6a1e 100644
--- a/core-framework/include/core/ObjectFactory.h
+++ b/core-framework/include/core/ObjectFactory.h
@@ -23,11 +23,7 @@
#include "ClassName.h"
#include "minifi-cpp/core/ObjectFactory.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
+namespace org::apache::nifi::minifi::core {
class ObjectFactoryImpl : public ObjectFactory {
public:
@@ -76,17 +72,25 @@ class DefaultObjectFactory : public ObjectFactoryImpl {
/**
* Create a raw pointer to a new processor.
*/
- CoreComponent* createRaw(const std::string &name) override {
- T *ptr = new T(name);
- return dynamic_cast<CoreComponent*>(ptr);
+ gsl::owner<CoreComponent*> createRaw(const std::string &name) override {
+ const gsl::owner<T*> ptr = new T(name);
+ if (const auto converted = dynamic_cast<CoreComponent*>(ptr)) {
+ return converted;
+ }
+ delete ptr;
+ return nullptr;
}
/**
* Create a raw pointer to a new processor.
*/
- CoreComponent* createRaw(const std::string &name, const utils::Identifier &uuid) override {
- T *ptr = new T(name, uuid);
- return dynamic_cast<CoreComponent*>(ptr);
+ gsl::owner<CoreComponent*> createRaw(const std::string &name, const utils::Identifier &uuid) override {
+ const gsl::owner<T*> ptr = new T(name, uuid);
+ if (const auto converted = dynamic_cast<CoreComponent*>(ptr)) {
+ return converted;
+ }
+ delete ptr;
+ return nullptr;
}
/**
@@ -101,8 +105,4 @@ class DefaultObjectFactory : public ObjectFactoryImpl {
std::string className;
};
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core
diff --git a/core-framework/include/core/extension/Extension.h b/core-framework/include/core/extension/Extension.h
index 55ee26b3d..73d437685 100644
--- a/core-framework/include/core/extension/Extension.h
+++ b/core-framework/include/core/extension/Extension.h
@@ -23,12 +23,7 @@
#include "minifi-cpp/core/extension/Extension.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace extension {
+namespace org::apache::nifi::minifi::core::extension {
class ExtensionImpl;
@@ -96,9 +91,4 @@ class ExtensionInitializer {
} \
})
-} // namespace extension
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::extension
diff --git a/core-framework/include/io/BufferStream.h b/core-framework/include/io/BufferStream.h
index 340e7a9a0..dcddc9425 100644
--- a/core-framework/include/io/BufferStream.h
+++ b/core-framework/include/io/BufferStream.h
@@ -25,11 +25,7 @@
#include "BaseStream.h"
#include "minifi-cpp/utils/gsl.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace io {
+namespace org::apache::nifi::minifi::io {
class BufferStream : public BaseStreamImpl {
public:
@@ -100,8 +96,4 @@ class BufferStream : public BaseStreamImpl {
uint64_t readOffset_ = 0;
};
-} // namespace io
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::io
diff --git a/core-framework/include/utils/CollectionUtils.h b/core-framework/include/utils/CollectionUtils.h
index 46b3f4f83..74957ff2f 100644
--- a/core-framework/include/utils/CollectionUtils.h
+++ b/core-framework/include/utils/CollectionUtils.h
@@ -20,11 +20,7 @@
#include <algorithm>
#include <utility>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
namespace internal {
@@ -52,8 +48,4 @@ bool haveCommonItem(const T& a, const U& b) {
});
}
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/IntervalSwitch.h b/core-framework/include/utils/IntervalSwitch.h
index a776feb23..4931f4e44 100644
--- a/core-framework/include/utils/IntervalSwitch.h
+++ b/core-framework/include/utils/IntervalSwitch.h
@@ -23,11 +23,7 @@
#include "minifi-cpp/utils/gsl.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
enum class IntervalSwitchState {
LOWER,
@@ -67,8 +63,4 @@ class IntervalSwitch {
IntervalSwitchState state_;
};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/JsonCallback.h b/core-framework/include/utils/JsonCallback.h
index c455e6c34..37d922bd5 100644
--- a/core-framework/include/utils/JsonCallback.h
+++ b/core-framework/include/utils/JsonCallback.h
@@ -27,11 +27,7 @@
#include "io/StreamPipe.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
class JsonInputCallback {
public:
@@ -93,8 +89,4 @@ class PrettyJsonOutputCallback {
std::optional<uint8_t> decimal_places_;
};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/MapUtils.h b/core-framework/include/utils/MapUtils.h
index 55011d78d..50d5f5efd 100644
--- a/core-framework/include/utils/MapUtils.h
+++ b/core-framework/include/utils/MapUtils.h
@@ -18,12 +18,7 @@
#include <set>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
-namespace MapUtils {
+namespace org::apache::nifi::minifi::utils::MapUtils {
/**
* Return a set of keys from a map
@@ -37,9 +32,4 @@ std::set<T> getKeys(const Map<T, U>& m) {
return keys;
}
-} /* namespace MapUtils */
-} /* namespace utils */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::utils::MapUtils
diff --git a/core-framework/include/utils/StringUtils.h b/core-framework/include/utils/StringUtils.h
index 8929f1123..30b2a1495 100644
--- a/core-framework/include/utils/StringUtils.h
+++ b/core-framework/include/utils/StringUtils.h
@@ -386,13 +386,13 @@ inline std::string to_base64(std::string_view str, bool url = false, bool padded
std::string replaceMap(std::string source_string, const std::map<std::string, std::string> &replace_map);
-constexpr std::pair<size_t, int> countOccurrences(std::string_view str, std::string_view pattern) {
+constexpr std::pair<size_t, size_t> countOccurrences(std::string_view str, std::string_view pattern) {
if (pattern.empty()) {
- return {str.size(), gsl::narrow<int>(str.size() + 1)};
+ return {str.size(), str.size() + 1};
}
size_t last_pos = 0;
- int occurrences = 0;
+ size_t occurrences = 0;
for (size_t pos = 0; (pos = str.find(pattern, pos)) != std::string_view::npos; pos += pattern.size()) {
last_pos = pos;
++occurrences;
diff --git a/core-framework/include/utils/TryMoveCall.h b/core-framework/include/utils/TryMoveCall.h
index 7f5a596a4..a430375d7 100644
--- a/core-framework/include/utils/TryMoveCall.h
+++ b/core-framework/include/utils/TryMoveCall.h
@@ -19,11 +19,7 @@
#include <type_traits>
#include <utility>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
// TryMoveCall calls an
// - unary function of a lvalue reference-type argument by passing a ref
@@ -53,8 +49,4 @@ struct TryMoveCall<FunType, T, std::void_t<decltype(std::declval<FunType>()(std:
template<typename Fun>
static auto call(Fun&& fun, T& elem) -> decltype(std::forward<Fun>(fun)(std::move(elem))) { return std::forward<Fun>(fun)(std::move(elem)); }
};
-} /* namespace utils */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/crypto/ciphers/Aes256Ecb.h b/core-framework/include/utils/crypto/ciphers/Aes256Ecb.h
index c45f1f37d..427c84cb4 100644
--- a/core-framework/include/utils/crypto/ciphers/Aes256Ecb.h
+++ b/core-framework/include/utils/crypto/ciphers/Aes256Ecb.h
@@ -25,12 +25,7 @@
#include "minifi-cpp/Exception.h"
#include "minifi-cpp/core/logging/Logger.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
-namespace crypto {
+namespace org::apache::nifi::minifi::utils::crypto {
class CipherError : public Exception {
public:
@@ -68,9 +63,4 @@ class Aes256EcbCipher {
const Bytes encryption_key_;
};
-} // namespace crypto
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils::crypto
diff --git a/core-framework/include/utils/requirements/Container.h b/core-framework/include/utils/requirements/Container.h
index 62b7aeba5..59460f63a 100644
--- a/core-framework/include/utils/requirements/Container.h
+++ b/core-framework/include/utils/requirements/Container.h
@@ -24,11 +24,7 @@
#include "LegacyForwardIterator.h"
#include "EqualityComparable.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
template<typename T>
struct assert_container :
@@ -70,8 +66,4 @@ struct assert_container :
static_assert(std::is_convertible<decltype(std::declval<T&>().empty()), bool>::value, "");
};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/requirements/EqualityComparable.h b/core-framework/include/utils/requirements/EqualityComparable.h
index 8c41800d1..431622732 100644
--- a/core-framework/include/utils/requirements/EqualityComparable.h
+++ b/core-framework/include/utils/requirements/EqualityComparable.h
@@ -20,11 +20,7 @@
#include <type_traits>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
template<typename T, typename = void>
struct is_equality_comparable : std::false_type {};
@@ -35,8 +31,4 @@ struct is_equality_comparable<T,
std::is_convertible<decltype(std::declval<const T>() == std::declval<const T>()), bool>::value
>::type> : std::true_type {};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/requirements/LegacyForwardIterator.h b/core-framework/include/utils/requirements/LegacyForwardIterator.h
index 389ce33c9..2a90b3ea4 100644
--- a/core-framework/include/utils/requirements/LegacyForwardIterator.h
+++ b/core-framework/include/utils/requirements/LegacyForwardIterator.h
@@ -21,11 +21,7 @@
#include <iterator>
#include "LegacyInputIterator.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
template<typename T>
struct assert_legacy_forward_iterator : assert_legacy_input_iterator<T> {
@@ -39,8 +35,4 @@ struct assert_legacy_forward_iterator : assert_legacy_input_iterator<T> {
static_assert(std::is_same<decltype(*std::declval<T>()++), typename std::iterator_traits<T>::reference>::value, "Expected a reference");
};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/requirements/LegacyInputIterator.h b/core-framework/include/utils/requirements/LegacyInputIterator.h
index d5a067574..2ede77b3a 100644
--- a/core-framework/include/utils/requirements/LegacyInputIterator.h
+++ b/core-framework/include/utils/requirements/LegacyInputIterator.h
@@ -23,11 +23,7 @@
#include "LegacyIterator.h"
#include "EqualityComparable.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
template<typename T>
struct assert_legacy_input_iterator : assert_legacy_iterator<T> {
@@ -41,8 +37,4 @@ struct assert_legacy_input_iterator : assert_legacy_iterator<T> {
using _ = decltype(true || (std::declval<const T>() != std::declval<const T>()));
};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/requirements/LegacyIterator.h b/core-framework/include/utils/requirements/LegacyIterator.h
index fea38bb3b..bb55b016b 100644
--- a/core-framework/include/utils/requirements/LegacyIterator.h
+++ b/core-framework/include/utils/requirements/LegacyIterator.h
@@ -24,11 +24,7 @@
#include "utils/GeneralUtils.h"
#include "Swappable.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
namespace detail {
@@ -66,8 +62,4 @@ struct assert_legacy_iterator {
using iterator_category = typename std::iterator_traits<T>::iterator_category;
};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/include/utils/requirements/Swappable.h b/core-framework/include/utils/requirements/Swappable.h
index 9369004eb..b291b2f28 100644
--- a/core-framework/include/utils/requirements/Swappable.h
+++ b/core-framework/include/utils/requirements/Swappable.h
@@ -21,11 +21,7 @@
#include <utility>
#include "utils/GeneralUtils.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
namespace detail {
@@ -73,8 +69,4 @@ struct is_swappable<T,
detail::is_referenceable<T>::value
>::type> : is_swappable_with<T&, T&> {};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/core-framework/src/utils/FifoExecutor.cpp b/core-framework/src/utils/FifoExecutor.cpp
index f7bf0a807..0d485902f 100644
--- a/core-framework/src/utils/FifoExecutor.cpp
+++ b/core-framework/src/utils/FifoExecutor.cpp
@@ -28,7 +28,7 @@ WorkerThread::~WorkerThread() {
void WorkerThread::run() noexcept {
while (task_queue_.isRunning()) {
- task_queue_.consumeWait([](std::packaged_task<void()>&& f) { f(); });
+ task_queue_.consumeWait([](std::packaged_task<void()>& f) { f(); });
}
}
} // namespace org::apache::nifi::minifi::utils::detail
diff --git a/core-framework/src/utils/crypto/ciphers/Aes256Ecb.cpp b/core-framework/src/utils/crypto/ciphers/Aes256Ecb.cpp
index d7fc0425e..3daf0a4c8 100644
--- a/core-framework/src/utils/crypto/ciphers/Aes256Ecb.cpp
+++ b/core-framework/src/utils/crypto/ciphers/Aes256Ecb.cpp
@@ -79,7 +79,7 @@ void Aes256EcbCipher::encrypt(std::span<unsigned char, BLOCK_SIZE> data) const {
}
ciphertext_len += len;
- gsl_Expects(ciphertext_len == BLOCK_SIZE);
+ gsl_Expects(gsl::narrow<size_t>(ciphertext_len) == BLOCK_SIZE);
}
void Aes256EcbCipher::decrypt(std::span<unsigned char, BLOCK_SIZE> data) const {
@@ -111,7 +111,7 @@ void Aes256EcbCipher::decrypt(std::span<unsigned char, BLOCK_SIZE> data) const {
}
plaintext_len += len;
- gsl_Expects(plaintext_len == BLOCK_SIZE);
+ gsl_Expects(gsl::narrow<size_t>(plaintext_len) == BLOCK_SIZE);
}
bool Aes256EcbCipher::operator==(const Aes256EcbCipher &other) const {
diff --git a/core-framework/src/utils/net/AsioSocketUtils.cpp b/core-framework/src/utils/net/AsioSocketUtils.cpp
index 36e7fd0af..2d3934d8e 100644
--- a/core-framework/src/utils/net/AsioSocketUtils.cpp
+++ b/core-framework/src/utils/net/AsioSocketUtils.cpp
@@ -81,7 +81,7 @@ bool AsioSocketConnection::connectTcpSocketOverSsl() {
logger_->log_error("Connecting to host '{}' on port '{}' failed with the following message: '{}'", socket_data_.host, socket_data_.port, err.message());
return false;
}
- socket.handshake(asio::ssl::stream_base::client, err);
+ std::ignore = socket.handshake(asio::ssl::stream_base::client, err);
if (err) {
logger_->log_error("SSL handshake failed while connecting to host '{}' on port '{}' with the following message: '{}'", socket_data_.host, socket_data_.port, err.message());
return false;
diff --git a/core-framework/src/utils/net/NetworkInterfaceInfo.cpp b/core-framework/src/utils/net/NetworkInterfaceInfo.cpp
index bc1c1d0b1..f9295672e 100644
--- a/core-framework/src/utils/net/NetworkInterfaceInfo.cpp
+++ b/core-framework/src/utils/net/NetworkInterfaceInfo.cpp
@@ -131,7 +131,7 @@ std::vector<NetworkInterfaceInfo> NetworkInterfaceInfo::getNetworkInterfaceInfos
}
namespace {
-void move_append(std::vector<std::string> &&source, std::vector<std::string> &destination) {
+void move_append(std::vector<std::string>& source, std::vector<std::string>& destination) {
destination.reserve(destination.size() + source.size());
std::move(std::begin(source), std::end(source), std::back_inserter(destination));
source.clear();
@@ -139,8 +139,8 @@ void move_append(std::vector<std::string> &&source, std::vector<std::string> &de
} // namespace
void NetworkInterfaceInfo::moveAddressesInto(NetworkInterfaceInfo& destination) {
- move_append(std::move(ip_v4_addresses_), destination.ip_v4_addresses_);
- move_append(std::move(ip_v6_addresses_), destination.ip_v6_addresses_);
+ move_append(ip_v4_addresses_, destination.ip_v4_addresses_);
+ move_append(ip_v6_addresses_, destination.ip_v6_addresses_);
}
} // namespace org::apache::nifi::minifi::utils
diff --git a/encrypt-config/ConfigFile.h b/encrypt-config/ConfigFile.h
index 634c9a89c..56079c9ff 100644
--- a/encrypt-config/ConfigFile.h
+++ b/encrypt-config/ConfigFile.h
@@ -22,11 +22,7 @@
#include "utils/crypto/EncryptionUtils.h"
#include "properties/PropertiesFile.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace encrypt_config {
+namespace org::apache::nifi::minifi::encrypt_config {
class ConfigFile : public PropertiesFile {
public:
@@ -38,9 +34,4 @@ class ConfigFile : public PropertiesFile {
friend bool operator==(const ConfigFile&, const ConfigFile&);
};
-} // namespace encrypt_config
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
-
+} // namespace org::apache::nifi::minifi::encrypt_config
diff --git a/encrypt-config/ConfigFileEncryptor.cpp b/encrypt-config/ConfigFileEncryptor.cpp
index 4e8d287f5..c5eacbbe9 100644
--- a/encrypt-config/ConfigFileEncryptor.cpp
+++ b/encrypt-config/ConfigFileEncryptor.cpp
@@ -23,11 +23,7 @@
#include "utils/StringUtils.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace encrypt_config {
+namespace org::apache::nifi::minifi::encrypt_config {
bool isEncrypted(const std::optional<std::string>& encryption_type) {
return encryption_type && !encryption_type->empty() && *encryption_type != "plaintext";
@@ -82,8 +78,4 @@ uint32_t encryptSensitivePropertiesInFile(ConfigFile& config_file, const Encrypt
return num_properties_encrypted;
}
-} // namespace encrypt_config
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::encrypt_config
diff --git a/encrypt-config/ConfigFileEncryptor.h b/encrypt-config/ConfigFileEncryptor.h
index aecd42f68..04941a4d2 100644
--- a/encrypt-config/ConfigFileEncryptor.h
+++ b/encrypt-config/ConfigFileEncryptor.h
@@ -20,18 +20,10 @@
#include "utils/crypto/EncryptionUtils.h"
#include "Utils.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace encrypt_config {
+namespace org::apache::nifi::minifi::encrypt_config {
uint32_t encryptSensitivePropertiesInFile(ConfigFile& config_file, const utils::crypto::Bytes& encryption_key);
uint32_t encryptSensitivePropertiesInFile(ConfigFile& config_file, const EncryptionKeys& keys);
-} // namespace encrypt_config
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::encrypt_config
diff --git a/encrypt-config/Utils.h b/encrypt-config/Utils.h
index fd645e2af..e4609af03 100644
--- a/encrypt-config/Utils.h
+++ b/encrypt-config/Utils.h
@@ -20,19 +20,11 @@
#include "utils/crypto/EncryptionUtils.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace encrypt_config {
+namespace org::apache::nifi::minifi::encrypt_config {
struct EncryptionKeys {
std::optional<utils::crypto::Bytes> old_key;
utils::crypto::Bytes encryption_key;
};
-} // namespace encrypt_config
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::encrypt_config
diff --git a/extension-framework/include/serialization/FlowFileSerializer.h b/extension-framework/include/serialization/FlowFileSerializer.h
index e8a612799..85362931f 100644
--- a/extension-framework/include/serialization/FlowFileSerializer.h
+++ b/extension-framework/include/serialization/FlowFileSerializer.h
@@ -23,10 +23,7 @@
#include <functional>
#include "minifi-cpp/io/StreamCallback.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
+namespace org::apache::nifi::minifi {
namespace io {
class OutputStream;
@@ -53,7 +50,4 @@ class FlowFileSerializer {
FlowFileReader reader_;
};
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi
diff --git a/extension-framework/include/serialization/FlowFileV3Serializer.h b/extension-framework/include/serialization/FlowFileV3Serializer.h
index 656422a89..64c9ce691 100644
--- a/extension-framework/include/serialization/FlowFileV3Serializer.h
+++ b/extension-framework/include/serialization/FlowFileV3Serializer.h
@@ -24,10 +24,7 @@
#include "io/OutputStream.h"
#include "FlowFileSerializer.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
+namespace org::apache::nifi::minifi {
class FlowFileV3Serializer : public FlowFileSerializer {
static constexpr uint8_t MAGIC_HEADER[] = {'N', 'i', 'F', 'i', 'F', 'F', '3'};
@@ -44,7 +41,4 @@ class FlowFileV3Serializer : public FlowFileSerializer {
int64_t serialize(const std::shared_ptr<core::FlowFile>& flowFile, const std::shared_ptr<io::OutputStream>& out) override;
};
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi
diff --git a/extension-framework/include/serialization/PayloadSerializer.h b/extension-framework/include/serialization/PayloadSerializer.h
index e1089a7e8..b6f843ca5 100644
--- a/extension-framework/include/serialization/PayloadSerializer.h
+++ b/extension-framework/include/serialization/PayloadSerializer.h
@@ -22,10 +22,7 @@
#include "minifi-cpp/io/OutputStream.h"
#include "FlowFileSerializer.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
+namespace org::apache::nifi::minifi {
class PayloadSerializer : public FlowFileSerializer {
public:
@@ -34,7 +31,4 @@ class PayloadSerializer : public FlowFileSerializer {
int64_t serialize(const std::shared_ptr<core::FlowFile>& flowFile, const std::shared_ptr<io::OutputStream>& out) override;
};
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi
diff --git a/extension-framework/src/utils/net/TcpServer.cpp b/extension-framework/src/utils/net/TcpServer.cpp
index 651c55ed8..1c51fa265 100644
--- a/extension-framework/src/utils/net/TcpServer.cpp
+++ b/extension-framework/src/utils/net/TcpServer.cpp
@@ -107,7 +107,7 @@ asio::awaitable<void> TcpServer::secureSession(asio::ip::tcp::socket socket, asi
co_await readLoop(ssl_socket, remote_address, local_port); // NOLINT
asio::error_code ec;
- ssl_socket.lowest_layer().cancel(ec);
+ std::ignore = ssl_socket.lowest_layer().cancel(ec);
if (ec) {
logger_->log_error("Cancelling asynchronous operations of SSL socket failed with: {}", ec.message());
}
diff --git a/extensions/aws/AWSCredentialsProvider.h b/extensions/aws/AWSCredentialsProvider.h
index 302a8407d..9dcafcc37 100644
--- a/extensions/aws/AWSCredentialsProvider.h
+++ b/extensions/aws/AWSCredentialsProvider.h
@@ -27,11 +27,7 @@
#include "minifi-cpp/core/logging/Logger.h"
#include "core/logging/LoggerFactory.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace aws {
+namespace org::apache::nifi::minifi::aws {
class AWSCredentialsProvider {
public:
@@ -56,8 +52,4 @@ class AWSCredentialsProvider {
std::shared_ptr<core::logging::Logger> logger_{core::logging::LoggerFactory<AWSCredentialsProvider>::getLogger()};
};
-} // namespace aws
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::aws
diff --git a/extensions/aws/utils/AWSInitializer.h b/extensions/aws/utils/AWSInitializer.h
index 34b3f2f38..dc0aab0e3 100755
--- a/extensions/aws/utils/AWSInitializer.h
+++ b/extensions/aws/utils/AWSInitializer.h
@@ -32,12 +32,7 @@
#undef GetObject // windows.h #defines GetObject = GetObjectA or GetObjectW, which conflicts with rapidjson
#endif
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace aws {
-namespace utils {
+namespace org::apache::nifi::minifi::aws::utils {
class AWSInitializer {
public:
@@ -50,9 +45,4 @@ class AWSInitializer {
Aws::SDKOptions options_;
};
-} /* namespace utils */
-} /* namespace aws */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::aws::utils
diff --git a/extensions/azure/processors/FetchAzureBlobStorage.cpp b/extensions/azure/processors/FetchAzureBlobStorage.cpp
index fa0a065f2..b96da5b5c 100644
--- a/extensions/azure/processors/FetchAzureBlobStorage.cpp
+++ b/extensions/azure/processors/FetchAzureBlobStorage.cpp
@@ -39,14 +39,13 @@ std::optional<storage::FetchAzureBlobStorageParameters> FetchAzureBlobStorage::b
return std::nullopt;
}
- std::string value;
if (auto range_start = utils::parseOptionalU64Property(context, RangeStart, &flow_file)) {
- params.range_start = *range_start;
+ params.range_start = range_start;
logger_->log_debug("Range Start property set to {}", *params.range_start);
}
if (auto range_length = utils::parseOptionalU64Property(context, RangeLength, &flow_file)) {
- params.range_length = *range_length;
+ params.range_length = range_length;
logger_->log_debug("Range Length property set to {}", *params.range_length);
}
diff --git a/extensions/expression-language/Driver.h b/extensions/expression-language/Driver.h
index c04d78c41..6d511dd7e 100644
--- a/extensions/expression-language/Driver.h
+++ b/extensions/expression-language/Driver.h
@@ -29,11 +29,7 @@
#define YY_DECL int org::apache::nifi::minifi::expression::Driver::lex(org::apache::nifi::minifi::expression::Parser::semantic_type* yylval, \
org::apache::nifi::minifi::expression::Parser::location_type* yylloc)
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace expression {
+namespace org::apache::nifi::minifi::expression {
class Driver : public yyFlexLexer {
public:
@@ -50,8 +46,4 @@ class Driver : public yyFlexLexer {
Expression result;
};
-} /* namespace expression */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::expression
diff --git a/extensions/expression-language/Expression.cpp b/extensions/expression-language/Expression.cpp
index cb3d03de3..7a6cc8308 100644
--- a/extensions/expression-language/Expression.cpp
+++ b/extensions/expression-language/Expression.cpp
@@ -387,13 +387,13 @@ Value expr_getDelimitedField(const std::vector<Value> &args) {
Value expr_startsWith(const std::vector<Value> &args) {
const std::string &arg_0 = args[0].asString();
const std::string &arg_1 = args[1].asString();
- return Value(arg_0.substr(0, arg_1.length()) == arg_1);
+ return Value(arg_0.starts_with(arg_1));
}
Value expr_endsWith(const std::vector<Value> &args) {
const std::string &arg_0 = args[0].asString();
const std::string &arg_1 = args[1].asString();
- return Value(arg_0.substr(arg_0.length() - arg_1.length()) == arg_1);
+ return Value(arg_0.ends_with(arg_1));
}
Value expr_contains(const std::vector<Value> &args) {
@@ -633,7 +633,6 @@ Value expr_format(const std::vector<Value> &args) {
using std::chrono::milliseconds;
date::sys_time<milliseconds> utc_time_point{milliseconds(args[0].asUnsignedLong())};
- auto format_string = args[1].asString();
auto zone = args.size() > 2 ? date::locate_zone(args[2].asString()) : date::current_zone();
auto zoned_time_point = date::make_zoned(zone, utc_time_point);
diff --git a/extensions/expression-language/Parser.yy b/extensions/expression-language/Parser.yy
index 3a1f4d67a..17b98200f 100644
--- a/extensions/expression-language/Parser.yy
+++ b/extensions/expression-language/Parser.yy
@@ -38,17 +38,9 @@
#undef S_FALSE // winerror.h #defines S_FALSE, which conflicts with the generated token
#endif
- namespace org {
- namespace apache {
- namespace nifi {
- namespace minifi {
- namespace expression {
+ namespace org::apache::nifi::minifi::expression {
class Driver;
- } /* namespace expression */
- } /* namespace minifi */
- } /* namespace nifi */
- } /* namespace apache */
- } /* namespace org */
+ } // namespace org::apache::nifi::minifi::expression
}
%code
diff --git a/extensions/pdh/MemoryConsumptionCounter.h b/extensions/pdh/MemoryConsumptionCounter.h
index f04fbccb0..93c60d353 100644
--- a/extensions/pdh/MemoryConsumptionCounter.h
+++ b/extensions/pdh/MemoryConsumptionCounter.h
@@ -21,11 +21,7 @@
#include <string>
#include "utils/OsUtils.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace processors {
+namespace org::apache::nifi::minifi::processors {
class MemoryConsumptionCounter : public PerformanceDataCounter {
public:
@@ -63,8 +59,4 @@ class MemoryConsumptionCounter : public PerformanceDataCounter {
int64_t available_physical_memory_;
int64_t total_paging_file_size_;
};
-} // namespace processors
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::processors
diff --git a/extensions/pdh/PDHCounters.cpp b/extensions/pdh/PDHCounters.cpp
index 34fbfe7a3..e83e11ad0 100644
--- a/extensions/pdh/PDHCounters.cpp
+++ b/extensions/pdh/PDHCounters.cpp
@@ -19,11 +19,7 @@
#include "PDHCounters.h"
#include "utils/StringUtils.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace processors {
+namespace org::apache::nifi::minifi::processors {
DWORD PDHCounter::getDWFormat() const {
return is_double_format_ ? PDH_FMT_DOUBLE : PDH_FMT_LARGE;
@@ -125,8 +121,4 @@ rapidjson::Value PDHCounterArray::getValue(const DWORD i) const {
return value;
}
-} // namespace processors
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::processors
diff --git a/extensions/pdh/PDHCounters.h b/extensions/pdh/PDHCounters.h
index 2a0d3e72a..26a8e6545 100644
--- a/extensions/pdh/PDHCounters.h
+++ b/extensions/pdh/PDHCounters.h
@@ -25,11 +25,7 @@
#include "PerformanceDataCounter.h"
#include <memory>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace processors {
+namespace org::apache::nifi::minifi::processors {
class PDHCounter : public PerformanceDataCounter {
public:
@@ -92,8 +88,4 @@ class PDHCounterArray : public PDHCounter {
};
-} // namespace processors
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::processors
diff --git a/extensions/pdh/PerformanceDataCounter.h b/extensions/pdh/PerformanceDataCounter.h
index 8962451e9..841d51285 100644
--- a/extensions/pdh/PerformanceDataCounter.h
+++ b/extensions/pdh/PerformanceDataCounter.h
@@ -20,11 +20,7 @@
#include "rapidjson/document.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace processors {
+namespace org::apache::nifi::minifi::processors {
class PerformanceDataCounter {
public:
@@ -45,8 +41,4 @@ class PerformanceDataCounter {
}
};
-} // namespace processors
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::processors
diff --git a/extensions/pdh/PerformanceDataMonitor.cpp b/extensions/pdh/PerformanceDataMonitor.cpp
index 6f8055a41..0b57a6067 100644
--- a/extensions/pdh/PerformanceDataMonitor.cpp
+++ b/extensions/pdh/PerformanceDataMonitor.cpp
@@ -28,11 +28,7 @@
#include "core/ProcessSession.h"
#include "core/Resource.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace processors {
+namespace org::apache::nifi::minifi::processors {
PerformanceDataMonitor::~PerformanceDataMonitor() {
PdhCloseQuery(pdh_query_);
@@ -297,8 +293,4 @@ void PerformanceDataMonitor::setupMembersFromProperties(core::ProcessContext& co
REGISTER_RESOURCE(PerformanceDataMonitor, Processor);
-} // namespace processors
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::processors
diff --git a/extensions/pdh/PerformanceDataMonitor.h b/extensions/pdh/PerformanceDataMonitor.h
index 274d4a977..9c3b082e7 100644
--- a/extensions/pdh/PerformanceDataMonitor.h
+++ b/extensions/pdh/PerformanceDataMonitor.h
@@ -36,11 +36,7 @@
#include "PerformanceDataCounter.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace processors {
+namespace org::apache::nifi::minifi::processors {
class PerformanceDataMonitor final : public core::ProcessorImpl {
public:
@@ -128,8 +124,4 @@ class PerformanceDataMonitor final : public core::ProcessorImpl {
std::vector<std::unique_ptr<PerformanceDataCounter>> resource_consumption_counters_;
};
-} // namespace processors
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::processors
diff --git a/extensions/procfs/ProcessStat.cpp b/extensions/procfs/ProcessStat.cpp
index 900c92c3c..2f9c72941 100644
--- a/extensions/procfs/ProcessStat.cpp
+++ b/extensions/procfs/ProcessStat.cpp
@@ -34,8 +34,8 @@ std::optional<ProcessStatData> ProcessStatData::parseProcessStatFile(std::istrea
size_t comm_end = stat_stream_string.find_last_of(')');
if (comm_start == std::string::npos || comm_end == std::string::npos)
return std::nullopt;
- process_stat_data.comm_ = stat_stream_string.substr(comm_start+1, comm_end-comm_start-1);
- stat_stream.seekg(comm_end+2); // seek to the start of the next field (after the space that follows (<comm>))
+ process_stat_data.comm_ = stat_stream_string.substr(comm_start + 1, comm_end-comm_start - 1);
+ stat_stream.seekg(gsl::narrow<std::streampos>(comm_end + 2)); // seek to the start of the next field (after the space that follows (<comm>))
stat_stream >> process_stat_data.state_ >> process_stat_data.ppid_ >> process_stat_data.pgrp_ >> process_stat_data.session_ >> process_stat_data.tty_nr_ >> process_stat_data.tpgid_
>> process_stat_data.flags_ >> process_stat_data.minflt_ >> process_stat_data.cminflt_ >> process_stat_data.majflt_ >> process_stat_data.cmajflt_ >> process_stat_data.utime_
diff --git a/extensions/python/PythonBindings.cpp b/extensions/python/PythonBindings.cpp
index 873188faf..8895c4a94 100644
--- a/extensions/python/PythonBindings.cpp
+++ b/extensions/python/PythonBindings.cpp
@@ -54,7 +54,7 @@ struct PyModuleDef minifi_module = {
PyMODINIT_FUNC
PyInit_minifi_native(void) {
- const std::array types = std::to_array<std::pair<PyTypeObject*, std::string_view>>({
+ const std::array types = std::to_array<std::pair<PyTypeObject*, std::string>>({
std::make_pair(PyLogger::typeObject(), "Logger"),
std::make_pair(PyProcessSessionObject::typeObject(), "ProcessSession"),
std::make_pair(PyProcessContext::typeObject(), "ProcessContext"),
@@ -83,7 +83,7 @@ PyInit_minifi_native(void) {
for (const auto& type : types) {
Py_INCREF(type.first);
}
- const auto result = std::all_of(std::begin(types), std::end(types), [&](std::pair<PyTypeObject*, std::string_view> type) {
+ const auto result = std::all_of(std::begin(types), std::end(types), [&](const std::pair<PyTypeObject*, std::string>& type) {
return PyModule_AddObject(minifi_module_instance, type.second.data(), reinterpret_cast<PyObject*>(type.first)) == 0;
});
diff --git a/extensions/rocksdb-repos/ProvenanceRepository.cpp b/extensions/rocksdb-repos/ProvenanceRepository.cpp
index 9b5571fc0..bd4ae8260 100644
--- a/extensions/rocksdb-repos/ProvenanceRepository.cpp
+++ b/extensions/rocksdb-repos/ProvenanceRepository.cpp
@@ -87,7 +87,6 @@ bool ProvenanceRepository::getElements(std::vector<std::shared_ptr<core::Seriali
if (max_size >= requested_batch)
break;
auto eventRead = ProvenanceEventRecord::create();
- std::string key = it->key().ToString();
io::BufferStream stream(gsl::make_span(it->value()).as_span<const std::byte>());
if (eventRead->deserialize(stream)) {
max_size++;
diff --git a/extensions/rocksdb-repos/RocksDbStream.h b/extensions/rocksdb-repos/RocksDbStream.h
index 1076f0b51..d5c52b024 100644
--- a/extensions/rocksdb-repos/RocksDbStream.h
+++ b/extensions/rocksdb-repos/RocksDbStream.h
@@ -25,11 +25,7 @@
#include "io/BaseStream.h"
#include "core/logging/LoggerFactory.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace io {
+namespace org::apache::nifi::minifi::io {
/**
* Purpose: File Stream Base stream extension. This is intended to be a thread safe access to
@@ -96,8 +92,4 @@ class RocksDbStream : public io::BaseStreamImpl {
std::shared_ptr<core::logging::Logger> logger_ = core::logging::LoggerFactory<RocksDbStream>::getLogger();
};
-} /* namespace io */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::io
diff --git a/extensions/rocksdb-repos/database/WriteBatch.cpp b/extensions/rocksdb-repos/database/WriteBatch.cpp
index 785edb1b9..3fe1dd3ad 100644
--- a/extensions/rocksdb-repos/database/WriteBatch.cpp
+++ b/extensions/rocksdb-repos/database/WriteBatch.cpp
@@ -18,11 +18,7 @@
#include "WriteBatch.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace internal {
+namespace org::apache::nifi::minifi::internal {
rocksdb::Status WriteBatch::Put(const rocksdb::Slice &key, const rocksdb::Slice &value) {
return impl_.Put(column_, key, value);
@@ -36,8 +32,4 @@ rocksdb::Status WriteBatch::Merge(const rocksdb::Slice &key, const rocksdb::Slic
return impl_.Merge(column_, key, value);
}
-} // namespace internal
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::internal
diff --git a/extensions/rocksdb-repos/database/WriteBatch.h b/extensions/rocksdb-repos/database/WriteBatch.h
index 65e925b88..b4c2412ba 100644
--- a/extensions/rocksdb-repos/database/WriteBatch.h
+++ b/extensions/rocksdb-repos/database/WriteBatch.h
@@ -20,11 +20,7 @@
#include "rocksdb/db.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace internal {
+namespace org::apache::nifi::minifi::internal {
class WriteBatch {
friend class OpenRocksDb;
@@ -38,9 +34,4 @@ class WriteBatch {
rocksdb::ColumnFamilyHandle* column_;
};
-} // namespace internal
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
-
+} // namespace org::apache::nifi::minifi::internal
diff --git a/extensions/sftp/tests/tools/SFTPTestServer.cpp b/extensions/sftp/tests/tools/SFTPTestServer.cpp
index 387be14cd..e74249b8e 100644
--- a/extensions/sftp/tests/tools/SFTPTestServer.cpp
+++ b/extensions/sftp/tests/tools/SFTPTestServer.cpp
@@ -99,7 +99,7 @@ bool SFTPTestServer::start() {
for (size_t i = 0; i < 15; i++) {
std::ifstream port_file(port_file_path_);
if (port_file.is_open() && port_file.good()) {
- uint16_t port;
+ uint16_t port = 0;
if (port_file >> port) {
port_ = port;
started_ = true;
@@ -128,7 +128,7 @@ bool SFTPTestServer::stop() {
logger_->log_error("Failed to kill child process, error: {}", strerror(errno));
return false;
}
- int wstatus;
+ int wstatus = 0;
if (::waitpid(server_pid_, &wstatus, 0) == -1) {
logger_->log_error("Failed to waitpid for child process, error: {}", strerror(errno));
return false;
diff --git a/extensions/sql/data/SQLRowSubscriber.h b/extensions/sql/data/SQLRowSubscriber.h
index 94614468e..d870a8673 100644
--- a/extensions/sql/data/SQLRowSubscriber.h
+++ b/extensions/sql/data/SQLRowSubscriber.h
@@ -21,11 +21,7 @@
#include <string>
#include <vector>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace sql {
+namespace org::apache::nifi::minifi::sql {
struct SQLRowSubscriber {
virtual ~SQLRowSubscriber() = default;
@@ -44,8 +40,4 @@ struct SQLRowSubscriber {
virtual void processColumn(const std::string& name, const char* value) = 0;
};
-} /* namespace sql */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::sql
diff --git a/extensions/systemd/Common.h b/extensions/systemd/Common.h
index 73d90a281..8d8bf1bee 100644
--- a/extensions/systemd/Common.h
+++ b/extensions/systemd/Common.h
@@ -18,13 +18,8 @@
#pragma once
-namespace org { namespace apache { namespace nifi { namespace minifi { namespace extensions { namespace systemd {
+namespace org::apache::nifi::minifi::extensions::systemd {
enum class JournalType { User, System, Both };
-} // namespace systemd
-} // namespace extensions
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::extensions::systemd
diff --git a/extensions/windows-event-log/TailEventLog.h b/extensions/windows-event-log/TailEventLog.h
index 9ba18378e..db7e81e84 100644
--- a/extensions/windows-event-log/TailEventLog.h
+++ b/extensions/windows-event-log/TailEventLog.h
@@ -32,11 +32,7 @@
#include "core/PropertyDefinitionBuilder.h"
#include "minifi-cpp/core/RelationshipDefinition.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace processors {
+namespace org::apache::nifi::minifi::processors {
#define MAX_RECORD_BUFFER_SIZE 0x10000 // 64k
const LPCWSTR pEventTypeNames[] = { L"Error", L"Warning", L"Informational", L"Audit Success", L"Audit Failure" };
@@ -129,8 +125,4 @@ class TailEventLog : public core::ProcessorImpl {
HANDLE log_handle_;
};
-} /* namespace processors */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::processors
diff --git a/extensions/windows-event-log/wel/JSONUtils.h b/extensions/windows-event-log/wel/JSONUtils.h
index 5e5b43f25..119f2da3c 100644
--- a/extensions/windows-event-log/wel/JSONUtils.h
+++ b/extensions/windows-event-log/wel/JSONUtils.h
@@ -24,11 +24,7 @@
#include "rapidjson/document.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace wel {
+namespace org::apache::nifi::minifi::wel {
/**
* * !!WARNING!! The json document must not outlive the xml argument. For better performance,
@@ -62,14 +58,14 @@ rapidjson::Document toSimpleJSON(const pugi::xml_node& root);
* Flattens most of the structure, i.e. removes intermediate
* objects and lifts innermost string-valued keys to the root.
* e.g. {System: {Provider: {Name: String}}} => {Name: String}
- *
+ *
* Moreover it also flattens each named data element where the
- * name does not conflict with already existing members
+ * name does not conflict with already existing members
* (e.g. a data with name "Guid" won't be flattened as it would
* overwrite the existing "Guid" field).
- *
+ *
* e.g. {EventData: [{Name: "Test", Content: "X"}]} => {Test: "X"}
- *
+ *
* In order to mitigate data loss, it preserves the EventData
* array in its entirety as well.
* (otherwise a "Guid" data would be lost)
@@ -78,8 +74,4 @@ rapidjson::Document toFlattenedJSON(const pugi::xml_node& root);
std::string jsonToString(const rapidjson::Document& doc);
-} // namespace wel
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::wel
diff --git a/extensions/windows-event-log/wel/XMLString.h b/extensions/windows-event-log/wel/XMLString.h
index b8d53117c..6995fb44c 100644
--- a/extensions/windows-event-log/wel/XMLString.h
+++ b/extensions/windows-event-log/wel/XMLString.h
@@ -37,11 +37,7 @@
#include "pugixml.hpp"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace wel {
+namespace org::apache::nifi::minifi::wel {
class XmlString : public pugi::xml_writer {
public:
@@ -52,9 +48,4 @@ class XmlString : public pugi::xml_writer {
}
};
-} /* namespace wel */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
-
+} // namespace org::apache::nifi::minifi::wel
diff --git a/generateVersion.bat b/generateVersion.bat
index 8b11dd7ca..0f46da4e9 100644
--- a/generateVersion.bat
+++ b/generateVersion.bat
@@ -49,10 +49,7 @@ for %%i in (%extensions%) do (
echo #include ^<vector^>
echo #include "minifi-cpp/agent/agent_version.h"
- echo namespace org {
- echo namespace apache {
- echo namespace nifi {
- echo namespace minifi {
+ echo namespace org::apache::nifi::minifi {
echo const char* const AgentBuild::VERSION = "%version%";
echo const char* const AgentBuild::BUILD_IDENTIFIER = "%buildident%";
@@ -79,10 +76,7 @@ for %%i in (%extensions%) do (
echo return extensions;
echo }
- echo } /* namespace minifi */
- echo } /* namespace nifi */
- echo } /* namespace apache */
- echo } /* namespace org */
+ echo } // namespace org::apache::nifi::minifi
) >> "%out_dir%/agent_version.cpp"
goto :EOF
diff --git a/generateVersion.sh b/generateVersion.sh
index 78ceb2687..0977e3553 100755
--- a/generateVersion.sh
+++ b/generateVersion.sh
@@ -60,10 +60,7 @@ cat >"$out_dir/agent_version.cpp" <<EOF
#include <vector>
#include "minifi-cpp/agent/agent_version.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
+namespace org::apache::nifi::minifi {
const char* const AgentBuild::VERSION = "$version";
const char* const AgentBuild::BUILD_IDENTIFIER = "$buildident";
@@ -91,9 +88,6 @@ cat <<EOF >> "$out_dir/agent_version.cpp"
return extensions;
}
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi
EOF
diff --git a/libminifi/include/c2/C2Protocol.h b/libminifi/include/c2/C2Protocol.h
index 18c7e9894..87de2220d 100644
--- a/libminifi/include/c2/C2Protocol.h
+++ b/libminifi/include/c2/C2Protocol.h
@@ -15,8 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_C2_C2PROTOCOL_H_
-#define LIBMINIFI_INCLUDE_C2_C2PROTOCOL_H_
+#pragma once
#include <memory>
#include <string>
@@ -111,5 +110,3 @@ class C2Protocol : public core::ConnectableImpl {
};
} // namespace org::apache::nifi::minifi::c2
-
-#endif // LIBMINIFI_INCLUDE_C2_C2PROTOCOL_H_
diff --git a/libminifi/include/c2/C2Trigger.h b/libminifi/include/c2/C2Trigger.h
index eb774a650..7db6c4004 100644
--- a/libminifi/include/c2/C2Trigger.h
+++ b/libminifi/include/c2/C2Trigger.h
@@ -15,8 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_C2_C2TRIGGER_H_
-#define LIBMINIFI_INCLUDE_C2_C2TRIGGER_H_
+#pragma once
#include <memory>
#include <utility>
@@ -71,5 +70,3 @@ class C2Trigger : public core::ConnectableImpl {
};
} // namespace org::apache::nifi::minifi::c2
-
-#endif // LIBMINIFI_INCLUDE_C2_C2TRIGGER_H_
diff --git a/libminifi/include/c2/HeartbeatReporter.h b/libminifi/include/c2/HeartbeatReporter.h
index b9b85a109..cd866db23 100644
--- a/libminifi/include/c2/HeartbeatReporter.h
+++ b/libminifi/include/c2/HeartbeatReporter.h
@@ -15,8 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_C2_HEARTBEATREPORTER_H_
-#define LIBMINIFI_INCLUDE_C2_HEARTBEATREPORTER_H_
+#pragma once
#include <memory>
#include <string>
@@ -89,5 +88,3 @@ class HeartbeatReporter : public core::ConnectableImpl {
};
} // namespace org::apache::nifi::minifi::c2
-
-#endif // LIBMINIFI_INCLUDE_C2_HEARTBEATREPORTER_H_
diff --git a/libminifi/include/c2/PayloadSerializer.h b/libminifi/include/c2/PayloadSerializer.h
index 097aa9773..35590c072 100644
--- a/libminifi/include/c2/PayloadSerializer.h
+++ b/libminifi/include/c2/PayloadSerializer.h
@@ -16,8 +16,7 @@
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_C2_PAYLOADSERIALIZER_H_
-#define LIBMINIFI_INCLUDE_C2_PAYLOADSERIALIZER_H_
+#pragma once
#include <memory>
#include <string>
@@ -31,11 +30,7 @@
#include "io/BufferStream.h"
#include "minifi-cpp/utils/gsl.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace c2 {
+namespace org::apache::nifi::minifi::c2 {
class PayloadSerializer {
public:
@@ -333,10 +328,4 @@ class PayloadSerializer {
virtual ~PayloadSerializer();
};
-} // namespace c2
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
-
-#endif // LIBMINIFI_INCLUDE_C2_PAYLOADSERIALIZER_H_
+} // namespace org::apache::nifi::minifi::c2
diff --git a/libminifi/include/c2/protocols/RESTProtocol.h b/libminifi/include/c2/protocols/RESTProtocol.h
index 8f45f7de2..35e3b57a6 100644
--- a/libminifi/include/c2/protocols/RESTProtocol.h
+++ b/libminifi/include/c2/protocols/RESTProtocol.h
@@ -15,8 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_C2_PROTOCOLS_RESTPROTOCOL_H_
-#define LIBMINIFI_INCLUDE_C2_PROTOCOLS_RESTPROTOCOL_H_
+#pragma once
#include <map>
#include <memory>
@@ -56,5 +55,3 @@ class RESTProtocol : public HeartbeatJsonSerializer {
};
} // namespace org::apache::nifi::minifi::c2
-
-#endif // LIBMINIFI_INCLUDE_C2_PROTOCOLS_RESTPROTOCOL_H_
diff --git a/libminifi/include/controllers/ThreadManagementService.h b/libminifi/include/controllers/ThreadManagementService.h
index bd13a99b6..6dba08434 100644
--- a/libminifi/include/controllers/ThreadManagementService.h
+++ b/libminifi/include/controllers/ThreadManagementService.h
@@ -15,8 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_CONTROLLERS_THREADMANAGEMENTSERVICE_H_
-#define LIBMINIFI_INCLUDE_CONTROLLERS_THREADMANAGEMENTSERVICE_H_
+#pragma once
#include <iostream>
#include <string>
@@ -81,5 +80,3 @@ class ThreadManagementServiceImpl : public core::controller::ControllerServiceIm
};
} // namespace org::apache::nifi::minifi::controllers
-
-#endif // LIBMINIFI_INCLUDE_CONTROLLERS_THREADMANAGEMENTSERVICE_H_
diff --git a/libminifi/include/core/extension/Executable.h b/libminifi/include/core/extension/Executable.h
index 29ef191b1..f6f59c6c9 100644
--- a/libminifi/include/core/extension/Executable.h
+++ b/libminifi/include/core/extension/Executable.h
@@ -19,12 +19,7 @@
#include "Module.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace extension {
+namespace org::apache::nifi::minifi::core::extension {
class Executable : public Module {
public:
@@ -32,9 +27,4 @@ class Executable : public Module {
~Executable() override = default;
};
-} // namespace extension
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::extension
diff --git a/libminifi/include/core/extension/Module.h b/libminifi/include/core/extension/Module.h
index f531b4114..2b39e010b 100644
--- a/libminifi/include/core/extension/Module.h
+++ b/libminifi/include/core/extension/Module.h
@@ -26,12 +26,7 @@
#include "properties/Configure.h"
#include "minifi-cpp/core/extension/Extension.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace extension {
+namespace org::apache::nifi::minifi::core::extension {
/**
* Represents an initializable component of the agent.
@@ -63,9 +58,4 @@ class Module {
static std::shared_ptr<logging::Logger> logger_;
};
-} // namespace extension
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::extension
diff --git a/libminifi/include/core/logging/WindowsEventLogSink.h b/libminifi/include/core/logging/WindowsEventLogSink.h
index 10f4581f6..ded240b2c 100644
--- a/libminifi/include/core/logging/WindowsEventLogSink.h
+++ b/libminifi/include/core/logging/WindowsEventLogSink.h
@@ -29,13 +29,7 @@
#include "spdlog/details/null_mutex.h"
#include "spdlog/sinks/base_sink.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace logging {
-namespace internal {
+namespace org::apache::nifi::minifi::core::logging::internal {
class windowseventlog_sink : public spdlog::sinks::base_sink<spdlog::details::null_mutex> {
private:
@@ -59,12 +53,6 @@ class windowseventlog_sink : public spdlog::sinks::base_sink<spdlog::details::nu
windowseventlog_sink& operator=(windowseventlog_sink&&) = delete;
};
-} // namespace internal
-} // namespace logging
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::logging::internal
#endif
diff --git a/libminifi/include/core/logging/internal/CompressionManager.h b/libminifi/include/core/logging/internal/CompressionManager.h
index 669480905..e768fdbe1 100644
--- a/libminifi/include/core/logging/internal/CompressionManager.h
+++ b/libminifi/include/core/logging/internal/CompressionManager.h
@@ -34,13 +34,7 @@
class LoggerTestAccessor;
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace logging {
-namespace internal {
+namespace org::apache::nifi::minifi::core::logging::internal {
class CompressionManager {
friend class ::LoggerTestAccessor;
@@ -76,10 +70,4 @@ class CompressionManager {
std::shared_ptr<LogCompressorSink> sink_;
};
-} // namespace internal
-} // namespace logging
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::logging::internal
diff --git a/libminifi/include/core/logging/internal/LogBuffer.h b/libminifi/include/core/logging/internal/LogBuffer.h
index bfc63eba2..2180bcddc 100644
--- a/libminifi/include/core/logging/internal/LogBuffer.h
+++ b/libminifi/include/core/logging/internal/LogBuffer.h
@@ -23,13 +23,7 @@
#include "io/BufferStream.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace logging {
-namespace internal {
+namespace org::apache::nifi::minifi::core::logging::internal {
class LogBuffer {
public:
@@ -53,10 +47,4 @@ class LogBuffer {
std::unique_ptr<io::BufferStream> buffer_;
};
-} // namespace internal
-} // namespace logging
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::logging::internal
diff --git a/libminifi/include/core/state/UpdatePolicy.h b/libminifi/include/core/state/UpdatePolicy.h
index 8e9eae419..9fa9b12b9 100644
--- a/libminifi/include/core/state/UpdatePolicy.h
+++ b/libminifi/include/core/state/UpdatePolicy.h
@@ -15,19 +15,14 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_CORE_STATE_UPDATEPOLICY_H_
-#define LIBMINIFI_INCLUDE_CORE_STATE_UPDATEPOLICY_H_
+#pragma once
#include <memory>
#include <string>
#include <utility>
#include <unordered_map>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace state {
+namespace org::apache::nifi::minifi::state {
enum UPDATE_POLICY {
PERM_ALLOWED,
@@ -94,7 +89,7 @@ class UpdatePolicy {
class UpdatePolicyBuilder {
public:
static std::unique_ptr<UpdatePolicyBuilder> newBuilder(bool enable_all = false) {
- std::unique_ptr<UpdatePolicyBuilder> policy = std::unique_ptr<UpdatePolicyBuilder>( new UpdatePolicyBuilder(enable_all));
+ std::unique_ptr<UpdatePolicyBuilder> policy = std::unique_ptr<UpdatePolicyBuilder>( new UpdatePolicyBuilder(enable_all)); // NOLINT(clang-analyzer-cplusplus.NewDeleteLeaks)
return policy;
}
@@ -107,7 +102,7 @@ class UpdatePolicyBuilder {
}
std::unique_ptr<UpdatePolicy> build() {
- std::unique_ptr<UpdatePolicy> new_policy = std::unique_ptr<UpdatePolicy>(new UpdatePolicy(*(current_policy_.get())));
+ std::unique_ptr<UpdatePolicy> new_policy = std::unique_ptr<UpdatePolicy>(new UpdatePolicy(*(current_policy_.get()))); // NOLINT(clang-analyzer-cplusplus.NewDeleteLeaks)
return new_policy;
}
@@ -122,10 +117,4 @@ class UpdatePolicyBuilder {
std::shared_ptr<UpdatePolicy> current_policy_;
};
-} // namespace state
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
-
-#endif // LIBMINIFI_INCLUDE_CORE_STATE_UPDATEPOLICY_H_
+} // namespace org::apache::nifi::minifi::state
diff --git a/libminifi/include/io/AtomicEntryStream.h b/libminifi/include/io/AtomicEntryStream.h
index f43fed659..eb30227e7 100644
--- a/libminifi/include/io/AtomicEntryStream.h
+++ b/libminifi/include/io/AtomicEntryStream.h
@@ -15,8 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_IO_ATOMICENTRYSTREAM_H_
-#define LIBMINIFI_INCLUDE_IO_ATOMICENTRYSTREAM_H_
+#pragma once
#include <memory>
#include <vector>
@@ -30,11 +29,7 @@
#include "core/logging/LoggerFactory.h"
#include "minifi-cpp/utils/gsl.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace io {
+namespace org::apache::nifi::minifi::io {
template<typename T>
class AtomicEntryStream : public BaseStreamImpl {
@@ -158,10 +153,4 @@ size_t AtomicEntryStream<T>::read(std::span<std::byte> buf) {
return STREAM_ERROR;
}
-} // namespace io
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
-
-#endif // LIBMINIFI_INCLUDE_IO_ATOMICENTRYSTREAM_H_
+} // namespace org::apache::nifi::minifi::io
diff --git a/libminifi/include/io/NetworkPrioritizer.h b/libminifi/include/io/NetworkPrioritizer.h
index 7ccf0fd15..8f755d1fc 100644
--- a/libminifi/include/io/NetworkPrioritizer.h
+++ b/libminifi/include/io/NetworkPrioritizer.h
@@ -15,19 +15,14 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#ifndef LIBMINIFI_INCLUDE_IO_NETWORKPRIORITIZER_H_
-#define LIBMINIFI_INCLUDE_IO_NETWORKPRIORITIZER_H_
+#pragma once
#include <string>
#include <iostream>
#include <memory>
#include <utility>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace io {
+namespace org::apache::nifi::minifi::io {
class NetworkInterface;
@@ -105,10 +100,4 @@ class NetworkPrioritizerFactory {
std::shared_ptr<NetworkPrioritizer> np_;
};
-} // namespace io
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
-
-#endif // LIBMINIFI_INCLUDE_IO_NETWORKPRIORITIZER_H_
+} // namespace org::apache::nifi::minifi::io
diff --git a/libminifi/include/properties/Decryptor.h b/libminifi/include/properties/Decryptor.h
index 822d338e0..8caa65df2 100644
--- a/libminifi/include/properties/Decryptor.h
+++ b/libminifi/include/properties/Decryptor.h
@@ -23,10 +23,7 @@
#include "utils/crypto/EncryptionUtils.h"
#include "utils/crypto/EncryptionProvider.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
+namespace org::apache::nifi::minifi {
class Decryptor {
public:
@@ -50,7 +47,4 @@ class Decryptor {
const utils::crypto::EncryptionProvider provider_;
};
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi
diff --git a/libminifi/include/utils/StagingQueue.h b/libminifi/include/utils/StagingQueue.h
index f0dc3b8b3..7f63ab8c2 100644
--- a/libminifi/include/utils/StagingQueue.h
+++ b/libminifi/include/utils/StagingQueue.h
@@ -22,11 +22,7 @@
#include <utility>
#include "utils/MinifiConcurrentQueue.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
+namespace org::apache::nifi::minifi::utils {
namespace internal {
template<typename T>
@@ -183,8 +179,4 @@ class StagingQueue {
ConditionConcurrentQueue<Item> queue_;
};
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils
diff --git a/libminifi/include/utils/file/FileSystem.h b/libminifi/include/utils/file/FileSystem.h
index 828e6262a..0c4bc1bea 100644
--- a/libminifi/include/utils/file/FileSystem.h
+++ b/libminifi/include/utils/file/FileSystem.h
@@ -23,12 +23,7 @@
#include "utils/crypto/EncryptionProvider.h"
#include "core/logging/LoggerFactory.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
-namespace file {
+namespace org::apache::nifi::minifi::utils::file {
class FileSystem {
public:
@@ -49,9 +44,4 @@ class FileSystem {
std::shared_ptr<core::logging::Logger> logger_{core::logging::LoggerFactory<FileSystem>::getLogger()};
};
-} // namespace file
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils::file
diff --git a/libminifi/include/utils/tls/DistinguishedName.h b/libminifi/include/utils/tls/DistinguishedName.h
index c122092ce..7fe0323af 100644
--- a/libminifi/include/utils/tls/DistinguishedName.h
+++ b/libminifi/include/utils/tls/DistinguishedName.h
@@ -21,12 +21,7 @@
#include <utility>
#include <vector>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
-namespace tls {
+namespace org::apache::nifi::minifi::utils::tls {
class DistinguishedName {
public:
@@ -44,9 +39,4 @@ class DistinguishedName {
std::vector<std::string> components_;
};
-} // namespace tls
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils::tls
diff --git a/libminifi/include/utils/tls/TLSUtils.h b/libminifi/include/utils/tls/TLSUtils.h
index d8abd89ff..c56c5c7ec 100644
--- a/libminifi/include/utils/tls/TLSUtils.h
+++ b/libminifi/include/utils/tls/TLSUtils.h
@@ -20,18 +20,8 @@
#include <atomic>
#include <cstdint>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace utils {
-namespace tls {
+namespace org::apache::nifi::minifi::utils::tls {
int pemPassWordCb(char *buf, int size, int rwflag, void *userdata);
-} // namespace tls
-} // namespace utils
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::utils::tls
diff --git a/libminifi/src/c2/HeartbeatJsonSerializer.cpp b/libminifi/src/c2/HeartbeatJsonSerializer.cpp
index 1b937715c..1cddcd1c8 100644
--- a/libminifi/src/c2/HeartbeatJsonSerializer.cpp
+++ b/libminifi/src/c2/HeartbeatJsonSerializer.cpp
@@ -28,7 +28,8 @@ namespace org::apache::nifi::minifi::c2 {
static void serializeOperationInfo(rapidjson::Value& target, const C2Payload& payload, rapidjson::Document::AllocatorType& alloc) {
gsl_Expects(target.IsObject());
- target.AddMember("operation", rapidjson::Value(magic_enum::enum_name<Operation>(payload.getOperation()).data(), alloc), alloc);
+ // magic_enum::enum_name() returns a string_view that is a null-terminated string literal
+ target.AddMember("operation", rapidjson::Value(magic_enum::enum_name<Operation>(payload.getOperation()).data(), alloc), alloc); // NOLINT(bugprone-suspicious-stringview-data-usage)
std::string id = payload.getIdentifier();
if (id.empty()) {
diff --git a/libminifi/src/c2/PayloadSerializer.cpp b/libminifi/src/c2/PayloadSerializer.cpp
index fa7713e50..a5d5d0441 100644
--- a/libminifi/src/c2/PayloadSerializer.cpp
+++ b/libminifi/src/c2/PayloadSerializer.cpp
@@ -17,18 +17,10 @@
*/
#include "c2/PayloadSerializer.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace c2 {
+namespace org::apache::nifi::minifi::c2 {
PayloadSerializer::PayloadSerializer() = default;
PayloadSerializer::~PayloadSerializer() = default;
-} /* namespace c2 */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::c2
diff --git a/libminifi/src/controllers/UpdatePolicyControllerService.cpp b/libminifi/src/controllers/UpdatePolicyControllerService.cpp
index a011bdbef..a4edd2668 100644
--- a/libminifi/src/controllers/UpdatePolicyControllerService.cpp
+++ b/libminifi/src/controllers/UpdatePolicyControllerService.cpp
@@ -51,8 +51,6 @@ bool UpdatePolicyControllerService::isWorkAvailable() {
}
void UpdatePolicyControllerService::onEnable() {
- std::string persistStr;
-
const bool enable_all = (getProperty(AllowAllProperties.name) | utils::andThen(parsing::parseBool)).value_or(false);
persist_updates_ = (getProperty(PersistUpdates.name) | utils::andThen(parsing::parseBool)).value_or(false);
diff --git a/libminifi/src/core/ClassLoader.cpp b/libminifi/src/core/ClassLoader.cpp
index 4f3c8d344..67d241f9d 100644
--- a/libminifi/src/core/ClassLoader.cpp
+++ b/libminifi/src/core/ClassLoader.cpp
@@ -53,7 +53,7 @@ class ClassLoaderImpl : public ClassLoader {
[[nodiscard]] std::unique_ptr<CoreComponent> instantiate(const std::string &class_name, const std::string &name, const utils::Identifier &uuid, std::function<bool(CoreComponent*)> filter) override;
- [[nodiscard]] CoreComponent* instantiateRaw(const std::string &class_name, const std::string &name, std::function<bool(CoreComponent*)> filter) override;
+ [[nodiscard]] gsl::owner<CoreComponent*> instantiateRaw(const std::string &class_name, const std::string &name, std::function<bool(CoreComponent*)> filter) override;
~ClassLoaderImpl() override = default;
@@ -116,13 +116,13 @@ class ProcessorFactoryWrapper : public ObjectFactoryImpl {
return std::unique_ptr<CoreComponent>{createRaw(name, uuid)};
}
- [[nodiscard]] CoreComponent* createRaw(const std::string &name) override {
+ [[nodiscard]] gsl::owner<CoreComponent*> createRaw(const std::string &name) override {
return createRaw(name, utils::IdGenerator::getIdGenerator()->generate());
}
- [[nodiscard]] CoreComponent* createRaw(const std::string &name, const utils::Identifier &uuid) override {
+ [[nodiscard]] gsl::owner<CoreComponent*> createRaw(const std::string &name, const utils::Identifier &uuid) override {
auto logger = logging::LoggerFactoryBase::getAliasedLogger(getClassName(), uuid);
- return new Processor(name, uuid, factory_->create({.uuid = uuid, .name = name, .logger = logger})); // NOLINT(cppcoreguidelines-owning-memory)
+ return new Processor(name, uuid, factory_->create({.uuid = uuid, .name = name, .logger = std::move(logger)}));
}
[[nodiscard]] std::string getGroupName() const override {
@@ -146,7 +146,6 @@ void ClassLoaderImpl::unregisterClass(const std::string& clazz) {
std::lock_guard<std::mutex> lock(internal_mutex_);
if (loaded_factories_.erase(clazz) == 0) {
logger_->log_error("Could not unregister non-registered class '{}' at '{}'", clazz, name_);
- return;
} else {
logger_->log_trace("Unregistered class '{}' at '{}'", clazz, name_);
}
@@ -221,11 +220,11 @@ std::unique_ptr<CoreComponent> ClassLoaderImpl::instantiate(const std::string &c
return nullptr;
}
-CoreComponent* ClassLoaderImpl::instantiateRaw(const std::string &class_name, const std::string &name, std::function<bool(CoreComponent*)> filter) {
+gsl::owner<CoreComponent*> ClassLoaderImpl::instantiateRaw(const std::string &class_name, const std::string &name, std::function<bool(CoreComponent*)> filter) {
std::lock_guard<std::mutex> lock(internal_mutex_);
// allow subsequent classes to override functionality (like ProcessContextBuilder)
for (auto& child_loader : class_loaders_) {
- if (auto* result = child_loader.second.instantiateRaw(class_name, name, filter)) {
+ if (gsl::owner<CoreComponent*> result = child_loader.second.instantiateRaw(class_name, name, filter)) {
return result;
}
}
@@ -235,6 +234,7 @@ CoreComponent* ClassLoaderImpl::instantiateRaw(const std::string &class_name, co
if (filter(obj)) {
return obj;
}
+ delete obj;
}
return nullptr;
}
diff --git a/libminifi/src/core/ParameterContext.cpp b/libminifi/src/core/ParameterContext.cpp
index 460507c92..9e175266f 100644
--- a/libminifi/src/core/ParameterContext.cpp
+++ b/libminifi/src/core/ParameterContext.cpp
@@ -20,7 +20,7 @@
namespace org::apache::nifi::minifi::core {
void ParameterContext::addParameter(const Parameter ¶meter) {
- if (parameters_.find(parameter.name) != parameters_.end()) {
+ if (parameters_.contains(parameter.name)) {
throw ParameterException("Parameter name '" + parameter.name + "' already exists, parameter names must be unique within a parameter context!");
}
parameters_.emplace(parameter.name, parameter);
diff --git a/libminifi/src/core/ProcessGroup.cpp b/libminifi/src/core/ProcessGroup.cpp
index 254f4ca20..d8e8ea066 100644
--- a/libminifi/src/core/ProcessGroup.cpp
+++ b/libminifi/src/core/ProcessGroup.cpp
@@ -109,7 +109,7 @@ void ProcessGroup::addPort(std::unique_ptr<Port> port) {
void ProcessGroup::addProcessGroup(std::unique_ptr<ProcessGroup> child) {
std::lock_guard<std::recursive_mutex> lock(mutex_);
- if (child_process_groups_.find(child) == child_process_groups_.end()) {
+ if (!child_process_groups_.contains(child)) {
// We do not have the same child process group in this process group yet
logger_->log_debug("Add child process group {} into process group {}", child->getName(), name_);
child_process_groups_.emplace(std::move(child));
diff --git a/libminifi/src/core/ProcessSessionFactory.cpp b/libminifi/src/core/ProcessSessionFactory.cpp
index 148a3f4fd..d4f6c6d7b 100644
--- a/libminifi/src/core/ProcessSessionFactory.cpp
+++ b/libminifi/src/core/ProcessSessionFactory.cpp
@@ -21,18 +21,10 @@
#include "core/ProcessSessionFactory.h"
#include <memory>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
+namespace org::apache::nifi::minifi::core {
std::shared_ptr<ProcessSession> ProcessSessionFactoryImpl::createSession() {
return std::make_shared<ProcessSessionImpl>(process_context_);
}
-} /* namespace core */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::core
diff --git a/libminifi/src/core/flow/CheckRequiredField.cpp b/libminifi/src/core/flow/CheckRequiredField.cpp
index eab0b1b36..600ad4f75 100644
--- a/libminifi/src/core/flow/CheckRequiredField.cpp
+++ b/libminifi/src/core/flow/CheckRequiredField.cpp
@@ -50,7 +50,7 @@ void checkRequiredField(const Node &node, const std::vector<std::string>& field_
if (error_message.empty()) {
throw std::invalid_argument(buildErrorMessage(node, field_names));
}
- throw std::invalid_argument(error_message.data());
+ throw std::invalid_argument(std::string{error_message});
}
}
@@ -63,7 +63,7 @@ std::string getRequiredField(const Node &node, const std::vector<std::string> &a
if (error_message.empty()) {
throw std::invalid_argument(buildErrorMessage(node, alternate_names));
}
- throw std::invalid_argument(error_message.data());
+ throw std::invalid_argument(std::string{error_message});
}
} // namespace org::apache::nifi::minifi::core::flow
diff --git a/libminifi/src/core/logging/WindowsEventLogSink.cpp b/libminifi/src/core/logging/WindowsEventLogSink.cpp
index b9c512345..a211fce35 100644
--- a/libminifi/src/core/logging/WindowsEventLogSink.cpp
+++ b/libminifi/src/core/logging/WindowsEventLogSink.cpp
@@ -28,13 +28,7 @@
#include "spdlog/sinks/sink.h"
#include "spdlog/details/log_msg.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace logging {
-namespace internal {
+namespace org::apache::nifi::minifi::core::logging::internal {
WORD windowseventlog_sink::type_from_level(const spdlog::details::log_msg& msg) const {
switch (static_cast<int>(msg.level)) {
@@ -82,12 +76,6 @@ windowseventlog_sink::~windowseventlog_sink() {
}
}
-} // namespace internal
-} // namespace logging
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::logging::internal
#endif
diff --git a/libminifi/src/core/logging/internal/LogCompressor.cpp b/libminifi/src/core/logging/internal/LogCompressor.cpp
index 4dd23c090..560e26b01 100644
--- a/libminifi/src/core/logging/internal/LogCompressor.cpp
+++ b/libminifi/src/core/logging/internal/LogCompressor.cpp
@@ -19,13 +19,7 @@
#include "core/logging/internal/LogCompressor.h"
#include "core/logging/LoggerConfiguration.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace logging {
-namespace internal {
+namespace org::apache::nifi::minifi::core::logging::internal {
LogCompressor::LogCompressor(gsl::not_null<OutputStream *> output, std::shared_ptr<logging::Logger> logger)
: ZlibCompressStream(output, io::ZlibCompressionFormat::GZIP, Z_DEFAULT_COMPRESSION, std::move(logger)) {}
@@ -37,11 +31,4 @@ LogCompressor::FlushResult LogCompressor::flush() {
return FlushResult::Error;
}
-} // namespace internal
-} // namespace logging
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
-
+} // namespace org::apache::nifi::minifi::core::logging::internal
diff --git a/libminifi/src/core/state/nodes/DeviceInformation.cpp b/libminifi/src/core/state/nodes/DeviceInformation.cpp
index d1b2d4aab..6468b93b9 100644
--- a/libminifi/src/core/state/nodes/DeviceInformation.cpp
+++ b/libminifi/src/core/state/nodes/DeviceInformation.cpp
@@ -54,10 +54,9 @@ Device::Device() {
canonical_hostname_ = hostname.data();
- std::stringstream ips;
auto ipaddressess = getIpAddresses();
for (const auto& ip : ipaddressess) {
- if (ipaddressess.size() > 1 && (ip.find("127") == 0 || ip.find("192") == 0))
+ if (ipaddressess.size() > 1 && (ip.starts_with("127") || ip.starts_with("192")))
continue;
ip_ = ip;
break;
diff --git a/libminifi/src/core/state/nodes/RepositoryMetrics.cpp b/libminifi/src/core/state/nodes/RepositoryMetrics.cpp
index 40748e20c..a9f56de38 100644
--- a/libminifi/src/core/state/nodes/RepositoryMetrics.cpp
+++ b/libminifi/src/core/state/nodes/RepositoryMetrics.cpp
@@ -22,7 +22,7 @@
namespace org::apache::nifi::minifi::state::response {
void RepositoryMetrics::addRepository(const std::shared_ptr<core::RepositoryMetricsSource> &repo) {
- return repository_metrics_source_store_.addRepository(repo);
+ repository_metrics_source_store_.addRepository(repo);
}
std::vector<SerializedResponseNode> RepositoryMetrics::serialize() {
diff --git a/libminifi/src/io/AtomicEntryStream.cpp b/libminifi/src/io/AtomicEntryStream.cpp
deleted file mode 100644
index 388fc8fd9..000000000
--- a/libminifi/src/io/AtomicEntryStream.cpp
+++ /dev/null
@@ -1,33 +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.
- */
-#include "io/AtomicEntryStream.h"
-#include <vector>
-#include <mutex>
-#include <string>
-
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace io {
-
-} /* namespace io */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
diff --git a/libminifi/src/utils/tls/DistinguishedName.cpp b/libminifi/src/utils/tls/DistinguishedName.cpp
index f611e4759..d14fe8f9e 100644
--- a/libminifi/src/utils/tls/DistinguishedName.cpp
+++ b/libminifi/src/utils/tls/DistinguishedName.cpp
@@ -39,7 +39,7 @@ DistinguishedName DistinguishedName::fromSlashSeparated(const std::string &slash
std::optional<std::string> DistinguishedName::getCN() const {
const auto it = std::find_if(components_.begin(), components_.end(),
- [](const std::string& component) { return component.compare(0, 3, "CN=") == 0; });
+ [](const std::string& component) { return component.starts_with("CN="); });
if (it != components_.end()) {
return it->substr(3);
} else {
diff --git a/libminifi/test/integration/OnScheduleErrorHandlingTests.cpp b/libminifi/test/integration/OnScheduleErrorHandlingTests.cpp
index 56b9b04d3..ae18fcd27 100644
--- a/libminifi/test/integration/OnScheduleErrorHandlingTests.cpp
+++ b/libminifi/test/integration/OnScheduleErrorHandlingTests.cpp
@@ -37,7 +37,7 @@ class KamikazeErrorHandlingTests : public IntegrationBase {
REQUIRE(verifyEventHappenedInPollTime(wait_time_, [&] {
const std::string logs = LogTestController::getInstance().getLogs();
const auto result = minifi::utils::string::countOccurrences(logs, minifi::processors::KamikazeProcessor::OnScheduleExceptionStr);
- const int occurrences = result.second;
+ const auto occurrences = result.second;
return 1 < occurrences;
}));
flowController_->updatePropertyValue("kamikaze", std::string(minifi::processors::KamikazeProcessor::ThrowInOnSchedule.name), "false");
diff --git a/libminifi/test/libtest/integration/ConnectionCountingServer.cpp b/libminifi/test/libtest/integration/ConnectionCountingServer.cpp
index 41ac99dca..86baee859 100644
--- a/libminifi/test/libtest/integration/ConnectionCountingServer.cpp
+++ b/libminifi/test/libtest/integration/ConnectionCountingServer.cpp
@@ -68,7 +68,7 @@ bool ReverseBodyPostHandler::handlePost(CivetServer* /*server*/, struct mg_conne
request_body.reserve(2048);
size_t read_size = mg_read(conn, request_body.data(), 2048);
assert(read_size < 2048);
- std::string response_body{request_body.begin(), request_body.begin() + read_size};
+ std::string response_body{request_body.begin(), request_body.begin() + gsl::narrow<std::vector<char>::difference_type>(read_size)};
std::reverse(std::begin(response_body), std::end(response_body));
mg_printf(conn, "HTTP/1.1 200 OK\r\n");
mg_printf(conn, "Content-length: %zu\r\n", read_size);
@@ -85,14 +85,14 @@ void ReverseBodyPostHandler::saveConnectionId(struct mg_connection* conn) {
AddIdToUserConnectionData::AddIdToUserConnectionData() {
init_connection = [](const struct mg_connection*, void** user_connection_data) -> int {
- minifi::utils::SmallString<36>* id = new minifi::utils::SmallString<36>(minifi::utils::IdGenerator::getIdGenerator()->generate().to_string());
+ auto id = new minifi::utils::SmallString<36>(minifi::utils::IdGenerator::getIdGenerator()->generate().to_string());
*user_connection_data = reinterpret_cast<void*>(id);
return 0;
};
connection_close = [](const struct mg_connection* conn) -> void {
auto user_connection_data = reinterpret_cast<minifi::utils::SmallString<36>*>(mg_get_user_connection_data(conn));
- delete user_connection_data;
+ delete user_connection_data; // NOLINT(cppcoreguidelines-owning-memory)
};
}
} // namespace details
diff --git a/libminifi/test/libtest/integration/HTTPIntegrationBase.cpp b/libminifi/test/libtest/integration/HTTPIntegrationBase.cpp
index c6439f9bb..62f2dc84a 100644
--- a/libminifi/test/libtest/integration/HTTPIntegrationBase.cpp
+++ b/libminifi/test/libtest/integration/HTTPIntegrationBase.cpp
@@ -43,7 +43,9 @@ std::string HTTPIntegrationBase::getC2RestUrl() const {
}
void HTTPIntegrationBase::setUrl(const std::string &url, ServerAwareHandler *handler) {
- std::string url_port, url_scheme, url_path;
+ std::string url_port;
+ std::string url_scheme;
+ std::string url_path;
minifi::utils::parse_http_components(url, url_port, url_scheme, url_path);
if (server) {
if (url_port != "0" && url_port != port) {
diff --git a/libminifi/test/libtest/unit/TestBase.cpp b/libminifi/test/libtest/unit/TestBase.cpp
index 11d2811fb..193885d62 100644
--- a/libminifi/test/libtest/unit/TestBase.cpp
+++ b/libminifi/test/libtest/unit/TestBase.cpp
@@ -148,7 +148,7 @@ std::optional<std::smatch> LogTestController::matchesRegex(const std::string& re
return found ? std::make_optional<std::smatch>(match) : std::nullopt;
}
-int LogTestController::countOccurrences(const std::string& pattern) const {
+size_t LogTestController::countOccurrences(const std::string& pattern) const {
return minifi::utils::string::countOccurrences(getLogs(), pattern).second;
}
diff --git a/libminifi/test/libtest/unit/TestBase.h b/libminifi/test/libtest/unit/TestBase.h
index dd5f0b9fb..133f97e38 100644
--- a/libminifi/test/libtest/unit/TestBase.h
+++ b/libminifi/test/libtest/unit/TestBase.h
@@ -139,7 +139,7 @@ class LogTestController {
std::chrono::milliseconds timeout = std::chrono::seconds(3),
std::chrono::milliseconds sleep_interval = std::chrono::milliseconds(200)) const;
- int countOccurrences(const std::string& pattern) const;
+ size_t countOccurrences(const std::string& pattern) const;
void reset();
diff --git a/libminifi/test/libtest/unit/TestUtils.cpp b/libminifi/test/libtest/unit/TestUtils.cpp
index c1f18ba6b..b479281e8 100644
--- a/libminifi/test/libtest/unit/TestUtils.cpp
+++ b/libminifi/test/libtest/unit/TestUtils.cpp
@@ -158,7 +158,7 @@ void verifyJSON(const std::string& actual_str, const std::string& expected_str,
}
bool countLogOccurrencesUntil(const std::string& pattern,
- const int occurrences,
+ const size_t occurrences,
const std::chrono::milliseconds max_duration,
const std::chrono::milliseconds wait_time) {
auto start_time = std::chrono::steady_clock::now();
diff --git a/libminifi/test/libtest/unit/TestUtils.h b/libminifi/test/libtest/unit/TestUtils.h
index 3a1223b85..d2ca10d83 100644
--- a/libminifi/test/libtest/unit/TestUtils.h
+++ b/libminifi/test/libtest/unit/TestUtils.h
@@ -167,7 +167,7 @@ class ExceptionSubStringMatcher : public Catch::Matchers::MatcherBase<T> {
};
bool countLogOccurrencesUntil(const std::string& pattern,
- const int occurrences,
+ const size_t occurrences,
const std::chrono::milliseconds max_duration,
const std::chrono::milliseconds wait_time = 50ms);
std::error_code sendMessagesViaTCP(const std::vector<std::string_view>& contents, const asio::ip::tcp::endpoint& remote_endpoint, const std::optional<std::string_view> delimiter = std::nullopt);
diff --git a/libminifi/test/schema-tests/SchemaTests.cpp b/libminifi/test/schema-tests/SchemaTests.cpp
index 3a3f7dc58..5615d62a4 100644
--- a/libminifi/test/schema-tests/SchemaTests.cpp
+++ b/libminifi/test/schema-tests/SchemaTests.cpp
@@ -233,7 +233,7 @@ TEST_CASE("The JSON schema detects invalid values in the json flow") {
std::unordered_map<std::string, std::string> errors;
extractExpectedErrors(config_json, "", errors);
- ErrorHandler err_handler{[&] (auto err) {
+ ErrorHandler err_handler{[&] (const auto& err) {
auto it = errors.find(err.path);
if (it == errors.end()) {
throw std::logic_error("Unexpected error in json flow at " + err.path + ": " + err.error);
diff --git a/libminifi/test/unit/BackTraceTests.cpp b/libminifi/test/unit/BackTraceTests.cpp
index 51eaa59d4..8dc26803a 100644
--- a/libminifi/test/unit/BackTraceTests.cpp
+++ b/libminifi/test/unit/BackTraceTests.cpp
@@ -52,7 +52,7 @@ TEST_CASE("BT2", "[TPT2]") {
constexpr std::string_view thread_pool_name = "Winnie the pool";
constexpr size_t number_of_worker_threads = 3;
- utils::ThreadPool pool(number_of_worker_threads, nullptr, thread_pool_name.data());
+ utils::ThreadPool pool(number_of_worker_threads, nullptr, std::string{thread_pool_name});
utils::Worker worker([&]() -> utils::TaskRescheduleInfo {
outer_function(ready_for_checking, done_with_checking);
return utils::TaskRescheduleInfo::Done();
diff --git a/libminifi/test/unit/CertificateUtilsTests.cpp b/libminifi/test/unit/CertificateUtilsTests.cpp
index 3700a7513..88b82b2c0 100644
--- a/libminifi/test/unit/CertificateUtilsTests.cpp
+++ b/libminifi/test/unit/CertificateUtilsTests.cpp
@@ -33,7 +33,7 @@ TEST_CASE("getCertificateExpiration() works correctly") {
const auto cert_location = executable_dir / "resources" / "ca_A.crt";
size_t num_times_called = 0;
- utils::tls::processPEMCertificate(cert_location, {}, {[&](utils::tls::X509_unique_ptr cert) {
+ std::ignore = utils::tls::processPEMCertificate(cert_location, {}, {[&](utils::tls::X509_unique_ptr cert) {
++num_times_called;
CHECK(utils::tls::getCertificateExpiration(cert) == date::sys_days(date::year_month_day(2033_y / 6 / 26)) + 12h + 26min + 48s);
return std::error_code{};
diff --git a/libminifi/test/unit/CronTests.cpp b/libminifi/test/unit/CronTests.cpp
index fa70ac206..1f3800577 100644
--- a/libminifi/test/unit/CronTests.cpp
+++ b/libminifi/test/unit/CronTests.cpp
@@ -25,7 +25,9 @@
using std::chrono::system_clock;
using std::chrono::seconds;
using org::apache::nifi::minifi::utils::Cron;
+#ifdef WIN32
namespace timeutils = org::apache::nifi::minifi::utils::timeutils;
+#endif
void checkNext(const std::string& expr, const date::zoned_time<seconds>& from, const date::zoned_time<seconds>& next) {
diff --git a/libminifi/test/unit/HTTPStreamingCallbackTests.cpp b/libminifi/test/unit/HTTPStreamingCallbackTests.cpp
index ae8618b57..3ed8a1d35 100644
--- a/libminifi/test/unit/HTTPStreamingCallbackTests.cpp
+++ b/libminifi/test/unit/HTTPStreamingCallbackTests.cpp
@@ -111,7 +111,7 @@ TEST_CASE_METHOD(HttpStreamingCallbackTestsFixture, "HttpStreamingCallback empty
std::string content = waitForCompletionAndGetContent();
- REQUIRE(0U == content.length());
+ REQUIRE(content.empty());
}
TEST_CASE_METHOD(HttpStreamingCallbackTestsFixture, "HttpStreamingCallback one buffer", "[basic]") {
diff --git a/libminifi/test/unit/IdTests.cpp b/libminifi/test/unit/IdTests.cpp
index fa3711535..048072b5d 100644
--- a/libminifi/test/unit/IdTests.cpp
+++ b/libminifi/test/unit/IdTests.cpp
@@ -333,6 +333,7 @@ TEST_CASE("Collision", "[collision]") {
std::vector<utils::Identifier> uuids(16 * 1024U);
std::vector<std::thread> threads;
+ threads.reserve(16);
for (size_t i = 0U; i < 16U; i++) {
threads.emplace_back([&generator, &uuids, i](){
for (size_t j = 0U; j < 1024U; j++) {
diff --git a/libminifi/test/unit/MapUtilsTests.cpp b/libminifi/test/unit/MapUtilsTests.cpp
index e0d7cedbf..88e33418c 100644
--- a/libminifi/test/unit/MapUtilsTests.cpp
+++ b/libminifi/test/unit/MapUtilsTests.cpp
@@ -28,8 +28,8 @@
namespace MapUtils = org::apache::nifi::minifi::utils::MapUtils;
TEST_CASE("TestMapUtils::getKeys", "[getKeys]") {
- REQUIRE(MapUtils::getKeys(std::map<int, int>()) == std::set<int>());
- REQUIRE(MapUtils::getKeys(std::unordered_map<int, int>()) == std::set<int>());
+ REQUIRE(MapUtils::getKeys(std::map<int, int>()).empty());
+ REQUIRE(MapUtils::getKeys(std::unordered_map<int, int>()).empty());
std::map<int, std::string> test_map{
std::make_pair(1, "one"),
diff --git a/libminifi/test/unit/NetworkInterfaceInfoTests.cpp b/libminifi/test/unit/NetworkInterfaceInfoTests.cpp
index bb57e294d..47f4c8b74 100644
--- a/libminifi/test/unit/NetworkInterfaceInfoTests.cpp
+++ b/libminifi/test/unit/NetworkInterfaceInfoTests.cpp
@@ -23,7 +23,7 @@ namespace utils = org::apache::nifi::minifi::utils;
TEST_CASE("NetworkInterfaceInfo test", "[testnetworkinterfaceinfo]") {
auto network_interface_infos = utils::NetworkInterfaceInfo::getNetworkInterfaceInfos();
- REQUIRE(network_interface_infos.size() > 0);
+ REQUIRE_FALSE(network_interface_infos.empty());
auto valid_interface_name = network_interface_infos.begin()->getName();
auto filter = [&valid_interface_name](const utils::NetworkInterfaceInfo& interface_info) -> bool { return interface_info.getName() == valid_interface_name; };
diff --git a/libminifi/test/unit/RegexUtilsTests.cpp b/libminifi/test/unit/RegexUtilsTests.cpp
index 7b0195df7..4913c7099 100644
--- a/libminifi/test/unit/RegexUtilsTests.cpp
+++ b/libminifi/test/unit/RegexUtilsTests.cpp
@@ -37,7 +37,6 @@ TEST_CASE("TestRegexUtils::single_match", "[regex1]") {
}
TEST_CASE("TestRegexUtils::invalid_construction", "[regex2]") {
- std::string pat = "Speed limit 130 | Speed limit 80";
std::string rgx1 = "Speed limit ([0-9]+)";
std::string rgx2 = "[Invalid)A(F)";
std::vector<Regex::Mode> mode = {Regex::Mode::ICASE};
diff --git a/libminifi/test/unit/SiteToSiteTests.cpp b/libminifi/test/unit/SiteToSiteTests.cpp
index 3f2d8b98c..2a0c36cd5 100644
--- a/libminifi/test/unit/SiteToSiteTests.cpp
+++ b/libminifi/test/unit/SiteToSiteTests.cpp
@@ -266,9 +266,8 @@ TEST_CASE("TestSiteToSiteVerifyNegotiationFail", "[S2S]") {
initializeLogging();
auto collector = std::make_unique<SiteToSiteResponder>();
- const char negotiated_abort_code = magic_enum::enum_underlying(sitetosite::ResourceNegotiationStatusCode::NEGOTIATED_ABORT);
- std::string resp_code;
- resp_code.insert(resp_code.begin(), negotiated_abort_code);
+ const auto negotiated_abort_code = magic_enum::enum_underlying(sitetosite::ResourceNegotiationStatusCode::NEGOTIATED_ABORT);
+ const std::string resp_code{static_cast<char>(negotiated_abort_code)};
collector->push_response(resp_code);
collector->push_response(resp_code);
diff --git a/libminifi/test/unit/StringUtilsTests.cpp b/libminifi/test/unit/StringUtilsTests.cpp
index f194a6a1e..b074e9381 100644
--- a/libminifi/test/unit/StringUtilsTests.cpp
+++ b/libminifi/test/unit/StringUtilsTests.cpp
@@ -178,7 +178,7 @@ TEST_CASE("test string::testJoin", "[test string join]") {
TEST_CASE("Test the join function with a projection", "[join][projection]") {
std::vector<std::string> fruits = {"APPLE", "OrAnGe"};
- CHECK(string::join(", ", fruits, [](auto fruit) { return string::toLower(fruit); }) == "apple, orange");
+ CHECK(string::join(", ", fruits, [](const auto& fruit) { return string::toLower(fruit); }) == "apple, orange");
std::set numbers_set = {3, 2, 1};
CHECK(string::join(", ", numbers_set, [](auto x) { return std::to_string(x); }) == "1, 2, 3");
@@ -523,15 +523,15 @@ TEST_CASE("string::replaceAll works correctly", "[replaceAll]") {
}
TEST_CASE("string::countOccurrences works correctly", "[countOccurrences]") {
- REQUIRE(string::countOccurrences("", "a") == std::make_pair(size_t{0}, 0));
- REQUIRE(string::countOccurrences("abc", "a") == std::make_pair(size_t{0}, 1));
- REQUIRE(string::countOccurrences("abc", "b") == std::make_pair(size_t{1}, 1));
- REQUIRE(string::countOccurrences("abc", "x") == std::make_pair(size_t{0}, 0));
- REQUIRE(string::countOccurrences("banana", "a") == std::make_pair(size_t{5}, 3));
- REQUIRE(string::countOccurrences("banana", "an") == std::make_pair(size_t{3}, 2));
- REQUIRE(string::countOccurrences("aaaaaaaa", "aaa") == std::make_pair(size_t{3}, 2)); // overlapping occurrences are not counted
- REQUIRE(string::countOccurrences("abc", "") == std::make_pair(size_t{3}, 4)); // "" occurs at the start, between chars, and at the end
- REQUIRE(string::countOccurrences("", "") == std::make_pair(size_t{0}, 1));
+ REQUIRE(string::countOccurrences("", "a") == std::make_pair(size_t{0}, size_t{0}));
+ REQUIRE(string::countOccurrences("abc", "a") == std::make_pair(size_t{0}, size_t{1}));
+ REQUIRE(string::countOccurrences("abc", "b") == std::make_pair(size_t{1}, size_t{1}));
+ REQUIRE(string::countOccurrences("abc", "x") == std::make_pair(size_t{0}, size_t{0}));
+ REQUIRE(string::countOccurrences("banana", "a") == std::make_pair(size_t{5}, size_t{3}));
+ REQUIRE(string::countOccurrences("banana", "an") == std::make_pair(size_t{3}, size_t{2}));
+ REQUIRE(string::countOccurrences("aaaaaaaa", "aaa") == std::make_pair(size_t{3}, size_t{2})); // overlapping occurrences are not counted
+ REQUIRE(string::countOccurrences("abc", "") == std::make_pair(size_t{3}, size_t{4})); // "" occurs at the start, between chars, and at the end
+ REQUIRE(string::countOccurrences("", "") == std::make_pair(size_t{0}, size_t{1}));
}
TEST_CASE("string::removeFramingCharacters works correctly", "[removeFramingCharacters]") {
diff --git a/libminifi/test/unit/TimeUtilTests.cpp b/libminifi/test/unit/TimeUtilTests.cpp
index ae479df06..6aac7eefb 100644
--- a/libminifi/test/unit/TimeUtilTests.cpp
+++ b/libminifi/test/unit/TimeUtilTests.cpp
@@ -140,9 +140,9 @@ TEST_CASE("Test windows FILETIME epoch") {
#endif
TEST_CASE("Test clock resolutions", "[clockresolutiontests]") {
- CHECK(std::is_constructible<std::chrono::system_clock::duration, std::chrono::microseconds>::value); // The resolution of the system_clock is at least microseconds
- CHECK(std::is_constructible<std::chrono::steady_clock::duration, std::chrono::microseconds>::value); // The resolution of the steady_clock is at least microseconds
- CHECK(std::is_constructible<std::chrono::high_resolution_clock::duration, std::chrono::nanoseconds>::value); // The resolution of the high_resolution_clock is at least nanoseconds
+ CHECK(std::is_constructible_v<std::chrono::system_clock::duration, std::chrono::microseconds>); // The resolution of the system_clock is at least microseconds
+ CHECK(std::is_constructible_v<std::chrono::steady_clock::duration, std::chrono::microseconds>); // The resolution of the steady_clock is at least microseconds
+ CHECK(std::is_constructible_v<std::chrono::high_resolution_clock::duration, std::chrono::nanoseconds>); // The resolution of the high_resolution_clock is at least nanoseconds
}
TEST_CASE("Test string to duration conversion", "[timedurationtests]") {
diff --git a/minifi-api/include/minifi-cpp/core/AgentIdentificationProvider.h b/minifi-api/include/minifi-cpp/core/AgentIdentificationProvider.h
index 6e297b634..c014325bb 100644
--- a/minifi-api/include/minifi-cpp/core/AgentIdentificationProvider.h
+++ b/minifi-api/include/minifi-cpp/core/AgentIdentificationProvider.h
@@ -21,11 +21,7 @@
#include <optional>
#include <string>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
+namespace org::apache::nifi::minifi::core {
/**
* Provides a single source of truth for the agent's class and identifier.
@@ -39,8 +35,4 @@ class AgentIdentificationProvider {
virtual ~AgentIdentificationProvider() = default;
};
-} /* namespace core */
-} /* namespace minifi */
-} /* namespace nifi */
-} /* namespace apache */
-} /* namespace org */
+} // namespace org::apache::nifi::minifi::core
diff --git a/minifi-api/include/minifi-cpp/core/Annotation.h b/minifi-api/include/minifi-cpp/core/Annotation.h
index e61117715..3f9014f60 100644
--- a/minifi-api/include/minifi-cpp/core/Annotation.h
+++ b/minifi-api/include/minifi-cpp/core/Annotation.h
@@ -21,12 +21,7 @@
#include <cstdint>
#include <string>
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
-namespace annotation {
+namespace org::apache::nifi::minifi::core::annotation {
enum class Input : uint8_t {
/**
@@ -64,9 +59,4 @@ inline std::string toString(Input input_requirement) {
return "ERROR_no_such_input_requirement";
}
-} // namespace annotation
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core::annotation
diff --git a/minifi-api/include/minifi-cpp/core/ClassLoader.h b/minifi-api/include/minifi-cpp/core/ClassLoader.h
index 5413e74e5..7956083ff 100644
--- a/minifi-api/include/minifi-cpp/core/ClassLoader.h
+++ b/minifi-api/include/minifi-cpp/core/ClassLoader.h
@@ -78,7 +78,7 @@ class ClassLoader {
[[nodiscard]] virtual std::unique_ptr<CoreComponent> instantiate(
const std::string &class_name, const std::string &name, const utils::Identifier &uuid, std::function<bool(CoreComponent*)> filter) = 0;
- [[nodiscard]] virtual CoreComponent* instantiateRaw(const std::string &class_name, const std::string &name, std::function<bool(CoreComponent*)> filter) = 0;
+ [[nodiscard]] virtual gsl::owner<CoreComponent*> instantiateRaw(const std::string &class_name, const std::string &name, std::function<bool(CoreComponent*)> filter) = 0;
/**
* Instantiate object based on class_name
@@ -105,7 +105,7 @@ class ClassLoader {
* @return nullptr or object created from class_name definition.
*/
template<class T = CoreComponent>
- [[nodiscard]] T *instantiateRaw(const std::string &class_name, const std::string &name);
+ [[nodiscard]] gsl::owner<T*> instantiateRaw(const std::string &class_name, const std::string &name);
template<class T = CoreComponent>
[[nodiscard]] std::unique_ptr<T> instantiate(const std::string &class_name, const std::string &name, const utils::Identifier &uuid);
diff --git a/minifi-api/include/minifi-cpp/core/ObjectFactory.h b/minifi-api/include/minifi-cpp/core/ObjectFactory.h
index 9f247b2a2..8058151ee 100644
--- a/minifi-api/include/minifi-cpp/core/ObjectFactory.h
+++ b/minifi-api/include/minifi-cpp/core/ObjectFactory.h
@@ -27,9 +27,9 @@ namespace org::apache::nifi::minifi::core {
class ObjectFactory {
public:
virtual std::unique_ptr<CoreComponent> create(const std::string& /*name*/) = 0;
- virtual CoreComponent *createRaw(const std::string& /*name*/) = 0;
+ virtual gsl::owner<CoreComponent*> createRaw(const std::string& /*name*/) = 0;
virtual std::unique_ptr<CoreComponent> create(const std::string& /*name*/, const utils::Identifier& /*uuid*/) = 0;
- virtual CoreComponent* createRaw(const std::string& /*name*/, const utils::Identifier& /*uuid*/) = 0;
+ virtual gsl::owner<CoreComponent*> createRaw(const std::string& /*name*/, const utils::Identifier& /*uuid*/) = 0;
virtual std::string getGroupName() const = 0;
virtual std::string getClassName() = 0;
diff --git a/minifi-api/include/minifi-cpp/core/TraceableResource.h b/minifi-api/include/minifi-cpp/core/TraceableResource.h
index 805ee51a9..828bab679 100644
--- a/minifi-api/include/minifi-cpp/core/TraceableResource.h
+++ b/minifi-api/include/minifi-cpp/core/TraceableResource.h
@@ -19,11 +19,7 @@
#include "utils/BackTrace.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace core {
+namespace org::apache::nifi::minifi::core {
/**
* Purpose: Defines a resource eligible for tracing
@@ -42,8 +38,4 @@ class TraceableResource {
virtual BackTrace getTraces() = 0;
};
-} // namespace core
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::core
diff --git a/minifi-api/include/minifi-cpp/io/OutputStream.h b/minifi-api/include/minifi-cpp/io/OutputStream.h
index 9784f10f8..d0e7f3d55 100644
--- a/minifi-api/include/minifi-cpp/io/OutputStream.h
+++ b/minifi-api/include/minifi-cpp/io/OutputStream.h
@@ -26,11 +26,7 @@
#include "utils/SmallString.h"
#include "utils/Id.h"
-namespace org {
-namespace apache {
-namespace nifi {
-namespace minifi {
-namespace io {
+namespace org::apache::nifi::minifi::io {
/**
* Serializable instances provide base functionality to
@@ -118,8 +114,4 @@ class OutputStream : public virtual Stream {
size_t write_str(const char* str, uint32_t len, bool widen);
};
-} // namespace io
-} // namespace minifi
-} // namespace nifi
-} // namespace apache
-} // namespace org
+} // namespace org::apache::nifi::minifi::io