码农知识堂 - 1000bd
  •   Python
  •   PHP
  •   JS/TS
  •   JAVA
  •   C/C++
  •   C#
  •   GO
  •   Kotlin
  •   Swift
  • 【IDEA使用maven package时,出现依赖不存在以及无法从仓库获取本地依赖的问题】


    Install Parent project

    在这里插入图片描述
    在这里插入图片描述

    C:\Users\lxh\.jdks\corretto-1.8.0_362\bin\java.exe -Dmaven.multiModuleProjectDirectory=D:\学习\projectFile\study\study_example_service "-Dmaven.home=D:\Program Files\JetBrains\IntelliJ IDEA2021\plugins\maven\lib\maven3" "-Dclassworlds.conf=D:\Program Files\JetBrains\IntelliJ IDEA2021\plugins\maven\lib\maven3\bin\m2.conf" "-Dmaven.ext.class.path=D:\Program Files\JetBrains\IntelliJ IDEA2021\plugins\maven\lib\maven-event-listener.jar" "-javaagent:D:\Program Files\JetBrains\IntelliJ IDEA2021\lib\idea_rt.jar=63004:D:\Program Files\JetBrains\IntelliJ IDEA2021\bin" -Dfile.encoding=UTF-8 -classpath "D:\Program Files\JetBrains\IntelliJ IDEA2021\plugins\maven\lib\maven3\boot\plexus-classworlds-2.6.0.jar;D:\Program Files\JetBrains\IntelliJ IDEA2021\plugins\maven\lib\maven3\boot\plexus-classworlds.license" org.codehaus.classworlds.Launcher -Didea.version=2021.1 -s D:\software\apache-maven-3.8.4\conf\settings.xml -Dmaven.repo.local=D:\software\apache-maven-3.8.4\mvn_resp -DskipTests=true package
    [WARNING] 
    [WARNING] Some problems were encountered while building the effective settings
    [WARNING] Unrecognised tag: 'blocked' (position: START_TAG seen ...</url>\r\n      <blocked>... @184:16)  @ D:\software\apache-maven-3.8.4\conf\settings.xml, line 184, column 16
    [WARNING] 
    [INFO] Scanning for projects...
    [INFO] 
    [INFO] -------------------< com.lxh:study_example_service >--------------------
    [INFO] Building study_example_service 1.0.0
    [INFO] --------------------------------[ jar ]---------------------------------
    [WARNING] The POM for com.lxh:study_common:jar:1.0.0 is missing, no dependency information available
    [WARNING] The POM for com.lxh:study_dao:jar:1.0.0 is missing, no dependency information available
    [WARNING] The POM for com.lxh:study_utils:jar:1.0.0 is missing, no dependency information available
    [WARNING] The POM for com.alibaba:druid:jar:1.2.11 is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
    [WARNING] The artifact mysql:mysql-connector-java:jar:8.0.32 has been relocated to com.mysql:mysql-connector-j:jar:8.0.32
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time:  5.503 s
    [INFO] Finished at: 2023-11-01T17:38:52+08:00
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal on project study_example_service: Could not resolve dependencies for project com.lxh:study_example_service:jar:1.0.0: The following artifacts could not be resolved: com.lxh:study_common:jar:1.0.0, com.lxh:study_dao:jar:1.0.0, com.lxh:study_utils:jar:1.0.0: Failure to find com.lxh:study_common:jar:1.0.0 in http://maven.aliyun.com/nexus/content/groups/public was cached in the local repository, resolution will not be reattempted until the update interval of alimaven has elapsed or updates are forced -> [Help 1]
    [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/DependencyResolutionException
    
    进程已结束,退出代码为 1
    
    
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
    • 7
    • 8
    • 9
    • 10
    • 11
    • 12
    • 13
    • 14
    • 15
    • 16
    • 17
    • 18
    • 19
    • 20
    • 21
    • 22
    • 23
    • 24
    • 25
    • 26
    • 27
    • 28
    • 29
    • 30
    • 31

    解决

    在父项目(root)pom依赖中加入标签,之前没加。

        <build>
            <pluginManagement>
                <plugins>
                    <plugin>
                        <groupId>org.springframework.bootgroupId>
                        <artifactId>spring-boot-maven-pluginartifactId>
                    plugin>
                plugins>
            pluginManagement>
        build>
    
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
    • 7
    • 8
    • 9
    • 10

    相关博客:
    https://blog.csdn.net/qq_39826207/article/details/123917550
    https://blog.csdn.net/qq_41988159/article/details/124761291
    maven标签的作用:
    https://blog.csdn.net/qq_27022241/article/details/108978554?ops_request_misc=%257B%2522request%255Fid%2522%253A%2522169890834816777224460914%2522%252C%2522scm%2522%253A%252220140713.130102334…%2522%257D&request_id=169890834816777224460914&biz_id=0&utm_medium=distribute.pc_search_result.none-task-blog-2allsobaiduend~default-1-108978554-null-null.142v96pc_search_result_base6&utm_term=pluginmanagement%E6%A0%87%E7%AD%BE&spm=1018.2226.3001.4187

    觉得对你有帮助点个赞哦爱你

  • 相关阅读:
    【Android学习】日期和时间选择对话框
    溶于乙醇的碳量子点CQDs,发射波长420nm,535nm,565nm,505nm,675nm
    软件设计模式总结
    进击的Mini LED:群雄逐“屏”,谁主沉浮
    在十四届蓝桥杯开赛前一星期开始复习
    数字化转型大潮下,企业如何做好绩效管理?
    X-Model传播模型3D仿真 在5G室内外协同规划中应用与研究
    展技术实力,筑元宇宙安全,零时科技成为首批湾区元宇宙联盟成员
    【机器学习-周志华】学习笔记-第八章
    NL2SQL技术方案系列(5):金融领域NL2SQL技术方案以及行业案例实战讲解3--非LLM技术方案
  • 原文地址:https://blog.csdn.net/sinat_37828702/article/details/134166617
  • 最新文章
  • 攻防演习之三天拿下官网站群
    数据安全治理学习——前期安全规划和安全管理体系建设
    企业安全 | 企业内一次钓鱼演练准备过程
    内网渗透测试 | Kerberos协议及其部分攻击手法
    0day的产生 | 不懂代码的"代码审计"
    安装scrcpy-client模块av模块异常,环境问题解决方案
    leetcode hot100【LeetCode 279. 完全平方数】java实现
    OpenWrt下安装Mosquitto
    AnatoMask论文汇总
    【AI日记】24.11.01 LangChain、openai api和github copilot
  • 热门文章
  • 十款代码表白小特效 一个比一个浪漫 赶紧收藏起来吧!!!
    奉劝各位学弟学妹们,该打造你的技术影响力了!
    五年了,我在 CSDN 的两个一百万。
    Java俄罗斯方块,老程序员花了一个周末,连接中学年代!
    面试官都震惊,你这网络基础可以啊!
    你真的会用百度吗?我不信 — 那些不为人知的搜索引擎语法
    心情不好的时候,用 Python 画棵樱花树送给自己吧
    通宵一晚做出来的一款类似CS的第一人称射击游戏Demo!原来做游戏也不是很难,连憨憨学妹都学会了!
    13 万字 C 语言从入门到精通保姆级教程2021 年版
    10行代码集2000张美女图,Python爬虫120例,再上征途
Copyright © 2022 侵权请联系2656653265@qq.com    京ICP备2022015340号-1
正则表达式工具 cron表达式工具 密码生成工具

京公网安备 11010502049817号