I have setup my environment for Sakai 19.0 from source following the guide on https://confluence.sakaiproject.org/pages/viewpage.action?pageId=109772882.
However when I try to build the source as detailed in 4.0 of the guide I am getting an error. Below are the logs with debug switched on:
C:\Users\Chitova\Desktop\Projects\sakai\master>mvn clean install
[INFO] Scanning for projects...
Downloading: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR] The project org.sakaiproject:master:19.0 (C:\Users\Chitova\Desktop\Projects\sakai\master\pom.xml) has 1 error
[ERROR] Non-resolvable parent POM: Could not transfer artifact org.sakaiproject:oss-parent:pom:1 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom. Return code is: 501 , ReasonPhrase:HTTPS Required. and 'parent.relativePath' points at no local POM @ line 5, column 11 -> [Help 2]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException
[ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException
C:\Users\Chitova\Desktop\Projects\sakai\master>mvn clean install -X
Apache Maven 3.2.5 (12a6b3acb947671f09b81f49094c53f426d8cea1; 2014-12-14T19:29:23+02:00)
Maven home: C:\Users\Chitova\Desktop\Projects\apache-maven-3.2.5\bin\..
Java version: 1.8.0_111, vendor: Oracle Corporation
Java home: C:\Program Files\Java\jdk1.8.0_111\jre
Default locale: en_GB, platform encoding: Cp1252
OS name: "windows 10", version: "10.0", arch: "amd64", family: "dos"
[INFO] Error stacktraces are turned on.
[DEBUG] Reading global settings from C:\Users\Chitova\Desktop\Projects\apache-maven-3.2.5\bin\..\conf\settings.xml
[DEBUG] Reading user settings from C:\Users\Chitova\.m2\settings.xml
[DEBUG] Using local repository at C:\Users\Chitova\.m2\repository
[DEBUG] Using manager EnhancedLocalRepositoryManager with priority 10.0 for C:\Users\Chitova\.m2\repository
[INFO] Scanning for projects...
[DEBUG] Using transporter WagonTransporter with priority -1.0 for http://repo1.maven.org/maven2
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for http://repo1.maven.org/maven2
Downloading: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom
[DEBUG] Writing tracking file C:\Users\Chitova\.m2\repository\org\sakaiproject\oss-parent\1\oss-parent-1.pom.lastUpdated
[ERROR] The build could not read 1 project -> [Help 1]
org.apache.maven.project.ProjectBuildingException: Some problems were encountered while processing the POMs:
[FATAL] Non-resolvable parent POM: Could not transfer artifact org.sakaiproject:oss-parent:pom:1 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom. Return code is: 501 , ReasonPhrase:HTTPS Required. and 'parent.relativePath' points at no local POM @ line 5, column 11
at org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:416)
at org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:672)
at org.apache.maven.DefaultMaven.getProjectsForMavenReactor(DefaultMaven.java:663)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:253)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:155)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:216)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:160)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
[ERROR]
[ERROR] The project org.sakaiproject:master:19.0 (C:\Users\Chitova\Desktop\Projects\sakai\master\pom.xml) has 1 error
[ERROR] Non-resolvable parent POM: Could not transfer artifact org.sakaiproject:oss-parent:pom:1 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom. Return code is: 501 , ReasonPhrase:HTTPS Required. and 'parent.relativePath' points at no local POM @ line 5, column 11 -> [Help 2]
org.apache.maven.model.resolution.UnresolvableModelException: Could not transfer artifact org.sakaiproject:oss-parent:pom:1 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom. Return code is: 501 , ReasonPhrase:HTTPS Required.
at org.apache.maven.project.ProjectModelResolver.resolveModel(ProjectModelResolver.java:195)
at org.apache.maven.project.ProjectModelResolver.resolveModel(ProjectModelResolver.java:244)
at org.apache.maven.model.building.DefaultModelBuilder.readParentExternally(DefaultModelBuilder.java:899)
at org.apache.maven.model.building.DefaultModelBuilder.readParent(DefaultModelBuilder.java:751)
at org.apache.maven.model.building.DefaultModelBuilder.build(DefaultModelBuilder.java:309)
at org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:463)
at org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:432)
at org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:396)
at org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:672)
at org.apache.maven.DefaultMaven.getProjectsForMavenReactor(DefaultMaven.java:663)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:253)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:155)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:216)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:160)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.eclipse.aether.resolution.ArtifactResolutionException: Could not transfer artifact org.sakaiproject:oss-parent:pom:1 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom. Return code is: 501 , ReasonPhrase:HTTPS Required.
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:444)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:246)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifact(DefaultArtifactResolver.java:223)
at org.eclipse.aether.internal.impl.DefaultRepositorySystem.resolveArtifact(DefaultRepositorySystem.java:294)
at org.apache.maven.project.ProjectModelResolver.resolveModel(ProjectModelResolver.java:191)
... 22 more
Caused by: org.eclipse.aether.transfer.ArtifactTransferException: Could not transfer artifact org.sakaiproject:oss-parent:pom:1 from/to central (http://repo1.maven.org/maven2): Failed to transfer file: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom. Return code is: 501 , ReasonPhrase:HTTPS Required.
at org.eclipse.aether.connector.basic.ArtifactTransportListener.transferFailed(ArtifactTransportListener.java:43)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$TaskRunner.run(BasicRepositoryConnector.java:355)
at org.eclipse.aether.util.concurrency.RunnableErrorForwarder$1.run(RunnableErrorForwarder.java:67)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$DirectExecutor.execute(BasicRepositoryConnector.java:581)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector.get(BasicRepositoryConnector.java:249)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.performDownloads(DefaultArtifactResolver.java:520)
at org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:421)
... 26 more
Caused by: org.apache.maven.wagon.TransferFailedException: Failed to transfer file: http://repo1.maven.org/maven2/org/sakaiproject/oss-parent/1/oss-parent-1.pom. Return code is: 501 , ReasonPhrase:HTTPS Required.
at org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.fillInputData(AbstractHttpClientWagon.java:1039)
at org.apache.maven.wagon.providers.http.AbstractHttpClientWagon.fillInputData(AbstractHttpClientWagon.java:977)
at org.apache.maven.wagon.StreamWagon.getInputStream(StreamWagon.java:116)
at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:88)
at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61)
at org.eclipse.aether.transport.wagon.WagonTransporter$GetTaskRunner.run(WagonTransporter.java:560)
at org.eclipse.aether.transport.wagon.WagonTransporter.execute(WagonTransporter.java:427)
at org.eclipse.aether.transport.wagon.WagonTransporter.get(WagonTransporter.java:404)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$GetTaskRunner.runTask(BasicRepositoryConnector.java:447)
at org.eclipse.aether.connector.basic.BasicRepositoryConnector$TaskRunner.run(BasicRepositoryConnector.java:350)
... 31 more
[ERROR]
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException
[ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException
C:\Users\Chitova\Desktop\Projects\sakai\master>
What could I be doing wrong?
On January 15, 2020 the Maven Central repository disabled access through HTTP (cf. Sonatype blog).
While recent version of Maven have the correct URL for Maven Central in their Super POM older ones might still use the HTTP URL. Upgrade your Maven installation or check whether your didn't override the Maven Central repository in your settings.xml
file.
The repository configuration should look like this:
<repository>
<id>central</id>
<name>Central Repository</name>
<url>https://repo.maven.apache.org/maven2</url>
<layout>default</layout>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>