]> source.dussan.org Git - aspectj.git/commitdiff
Remove Apache Commons from 'lib' module, update remaining dependencies
authorAlexander Kriegisch <Alexander@Kriegisch.name>
Fri, 15 Mar 2024 11:17:48 +0000 (12:17 +0100)
committerAlexander Kriegisch <Alexander@Kriegisch.name>
Fri, 15 Mar 2024 18:27:30 +0000 (19:27 +0100)
Of beanutils, collections, digester and logging actually only digester
and logging are directly used in AspectJ code. Therefore, remove the
unused ones and upgrade the remaining libraries' versions to ones which
also have source JARs on Maven Central. This makes downloading sources
from GitHub and packaging separate commons.jar and commons-src.zip
artifacts superfluous. Hence, we can get rid of them completely.

Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
.gitignore
lib/pom.xml
org.aspectj.matcher/pom.xml
pom.xml
testing/pom.xml
testing/src/test/java/org/aspectj/testing/AutowiredXMLBasedAjcTestCase.java
testing/src/test/java/org/aspectj/testing/MakeTestClass.java
testing/src/test/java/org/aspectj/testing/XMLBasedAjcTestCase.java
testing/src/test/java/org/aspectj/testing/xml/AjcSpecXmlReader.java
testing/src/test/java/org/aspectj/testing/xml/MessageListXmlReader.java

index 043448a8578f0e457ebe9030cd98dbb9f5b0a8bf..21ffd64edca31d8b05b08e02f02a0afac9090d60 100644 (file)
@@ -34,7 +34,6 @@ bin/
 # Downloaded libraries used during tests + marker file
 /lib/provisioned.marker
 /lib/ant/
-/lib/commons/
 /lib/jarjar/
 /lib/jdtcore-aj/
 /lib/junit/
index ff1fcc251bc24f85291859a708dd46bdbe246c63..86d89e040539db6c2e80c88b06f0283be4b3cc7d 100644 (file)
                   <sha1>b9f3c8c31bb6c9069ad5b655059a17769af12f20</sha1>
                 </configuration>
               </execution>
-              <execution>
-                <id>download-beanutils-sources</id>
-                <phase>generate-resources</phase>
-                <goals>
-                  <goal>wget</goal>
-                </goals>
-                <configuration>
-                  <url>https://github.com/apache/commons-beanutils/archive/refs/tags/${lib.commons.beanutils.tag}.zip</url>
-                  <outputDirectory>commons</outputDirectory>
-                  <outputFileName>commons-beanutils-${lib.commons.beanutils.version}-sources.jar</outputFileName>
-                  <sha1>b2c02afe7e6475cd7c811932b8415d171a8afa00</sha1>
-                </configuration>
-              </execution>
-              <execution>
-                <id>download-collections-sources</id>
-                <phase>generate-resources</phase>
-                <goals>
-                  <goal>wget</goal>
-                </goals>
-                <configuration>
-                  <url>https://github.com/apache/commons-collections/archive/refs/tags/${lib.commons.collections.tag}.zip</url>
-                  <outputDirectory>commons</outputDirectory>
-                  <outputFileName>commons-collections-${lib.commons.collections.version}-sources.jar</outputFileName>
-                  <sha1>824cacd0aafe21a94fb142388fd62f28a12df5ef</sha1>
-                </configuration>
-              </execution>
-              <execution>
-                <id>download-digester-sources</id>
-                <phase>generate-resources</phase>
-                <goals>
-                  <goal>wget</goal>
-                </goals>
-                <configuration>
-                  <url>https://github.com/apache/commons-digester/archive/refs/tags/${lib.commons.digester.tag}.zip</url>
-                  <outputDirectory>commons</outputDirectory>
-                  <outputFileName>commons-digester-${lib.commons.digester.version}-sources.jar</outputFileName>
-                  <sha1>49f653c7ea726301c564f9662b72c051fee9390a</sha1>
-                </configuration>
-              </execution>
-              <execution>
-                <id>download-logging-sources</id>
-                <phase>generate-resources</phase>
-                <goals>
-                  <goal>wget</goal>
-                </goals>
-                <configuration>
-                  <url>https://github.com/apache/commons-logging/archive/refs/tags/${lib.commons.logging.tag}.zip</url>
-                  <outputDirectory>commons</outputDirectory>
-                  <outputFileName>commons-logging-${lib.commons.logging.version}-sources.jar</outputFileName>
-                  <sha1>c61a373f6d50ff8fcfba900934f7254d44f9735b</sha1>
-                </configuration>
-              </execution>
             </executions>
           </plugin>
 
                       <destFileName>jakarta-regexp-1.2.jar</destFileName>
                     </artifactItem>
 
