zoukankan      html  css  js  c++  java
  • intellij idea 用 Gradle新建 spring boot

    intellij idea用的是ideaIU-2017.1.4  。spring boot用的是2.10

    出现错误 

    ERROR StatusLogger Log4j2 could not find a logging implementation. Please add log4j-core to the classpath. Using SimpleLogger to log to the console...
    Exception in thread "main" java.lang.NoClassDefFoundError: ch/qos/logback/classic/Level
    at org.springframework.boot.logging.logback.LogbackLoggingSystem.<clinit>(LogbackLoggingSystem.java:70)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
    at org.springframework.boot.logging.LoggingSystem.get(LoggingSystem.java:170)
    at org.springframework.boot.logging.LoggingSystem.lambda$get$1(LoggingSystem.java:161)
    at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
    at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:175)
    at java.util.Collections$UnmodifiableMap$UnmodifiableEntrySet.lambda$entryConsumer$0(Collections.java:1575)
    at java.util.Spliterators$IteratorSpliterator.tryAdvance(Spliterators.java:1812)
    at java.util.Collections$UnmodifiableMap$UnmodifiableEntrySet$UnmodifiableEntrySetSpliterator.tryAdvance(Collections.java:1594)
    at java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:126)
    at java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:498)
    at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:485)
    at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
    at java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:152)
    at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
    at java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:464)
    at org.springframework.boot.logging.LoggingSystem.get(LoggingSystem.java:161)
    at org.springframework.boot.context.logging.LoggingApplicationListener.onApplicationStartingEvent(LoggingApplicationListener.java:216)
    at org.springframework.boot.context.logging.LoggingApplicationListener.onApplicationEvent(LoggingApplicationListener.java:196)

    增加 log4j-core 后也不行 ,控制台就会出现

    Exception in thread "main" java.lang.NoClassDefFoundError: ch/qos/logback/classic/Level

    错误。

    后来我用  spring boot用的是1.56 就不会出现这个问题,正常运行

    最后重新安装了ideaIU-2018.2.6 ,在用spring boot 2.10就没问题了 

  • 相关阅读:
    给定一个排序数组,你需要在原地删除重复出现的元素
    OSPF-外部路由
    虚链路
    OSPF域间路由计算,防环
    转 C# 只允许运行一个实例
    转 点击关闭时最小化到任务栏
    C#,int转成string,string转成int
    SQL 查找表名 字段名
    C# *= 运算顺序
    SQL 批量删除表
  • 原文地址:https://www.cnblogs.com/jialiguo/p/9969254.html
Copyright © 2011-2022 走看看