Recently Maven build jobs running in Jenkins are failing with the below exception saying that they couldn\'t pull dependencies from Maven Central
Maven is moving to HTTPS and disabling HTTP access
Short story, from January 15, 2020, Maven Central repository is not longer supporting HTTP connections (other repositories are doing the same). Therefore, you will indicate your Maven/Gradle settings to use an HTTPS URL.
Solution:
You can choose one of the following three approaches.
Add a repository in your project´s pom.xml file
...
central maven repo
central maven repo https
https://repo.maven.apache.org/maven2
Add the repository into a profile in the settings.xml file.
my profile
central maven repo
central maven repo https
https://repo.maven.apache.org/maven2
For Gradle:
Only replace the URL for the HTTPS version.
repositories {
maven { url "https://repo.maven.apache.org/maven2" }
}