springboot集成MQTT 超详细 保姆级 我知道你想要什么
翼贞殿士:
[code=plain]
Caused by: java.lang.IllegalStateException: Failed to introspect Class [com.hirox.mqttdemo.config.MqttConfig] from ClassLoader [sun.misc.Launcher$AppClassLoader@22d8cfe0]
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:485) ~[spring-core-5.3.31.jar:5.3.31]
Caused by: java.lang.NoClassDefFoundError: org/springframework/integration/mqtt/core/MqttPahoClientFactory
at java.lang.Class.getDeclaredMethods0(Native Method) ~[na:1.8.0_431]
at java.lang.Class.privateGetDeclaredMethods(Class.java:2701) ~[na:1.8.0_431]
at java.lang.Class.getDeclaredMethods(Class.java:1975) ~[na:1.8.0_431]
at org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:467) ~[spring-core-5.3.31.jar:5.3.31]
... 33 common frames omitted
Caused by: java.lang.ClassNotFoundException: org.springframework.integration.mqtt.core.MqttPahoClientFactory
at java.net.URLClassLoader.findClass(URLClassLoader.java:387) ~[na:1.8.0_431]
at java.lang
[/code]
springboot集成MQTT 超详细 保姆级 我知道你想要什么
翼贞殿士:
您好,可以提供完整的springboot相关依赖吗?你的springboot版本是多少的?另外这个mqtt的依赖为啥没有指定版本?我按照您的来直接启动不了...
[code=plain]
. ____ _ __ _ _
/\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v2.7.18)
2025-06-07 10:17:44.792 INFO 5524 --- [ main] com.hirox.mqttdemo.MqttApplication : Starting MqttApplication using Java 1.8.0_431 on hirox-win11 with PID 5524 (D:\workspace\mqtt_demo\target\classes started by dgc12 in D:\workspace\mqtt_demo)
2025-06-07 10:17:44.793 INFO 5524 --- [ main] com.hirox.mqttdemo.MqttApplication : No active profile set, falling back to 1 default profile: "default"
2025-06-07 10:17:45.178 ERROR 5524 --- [ main] o.s.boot.SpringApplication : Application run failed
java.lang.IllegalStateException: Error processing cond
[/code]
Windows程序闪退原因查看方法----事件查看器
split vision:
你好 你找到定位方法了吗
MybatisPlus 超好用的idea代码生成插件,及使用详解
踩坑的菜鸟:
我也是post 只生成了文件夹
Windows程序闪退原因查看方法----事件查看器
BlackstarOffice:
这个方法只能记录程序遇到的外部错误,如果是程序本身的错误(代码写错了)则不会显示。这种情况下应该如何定位错误呢?