Skip to content

Commit

Permalink
Convert odl-apache-shiro to template-feature-parent
Browse files Browse the repository at this point in the history
Using a template here allows us to properly disconnect build-time
dependency graph from packaged bundles: we no longer need to specify
exclusions all over the place.

Change-Id: Ia8f3c32f65ae00212bd397f35b092974409af3c7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
  • Loading branch information
rovarga committed Dec 3, 2024
1 parent 703d92b commit 1e9abd1
Show file tree
Hide file tree
Showing 8 changed files with 73 additions and 69 deletions.
12 changes: 0 additions & 12 deletions features/odl-aaa-password-service/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -44,24 +44,12 @@
<dependency>
<groupId>org.opendaylight.aaa</groupId>
<artifactId>aaa-password-service-impl</artifactId>
<exclusions>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.opendaylight.aaa</groupId>
<artifactId>aaa-password-service-impl</artifactId>
<classifier>aaa-password-service-config</classifier>
<type>xml</type>
<exclusions>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.opendaylight.aaa</groupId>
Expand Down
6 changes: 0 additions & 6 deletions features/odl-aaa-shiro/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,6 @@
<dependency>
<groupId>org.opendaylight.aaa</groupId>
<artifactId>aaa-jetty-auth-log-filter</artifactId>
<exclusions>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.opendaylight.aaa</groupId>
Expand Down
45 changes: 17 additions & 28 deletions features/odl-apache-shiro/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,53 +12,42 @@
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.opendaylight.odlparent</groupId>
<artifactId>single-feature-parent</artifactId>
<version>14.0.5</version>
<relativePath/>
<groupId>org.opendaylight.aaa</groupId>
<artifactId>template-feature-parent</artifactId>
<version>0.21.0-SNAPSHOT</version>
<relativePath>../parent</relativePath>
</parent>

<groupId>org.opendaylight.aaa</groupId>
<artifactId>odl-apache-shiro</artifactId>
<version>0.21.0-SNAPSHOT</version>
<packaging>feature</packaging>

<name>OpenDaylight :: Apache Shiro</name>
<description>Apache Shiro (repackaged)</description>

<properties>
<checkDependencyChange>true</checkDependencyChange>
<failOnDependencyChange>true</failOnDependencyChange>
</properties>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>aaa-artifacts</artifactId>
<version>${project.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<groupId>org.opendaylight.odlparent</groupId>
<artifactId>odl-servlet-api</artifactId>
<type>xml</type>
<classifier>features</classifier>
</dependency>

<dependency>
<groupId>commons-beanutils</groupId>
<artifactId>commons-beanutils</artifactId>
</dependency>
<dependency>
<groupId>commons-collections</groupId>
<artifactId>commons-collections</artifactId>
</dependency>
<dependency>
<groupId>org.opendaylight.aaa</groupId>
<artifactId>repackaged-shiro</artifactId>
<exclusions>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.owasp.encoder</groupId>
<artifactId>encoder</artifactId>
</dependency>
</dependencies>
</project>
13 changes: 0 additions & 13 deletions features/odl-apache-shiro/src/main/feature/feature.xml

This file was deleted.

11 changes: 11 additions & 0 deletions features/odl-apache-shiro/src/main/feature/template.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<features xmlns="http://karaf.apache.org/xmlns/features/v1.6.0" name="odl-apache-shiro">
<repository>mvn:org.opendaylight.odlparent/odl-servlet-api/{{versionAsInProject}}/xml/features</repository>
<feature name="odl-apache-shiro">
<feature version="[14,15)">odl-servlet-api</feature>
<bundle>mvn:org.opendaylight.aaa/repackaged-shiro/{{versionAsInProject}}</bundle>
<bundle>mvn:commons-beanutils/commons-beanutils/{{versionAsInProject}}</bundle>
<bundle>mvn:commons-collections/commons-collections/{{versionAsInProject}}</bundle>
<bundle>mvn:org.owasp.encoder/encoder/{{versionAsInProject}}</bundle>
</feature>
</features>
10 changes: 0 additions & 10 deletions features/odl-apache-shiro/src/main/history/dependencies.xml

This file was deleted.

44 changes: 44 additions & 0 deletions features/parent/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2024 PANTHEON.tech, s.r.o. and others. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v1.0 which accompanies this distribution,
and is available at http://www.eclipse.org/legal/epl-v10.html
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.opendaylight.odlparent</groupId>
<artifactId>template-feature-parent</artifactId>
<version>14.0.5</version>
<relativePath/>
</parent>

<groupId>org.opendaylight.aaa</groupId>
<artifactId>template-feature-parent</artifactId>
<version>0.21.0-SNAPSHOT</version>
<packaging>pom</packaging>
<name>${project.artifactId}</name>
<description>Feature parent (based on template-feature-parent)</description>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.opendaylight.aaa</groupId>
<artifactId>aaa-parent</artifactId>
<version>0.21.0-SNAPSHOT</version>
<scope>import</scope>
<type>pom</type>
</dependency>
</dependencies>
</dependencyManagement>

<scm>
<connection>scm:git:ssh://git.opendaylight.org:29418/aaa.git</connection>
<developerConnection>scm:git:ssh://git.opendaylight.org:29418/aaa.git</developerConnection>
<tag>HEAD</tag>
<url>https://git.opendaylight.org/gerrit/gitweb?p=aaa.git;a=summary</url>
</scm>
</project>
1 change: 1 addition & 0 deletions features/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
</properties>

<modules>
<module>parent</module>
<module>features-aaa</module>
<module>odl-aaa-api</module>
<module>odl-aaa-cert</module>
Expand Down

0 comments on commit 1e9abd1

Please sign in to comment.