-                    <!--
-                      About commons.jar + commons-src.zip:
-                        - Beanutils Binaries are commons-beanutils:commons-beanutils:1.4 (no sources on Maven Central, but
-                          https://github.com/apache/commons-beanutils/archive/refs/tags/BEANUTILS_1_4.zip)
-                        - Collections: Binaries are commons-collections:commons-collections:2.0 (no sources on Maven Central, but
-                          https://github.com/apache/commons-collections/archive/refs/tags/collections-2.0.zip)
-                        - Digester: Binaries are commons-digester:commons-digester:1.3 (no sources on Maven Central, but
-                          https://github.com/apache/commons-digester/archive/refs/tags/DIGESTER_1_3.zip)
-                        - Logging: Binaries are commons-logging:commons-logging:1.0.1 (no sources on Maven Central, but
-                          https://github.com/apache/commons-logging/archive/refs/tags/LOGGING_1_0_1.zip)
-                    -->
-                    <artifactItem>
-                      <!-- Binary is identical to committed version -->
-                      <!-- TODO: not used anywhere -> remove -->
-                      <groupId>commons-beanutils</groupId>
-                      <artifactId>commons-beanutils</artifactId>
-                      <version>${lib.commons.beanutils.version}</version>
-                      <type>jar</type>
-                      <overWrite>false</overWrite>
-                      <outputDirectory>commons</outputDirectory>
-                      <destFileName>commons-beanutils-${lib.commons.beanutils.version}.jar</destFileName>
-                    </artifactItem>
-                    <artifactItem>
-                      <!-- Binary is identical to committed version -->
-                      <!-- TODO: not used anywhere -> remove -->
-                      <groupId>commons-collections</groupId>
-                      <artifactId>commons-collections</artifactId>
-                      <version>2.0</version>
-                      <type>jar</type>
-                      <overWrite>false</overWrite>
-                      <outputDirectory>commons</outputDirectory>
-                      <destFileName>commons-collections-2.0.jar</destFileName>
-                    </artifactItem>
-                    <artifactItem>
-                      <!-- Binary is identical to committed version -->
-                      <!-- TODO: used in module 'testing' -->
-                      <groupId>commons-digester</groupId>
-                      <artifactId>commons-digester</artifactId>
-                      <version>${lib.commons.digester.version}</version>
-                      <type>jar</type>
-                      <overWrite>false</overWrite>
-                      <outputDirectory>commons</outputDirectory>
-                      <destFileName>commons-digester-${lib.commons.digester.version}.jar</destFileName>
-                    </artifactItem>
-                    <artifactItem>
-                      <!-- Binary is identical to committed version -->
-                      <!-- TODO: used in modules 'org.aspectj.matcher' -->
-                      <groupId>commons-logging</groupId>
-                      <artifactId>commons-logging</artifactId>
-                      <version>${lib.commons.logging.version}</version>
-                      <type>jar</type>
-                      <overWrite>false</overWrite>
-                      <outputDirectory>commons</outputDirectory>
-                      <destFileName>commons-logging-${lib.commons.logging.version}.jar</destFileName>
-                    </artifactItem>
-
                   </artifactItems>
                 </configuration>
               </execution>
                   </fileset>
                 </configuration>
               </execution>
-              <execution>
-                <id>zip-beanutils-binaries</id>
-                <phase>process-resources</phase>
-                <goals>
-                  <goal>copy</goal>
-                </goals>
-                <configuration>
-                  <verbose>true</verbose>
-                  <fileset>
-                    <directory>commons/commons-beanutils-${lib.commons.beanutils.version}.jar</directory>
-                    <outputDirectory>commons/commons.jar</outputDirectory>
-                  </fileset>
-                </configuration>
-              </execution>
-              <execution>
-                <id>zip-collections-binaries</id>
-                <phase>process-resources</phase>
-                <goals>
-                  <goal>copy</goal>
-                </goals>
-                <configuration>
-                  <verbose>true</verbose>
-                  <fileset>
-                    <directory>commons/commons-collections-${lib.commons.collections.version}.jar</directory>
-                    <outputDirectory>commons/commons.jar</outputDirectory>
-                  </fileset>
-                </configuration>
-              </execution>
-              <execution>
-                <id>zip-digester-binaries</id>
-                <phase>process-resources</phase>
-                <goals>
-                  <goal>copy</goal>
-                </goals>
-                <configuration>
-                  <verbose>true</verbose>
-                  <fileset>
-                    <directory>commons/commons-digester-${lib.commons.digester.version}.jar</directory>
-                    <outputDirectory>commons/commons.jar</outputDirectory>
-                  </fileset>
-                </configuration>
-              </execution>
-              <execution>
-                <id>zip-logging-binaries</id>
-                <phase>process-resources</phase>
-                <goals>
-                  <goal>copy</goal>
-                </goals>
-                <configuration>
-                  <verbose>true</verbose>
-                  <fileset>
-                    <directory>commons/commons-logging-${lib.commons.logging.version}.jar</directory>
-                    <outputDirectory>commons/commons.jar</outputDirectory>
-                  </fileset>
-                </configuration>
-              </execution>
-              <execution>
-                <id>zip-beanutils-sources</id>
-                <phase>process-resources</phase>
-                <goals>
-                  <goal>copy</goal>
-                </goals>
-                <configuration>
-                  <verbose>true</verbose>
-                  <fileset>
-                    <directory>commons/commons-beanutils-${lib.commons.beanutils.version}-sources.jar/commons-beanutils-${lib.commons.beanutils.tag}/src/java</directory>
-                    <outputDirectory>commons/commons-src.zip</outputDirectory>
-                  </fileset>
-                </configuration>
-              </execution>
-              <execution>
-                <id>zip-collections-sources</id>
-                <phase>process-resources</phase>
-                <goals>
-                  <goal>copy</goal>
-                </goals>
-                <configuration>
-                  <verbose>true</verbose>
-                  <fileset>
-                    <directory>commons/commons-collections-${lib.commons.collections.version}-sources.jar/commons-collections-${lib.commons.collections.tag}/src/java</directory>
-                    <outputDirectory>commons/commons-src.zip</outputDirectory>
-                  </fileset>
-                </configuration>
-              </execution>
-              <execution>
-                <id>zip-digester-sources</id>
-                <phase>process-resources</phase>
-                <goals>
-                  <goal>copy</goal>
-                </goals>
-                <configuration>
-                  <verbose>true</verbose>
-                  <fileset>
-                    <directory>commons/commons-digester-${lib.commons.digester.version}-sources.jar/commons-digester-${lib.commons.digester.tag}/src/java</directory>
-                    <outputDirectory>commons/commons-src.zip</outputDirectory>
-                  </fileset>
-                </configuration>
-              </execution>
-              <execution>
-                <id>zip-logging-sources</id>
-                <phase>process-resources</phase>
-                <goals>
-                  <goal>copy</goal>
-                </goals>
-                <configuration>
-                  <verbose>true</verbose>
-                  <fileset>
-                    <directory>commons/commons-logging-${lib.commons.logging.version}-sources.jar/commons-logging-${lib.commons.logging.tag}/src/java</directory>
-                    <outputDirectory>commons/commons-src.zip</outputDirectory>
-                  </fileset>
-                </configuration>
-              </execution>
             </executions>
           </plugin>
 
                       <includes>
                         <include>${lib.provisioned.marker}</include>
                         <include>ant/**</include>
-                        <include>commons/**</include>
                         <include>jarjar/**</include>
                         <include>jdtcore-aj/**</include>
                         <include>junit/**</include>
                     <file>${lib.provisioned.marker}</file>
                     <file>ant/bin/ant.bat</file>
                     <file>ant/lib/junit.jar</file>
-                    <file>commons/commons.jar</file>
                     <file>jarjar/jarjar-1.3.jar</file>
                     <file>jdtcore-aj/jdtcore-for-aspectj.jar</file>
                     <file>junit/junit.jar</file>
index 96d0bf7f3acfa5ab9889a83f21cc891d05ec812a..251c75e011ea9912aa058a264fe03d41f91cd214 100644 (file)
@@ -31,7 +31,7 @@
     <dependency>
       <groupId>commons-logging</groupId>
       <artifactId>commons-logging</artifactId>
-      <version>${lib.commons.logging.version}</version>
+      <version>${commons.logging.version}</version>
     </dependency>
   </dependencies>
 
diff --git a/pom.xml b/pom.xml
index 01a0b5699bb58bd61ab90bf575ab2ad4e3716549..15319c20bc416f01e89d08f0f119daacecfe9a08 100644 (file)
--- a/pom.xml
+++ b/pom.xml
                <!-- Dependency versions -->
                <jdt.core.version>1.9.21.1</jdt.core.version> <!-- AspectJ_JDK_Update -->
                <asm.version>9.6</asm.version> <!-- AspectJ_JDK_Update -->
+               <commons.digester.version>3.2</commons.digester.version>
+               <commons.logging.version>1.3.0</commons.logging.version>
                <lib.ant.version>1.6.3</lib.ant.version>
                <lib.ant.xerces.version>2.6.2</lib.ant.xerces.version>
                <lib.regexp.version>1.2</lib.regexp.version>
-               <lib.commons.beanutils.version>1.4</lib.commons.beanutils.version>
-               <lib.commons.beanutils.tag>BEANUTILS_1_4</lib.commons.beanutils.tag>
-               <lib.commons.collections.version>2.0</lib.commons.collections.version>
-               <lib.commons.collections.tag>collections-2.0</lib.commons.collections.tag>
-               <lib.commons.digester.version>1.3</lib.commons.digester.version>
-               <lib.commons.digester.tag>DIGESTER_1_3</lib.commons.digester.tag>
-               <lib.commons.logging.version>1.0.1</lib.commons.logging.version>
-               <lib.commons.logging.tag>LOGGING_1_0_1</lib.commons.logging.tag>
        </properties>
 
        <distributionManagement>
                                <artifactId>org.eclipse.jdt.core</artifactId>
                                <version>${jdt.core.version}</version>
                        </dependency>
-                       <dependency>
-                               <!-- Because commons-digester:commons-digester:1.3 refers to version 1.4-dev -->
-                               <groupId>commons-beanutils</groupId>
-                               <artifactId>commons-beanutils</artifactId>
-                               <version>${lib.commons.beanutils.version}</version>
-                       </dependency>
                        <dependency>
                                <groupId>org.ow2.asm</groupId>
                                <artifactId>asm</artifactId>
index 80d3bf16b5bf20de2d77c79d3a711d7993b76836..91e175fb0ce59aaa1ef5081088bf8a9a2bb61a16 100644 (file)
       <version>${lib.ant.xerces.version}</version>
     </dependency>
     <dependency>
-      <groupId>commons-digester</groupId>
-      <artifactId>commons-digester</artifactId>
-      <version>${lib.commons.digester.version}</version>
+      <groupId>org.apache.commons</groupId>
+      <artifactId>commons-digester3</artifactId>
+      <version>${commons.digester.version}</version>
     </dependency>
     <dependency>
       <groupId>org.aspectj</groupId>
     <dependency>
       <groupId>commons-logging</groupId>
       <artifactId>commons-logging</artifactId>
-      <version>${lib.commons.logging.version}</version>
+      <version>${commons.logging.version}</version>
     </dependency>
   </dependencies>
 
index 3769f9326e5affc19a9fa8608043ea72f1951668..6be56d2c91c9151e10e050d4a79f0767c6d8d9e8 100644 (file)
@@ -15,7 +15,7 @@ import java.lang.reflect.Method;
 import java.util.HashMap;
 import java.util.Map;
 
-import org.apache.commons.digester.Digester;
+import org.apache.commons.digester3.Digester;
 import org.aspectj.tools.ajc.Ajc;
 
 import junit.extensions.TestSetup;
index 91cee0ea28e9a6900956fb69dbf4da49127defaa..2a55adff7d2f25752b242f5005c623f7a087f6fd 100644 (file)
@@ -12,7 +12,7 @@ import java.text.NumberFormat;
 import java.util.ArrayList;
 import java.util.List;
 
-import org.apache.commons.digester.Digester;
+import org.apache.commons.digester3.Digester;
 
 /**
  * @author colyer
index 440bd9821373ffe906fc65f09a81d8fb009b2c20..fa164313e363b4d10964c82b51562470c3e8334f 100644 (file)
@@ -28,7 +28,7 @@ import java.util.Map;
 import java.util.Stack;
 
 import junit.framework.TestCase;
-import org.apache.commons.digester.Digester;
+import org.apache.commons.digester3.Digester;
 import org.aspectj.apache.bcel.classfile.Attribute;
 import org.aspectj.apache.bcel.classfile.JavaClass;
 import org.aspectj.apache.bcel.classfile.LocalVariable;
index af822c478e158ba95b76f973a3082ce07320872c..078624b98d70d6422aaa5f8d6c32399f2f9cb964 100644 (file)
@@ -23,7 +23,7 @@ import java.io.FileWriter;
 import java.io.IOException;
 import java.io.PrintWriter;
 
-import org.apache.commons.digester.Digester;
+import org.apache.commons.digester3.Digester;
 import org.aspectj.bridge.AbortException;
 import org.aspectj.bridge.IMessage;
 import org.aspectj.bridge.ISourceLocation;
index 46352a0a2740ed180fc9d6eb0c81e0aca6f1e306..6e3584c467d2e7bda5ca12c0fd4c262b543c0b51 100644 (file)
@@ -20,7 +20,7 @@ import java.io.PrintWriter;
 import java.util.ArrayList;
 import java.util.List;
 
-import org.apache.commons.digester.Digester;
+import org.apache.commons.digester3.Digester;
 import org.aspectj.bridge.AbortException;
 import org.aspectj.bridge.IMessage;
 import org.aspectj.bridge.ISourceLocation;
@@ -210,6 +210,3 @@ public class MessageListXmlReader {
     }
 
 }
-
-
-