This is an automated email from the ASF dual-hosted git repository.
pvillard pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/nifi.git
The following commit(s) were added to refs/heads/main by this push:
new 23d2d97aab NIFI-12511 Corrected lib Directory Assembly Configuration
23d2d97aab is described below
commit 23d2d97aabac6f96f4de32d32213307a1605355c
Author: exceptionfactory <[email protected]>
AuthorDate: Wed Dec 13 10:39:56 2023 -0600
NIFI-12511 Corrected lib Directory Assembly Configuration
- Moved JAR libraries to core.xml configuration using include strategy
- Added NAR bundles section to common.xml dependencies
Signed-off-by: Pierre Villard <[email protected]>
This closes #8155.
---
nifi-assembly/src/main/assembly/common.xml | 9 +++++
nifi-assembly/src/main/assembly/core.xml | 50 ++++++++++++++++++++++++
nifi-assembly/src/main/assembly/dependencies.xml | 25 +-----------
nifi-assembly/src/main/assembly/ranger.xml | 18 +--------
4 files changed, 61 insertions(+), 41 deletions(-)
diff --git a/nifi-assembly/src/main/assembly/common.xml
b/nifi-assembly/src/main/assembly/common.xml
index 0d15d8a9da..8f12406415 100644
--- a/nifi-assembly/src/main/assembly/common.xml
+++ b/nifi-assembly/src/main/assembly/common.xml
@@ -190,6 +190,15 @@
</unpackOptions>
</dependencySet>
+ <!-- NAR bundles -->
+ <dependencySet>
+ <outputDirectory>lib</outputDirectory>
+ <useProjectArtifact>false</useProjectArtifact>
+ <useTransitiveDependencies>false</useTransitiveDependencies>
+ <includes>
+ <include>org.apache.nifi:*:nar</include>
+ </includes>
+ </dependencySet>
</dependencySets>
<fileSets>
<fileSet>
diff --git a/nifi-assembly/src/main/assembly/core.xml
b/nifi-assembly/src/main/assembly/core.xml
new file mode 100644
index 0000000000..743e81bf5b
--- /dev/null
+++ b/nifi-assembly/src/main/assembly/core.xml
@@ -0,0 +1,50 @@
+<?xml version="1.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.
+-->
+<component>
+ <dependencySets>
+ <!-- Core libraries -->
+ <dependencySet>
+ <outputDirectory>lib</outputDirectory>
+ <directoryMode>0770</directoryMode>
+ <fileMode>0664</fileMode>
+ <useProjectArtifact>false</useProjectArtifact>
+ <includes>
+ <!-- Logging -->
+ <include>org.slf4j:slf4j-api</include>
+ <include>org.slf4j:log4j-over-slf4j</include>
+ <include>org.slf4j:jcl-over-slf4j</include>
+ <include>org.slf4j:jul-to-slf4j</include>
+ <include>ch.qos.logback:logback-classic</include>
+ <include>ch.qos.logback:logback-core</include>
+ <!-- Servlet API -->
+ <include>javax.servlet:javax.servlet-api</include>
+ <include>org.eclipse.jetty.toolchain:jetty-schemas</include>
+ <!-- Apache NiFi -->
+ <include>org.apache.nifi:nifi-api</include>
+ <include>org.apache.nifi:nifi-framework-api</include>
+ <include>org.apache.nifi:nifi-nar-utils</include>
+
<include>org.apache.nifi:nifi-per-process-group-logging</include>
+ <include>org.apache.nifi:nifi-properties</include>
+ <include>org.apache.nifi:nifi-property-utils</include>
+ <include>org.apache.nifi:nifi-python-framework-api</include>
+ <include>org.apache.nifi:nifi-runtime</include>
+ <include>org.apache.nifi:nifi-server-api</include>
+ <include>org.apache.nifi:nifi-stateless-api</include>
+ <include>org.apache.nifi:nifi-stateless-bootstrap</include>
+ </includes>
+ </dependencySet>
+ </dependencySets>
+</component>
diff --git a/nifi-assembly/src/main/assembly/dependencies.xml
b/nifi-assembly/src/main/assembly/dependencies.xml
index 767a8baf92..949a316872 100644
--- a/nifi-assembly/src/main/assembly/dependencies.xml
+++ b/nifi-assembly/src/main/assembly/dependencies.xml
@@ -19,30 +19,7 @@
<baseDirectory>nifi-${project.version}</baseDirectory>
<componentDescriptors>
+ <componentDescriptor>src/main/assembly/core.xml</componentDescriptor>
<componentDescriptor>src/main/assembly/common.xml</componentDescriptor>
</componentDescriptors>
-
- <dependencySets>
- <!-- Write out all dependency artifacts to lib directory -->
- <dependencySet>
- <scope>runtime</scope>
- <useProjectArtifact>false</useProjectArtifact>
- <outputDirectory>lib</outputDirectory>
- <directoryMode>0770</directoryMode>
- <fileMode>0664</fileMode>
- <useTransitiveFiltering>true</useTransitiveFiltering>
- <excludes>
- <exclude>*:nifi-bootstrap</exclude>
- <exclude>*:nifi-property-protection-api</exclude>
- <exclude>*:nifi-property-protection-factory</exclude>
- <exclude>*:nifi-resources</exclude>
- <exclude>*:nifi-docs</exclude>
- <exclude>*:nifi-single-user-utils</exclude>
- <exclude>*:nifi-flow-encryptor</exclude>
- <!-- exclude AspectJ library from lib included in the aspectj
subdir -->
- <exclude>org.aspectj:aspectjweaver</exclude>
- </excludes>
- </dependencySet>
- </dependencySets>
-
</assembly>
diff --git a/nifi-assembly/src/main/assembly/ranger.xml
b/nifi-assembly/src/main/assembly/ranger.xml
index 68baf6a3a5..134d7811ac 100644
--- a/nifi-assembly/src/main/assembly/ranger.xml
+++ b/nifi-assembly/src/main/assembly/ranger.xml
@@ -24,27 +24,11 @@
<baseDirectory>nifi-${project.version}</baseDirectory>
<componentDescriptors>
+ <componentDescriptor>src/main/assembly/core.xml</componentDescriptor>
<componentDescriptor>src/main/assembly/common.xml</componentDescriptor>
</componentDescriptors>
<dependencySets>
- <!-- Write out all dependency artifacts to lib directory, exclude
Ranger dependencies -->
- <dependencySet>
- <scope>runtime</scope>
- <useProjectArtifact>false</useProjectArtifact>
- <outputDirectory>lib</outputDirectory>
- <directoryMode>0770</directoryMode>
- <fileMode>0660</fileMode>
- <useTransitiveFiltering>true</useTransitiveFiltering>
- <excludes>
- <exclude>*:nifi-bootstrap</exclude>
- <exclude>*:nifi-property-protection-api</exclude>
- <exclude>*:nifi-property-protection-factory</exclude>
- <exclude>*:nifi-resources</exclude>
- <exclude>*:nifi-docs</exclude>
- <exclude>org.apache.nifi:nifi-ranger-resources:jar</exclude>
- </excludes>
- </dependencySet>
<!-- Write out dependencies for Ranger's credentialbuilder to
ext/ranger/install/lib -->
<dependencySet>
<scope>runtime</scope>