Because we’d decided to build the source code, particularly a long range of versions, we had to decide where to acquire the sources from and use that as the source of truth to map version releases against.
Maven is a very effective toolchain in Java. It combines dependency management, repository synchronization, build, source code management (also known as version control), and a test execution tool. In fact, it’s useful even in retrieving sources for dependencies. However, repo.maven.apache.org doesn’t contain source code releases for Apache Struts versions where binaries are not available. Even for the binary releases that exist, not all versions provide a source jar on the repository or source included in the jar file. For example, version 2.0.5 doesn’t contain any sources.
We looked at the official web archives from Apache Struts, which didn’t provide a complete version listing either. However, at least it had sources for more versions than Maven did (such as 2.0.5). Further, when we trial-built versions of Struts to make some headway, a variety of issues in missing files caused the builds to fail on Maven.
We identified the Git repository for Struts as the best choice, since we could identify each release version based on the tags. From here we accurately identified 115 versions of Struts, and we no longer ran into the problem of missing files causing Maven to fail builds.