Maven: Non-resolvable parent POM

后端 未结 14 1556
一整个雨季
一整个雨季 2020-12-02 11:04

I have my maven project setup as 1 shell projects and 4 children modules. When I try to build the shell. I get:

[INFO] Scanning for projects...
[ERROR] The b         


        
14条回答
  •  长情又很酷
    2020-12-02 11:22

    Alternative reason also might be the parent artifact comes from repository which is not accessible from pom.xml, typically private repository. The solution was to provide that repository in pom.xml:

    
        
            internal-repo
            internal repository
            https://my/private/repo
            default
            
                true
            
            
                true
            
        
    
    

    In my case the problem was even more complicated due to Eclipse: the repository was active only in special profile (activate-private-repo...) and Maven GUI in Eclipse didn't allow to set this profile through Ctrl+Alt+P shortcut.

    The solution was to temporarily declare repository outside profile (unconditionally), launch Alt+F5 Maven Update Project, activate profile and put repository declaration back into profile. This is rather Eclipse bug, not Maven bug.

提交回复
热议问题