zoukankan      html  css  js  c++  java
  • spring boot 整合 RabbitMQ 错误

    1.错误

    org.springframework.beans.factory.BeanCreationException: 
    Error creating bean with name 'org.springframework.amqp.rabbit.config.internalRabbitListenerAnnotationProcessor' 
    defined in class path resource [org/springframework/amqp/rabbit/annotation/RabbitBootstrapConfiguration.class]:
     Bean instantiation via factory method failed; 
     nested exception is org.springframework.beans.BeanInstantiationException: F
     ailed to instantiate [org.springframework.amqp.rabbit.annotation.RabbitListenerAnnotationBeanPostProcessor]: 
     Factory method 'rabbitListenerAnnotationProcessor' threw exception;
     nested exception is java.lang.NoClassDefFoundError: org/springframework/messaging/handler/annotation/support/MessageHandlerMethodFactory

    一大堆,不过最关键的是

    java.lang.NoClassDefFoundError: org/springframework/messaging/handler/annotation/support/MessageHandlerMethodFactory

    这个类没有找见

    2.解决:

    这个类是通过 spring boot 的web 模块导入的

    所以直接在 gradle中  添加

    implementation 'org.springframework.boot:spring-boot-starter-web'

    即可

  • 相关阅读:
    php安装扩展的几种方法
    navicat连接linux系统中mysql-错误:10038
    linux下报错bash: service: command not found
    linux配置防火墙和重启防火墙
    linux 环境安装
    匿名函数
    workman的学习总结
    xampp/apache启动失败解决方法
    Linux 查看IP
    慢查询日志
  • 原文地址:https://www.cnblogs.com/lishuaiqi/p/11158547.html
Copyright © 2011-2022 走看看