Project build error: Non-resolvable parent POM in maven - pom.xml

Project build error: Non-resolvable parent POM guide.ide.eclipse:guide-ide-eclipses:1.0-SNAPSHOT for guide.ide.eclipse:guide-ide-eclipse:0.0.1-SNAPSHOT: Failed to resolve POM for guide.ide.eclipse:guide-ide-eclipses:1.0-SNAPSHOT due to Missing:
1) guide.ide.eclipse:guide-ide-eclipses:pom:1.0-SNAPSHOT
1 required artifact is missing.
for artifact:
guide.ide.eclipse:guide-ide-eclipses:pom:1.0-SNAPSHOT
from the specified remote repositories:
central (http://repo1.maven.org/maven2, releases=true, snapshots=false)

Bit late in answering this but... as I've been bitten this afternoon by something similar...
Have you checked out How do I use Maven through a proxy?
The answers there are pretty helpful and relate to proxy issues which may relate to your problem. My own answer there relates to "parent not found" and "parent.relativeParent points to wrong local POM" errors where the parent pom actually resides in a remote repository. I've documented the various attempts I made to resolve this issue (with credits), ultimately changing how I configured the proxy for maven.

My friend was getting the same error. Actually he was connected to his companies VPN. He just disconnected with the VPN and then force updated the project and it started working fine.

Related

How to read settings from Jenkins in Gradle?

I use Jenkins to build Gradle, but there was a problem when reading the settings.
I use the 'net.linguica.maven-settings' plugin and in build.gradle wrote the line:
mavenSettings { userSettingsFileName = project.property('maven.settings.location) }
And now I can run the build like this:
gradle -Pmaven.settings.location=/u01/test.xml clean build publish
But when building, I get dependency errors.
Could not resolve org.springframework.boot:spring-boot-configuration-processor:2.1.6.RELEASE.
Required by:
project :
Skipped due to earlier error
Could not resolve org.junit.jupiter:junit-jupiter-api:5.8.0.
What do I need to do?
Maven doesn't intrinsically know where to get dependencies from. It will look to the setting.xml for a list of repositories and look for any dependencies from there. If you list multiple repositories is will check each one until it finds the dependencies listed in the pom file.
I suspect because you are overriding the settings the file you are using doesn't have a repository listed which has the dependency you need.
That is what the error message is telling you - "I looked though all the registries I know about but couldn't find org.junit.jupiter:junit-jupiter-api:5.8.0 in any of them"
You can read a bit about it here https://maven.apache.org/settings.html under "Repositories"

Why is Grails completely broken since Sunday and why is no one noticing?

Since Sunday, I and my co-worker cannot build any Grails project nor even create a new Grails app of any version. We have completely independent development environments.
For example:
$ grails create-app --profile web junk
| Error Error occurred running Grails CLI: Could not find artifact org.grails:grails-bom:pom:4.0.10 in grailsCentral (https://repo.grails.org/grails/core) (Use --stacktrace to see the full trace)
./gradlew dependencies also fails with Could not find org.grails:grails-gradle-model:3.2.13).
The repository repo.grails.org is up, but when I browse it, it is very slow and missing many, many artifacts.
Is their a way to configure build.gradle to fix this? We have several Grails projects using different versions, mostly using the default repository configuration.
There's actually been some discussion here on stackoverflow, but more on a github issue: https://github.com/grails/grails-core/issues/11825
You can certainly read that issue for far more info than makes sense to post here, but the short version is: URL changed unintentionally, temporary workaround is to move to https://repo.grails.org/artifactory/core
I guess we have an official message related to this issue in grails blog - https://grails.org/blog/2021-06-10-grails-wrapper-update.html

Jenkins build breaks on SaxParsing xsd scheme

i have a maven2 project which is built periodically by jenkins. The bad thing about it ... it won´t build anymore.
I´m not sure what has changed, because i don´t have any tickets in the code itself or jenkins configuration, but strange as it is..... the local build works.
Normally that would hint on a configuration problem in jenkins, but the error in jenkins is:
[ERROR] XJC while parsing schema(s) file:/global/contint/build_server/jenkins/jobs/ERIC_E4N%20Continuous-Trunk-Check/workspace/Eric4N-publishing-xsd/src/main/resources/E4N_E4D_InterfaceSalesAllowanceDoType.xsd[76,14]: org.xml.sax.SAXParseException: 'SalesAllowanceDoType' is already defined
Locally I don´t get this error....
Any clues where I could continue my search ?
Thanks alot and Greetings !

Maven dependency resolution fails because properties are not substituted

We've been working on a maven (3.0.5) project for a couple of months now, and suddenly we're getting this error when establishing new dev environments (without a local maven repository):
[ERROR] Failed to execute goal on project [100's of dependencies truncated]: Failed to read artifact descriptor for org.apache.httpcomponents:httpclient:jar:${httpcomponents.version}: Could not transfer artifact org.apache.httpcomponents:httpclient:pom:${httpcomponents.version} from/to nexus (http://bob.premitech.net:8081/nexus/content/groups/public): Illegal character in path at index 96: http://bob.premitech.net:8081/nexus/content/groups/public/org/apache/httpcomponents/httpclient/${httpcomponents.version}/httpclient-${httpcomponents.version}.pom -> [Help 1]
I'm using a multi-module project, and the obvious thing you might think is wrong is that ${httpcomponents.version} isn't defined. Except it is defined as 4.2.5 in the parent pom. Even wierder, hardcoding the version instead of using the property does not change the error message.
I've even tried removing the http components dependency entirely. This also does nothing. The only thing that does work is manually copying the correct dependency into the local maven repository (.m2), which completely defeats the purpose of using maven in the first place.
Does anybody have the slightest idea what could be wrong here? Is there some kind of caching mechanism I'm not aware of?
As you said, even hard-coding the version in your POM still giving you such error, it seems to me that the "incorrect" version is coming from other dependencies transitively. IIRC, place holders of dependencies are not replaced in Maven.
For example, your foo project is depending on your own bar-framework, both foo and bar-framework is depending on httpcomponent. In bar-framework you are also using property place holder for the version. In such case , if you built bar-framework in that new machine with problem, for which the bar-framework POM contains the un-substituted property of httpcomponent version. Then even your foo project is correct, Maven will still need to resolve the incorrect httpcomponent because of transitive dependency.
Try to do mvn dependency:tree to see how you are getting the dependency in your project. This may give some hints.

Shrinkwrap resolver plugin behind proxy

I am using the 2.0.0-alpha-1 version of shrinkwrap-resolver-bom in my POM file. When I try to execute Arquillian test cases, it seems Shrinkwrap resolver suffers the presence of company proxy in that the deployment is very, very slow due to long timeout for artifact tranfer operations. I keep getting org.jboss.shrinkwrap.resolver.impl.maven.LogTransferListerer transferFailed.
I found Arquillian/Shrinkwrap MavenDependencyResolver behind proxy explaining what to do with version 1.0.0, I guess, but I don't know what how to handle this with version 2.0.0.
Any suggestions?
Thanks
Massimo
Quick and dirty solution:
add the missing Shrinkwrap dependencies in your pom, so that Maven will download them and install them in your local repository (+ Nexus if you have one)
remove the previously added dependencies in the pom. Now that the dependencies are in the local repo, shrinkwrap should find them without trying to connect to Maven Central

Resources