Java 调 webservice 报如下错误

[2023-11-07 17:01:02.315] ERROR [scheduling-1] ToHisApiImpl.java:106 - No compiler detected, make sure you are running on top of a JDK instead of a JRE.
java.lang.IllegalStateException: No compiler detected, make sure you are running on top of a JDK instead of a JRE.
at org.apache.cxf.common.util.Compiler.useJava6Compiler(Compiler.java:193)
at org.apache.cxf.common.util.Compiler.compileFiles(Compiler.java:141)
at org.apache.cxf.common.util.Compiler.compileFiles(Compiler.java:136)
at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.compileJavaSrc(DynamicClientFactory.java:639)
at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:389)
at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:244)
at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:237)
at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:192)
at com.vipsoft.his.hospital.service.impl.GoodwillcisServiceImpl.archiveFile(GoodwillcisServiceImpl.java:85)
at com.vipsoft.his.hospital.service.impl.ToHisApiImpl.syncReport(ToHisApiImpl.java:92)
at com.vipsoft.his.hospital.schedule.HisTaskJob.syncReport(HisTaskJob.java:38)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.springframework.scheduling.support.ScheduledMethodRunnable.run(ScheduledMethodRunnable.java:84)
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
at org.springframework.scheduling.concurrent.ReschedulingRunnable.run(ReschedulingRunnable.java:93)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)

安装 JDK 默认使用 JRE 环境,新增 JAVA_HOME 环境变量,指向 JDK 目录即可



如果还是不行,修改运行命令

java -jar XXX.jar

改成

"%JAVA_HOME%/BIN/JAVA" -jar XXX.jar

(XXX为你自己打包好的jar包名称)

No compiler detected, make sure you are running on top of a JDK instead of a JRE的更多相关文章

  1. A previous installation of Qt5 Visual Studio Add-in was detected. Please uninstall it before running this installer解决办法

    前段时间在安装Qt Visual Studio插件的时候,安装到一半不小心中止了,结果后来怎么安装都不行,提示已经安装了,要先卸载, 可是到哪里都找不到有卸载的,因为压根就没有安装完成.这可害苦我了. ...

  2. Android stadio 生成项目 Cannot find System Java Compiler. Ensure that you have installed a JDK (not just a JRE)

    解决方法 File-->Project-->Structrue-->SDK Location-->JDK location Use embedded JDK 前面勾去掉,指定一 ...

  3. maven install 报错 No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?

    1.控制台打印信息 [INFO] Scanning for projects... [INFO] [INFO] ---------------------< org.cqupt.mauger:R ...

  4. No compiler is provided in this environment. Perhaps you are running on a JR

    maven编译项目时出错,提示信息如下: [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3 ...

  5. 关于Maven项目build时出现No compiler is provided in this environment的处理

    版权声明:本文为博主原创文章,未经博主允许不得转载. http://blog.csdn.net/lslk9898/article/details/73836745 近日有同事遇到在编译Maven项目时 ...

  6. 关于Maven项目build时出现No compiler is provided in this environment的处理(转)

    本文转自https://blog.csdn.net/lslk9898/article/details/73836745 近日有同事遇到在编译Maven项目时出现[ERROR] No compiler ...

  7. 解决Maven项目报错Perhaps you are running on a JRE rather than a JDK?

    问题描述: 在创建SpringMVC项目运行构建项目的时候,发现构建失败.报错信息为Maven-No compiler is provided in this environment. Perhaps ...

  8. Atitit.java eval功能的实现  Compiler API

    Atitit.java eval功能的实现  Compiler API 输出echo2 输出目录配置2 针对编译器,JDK 设计了两个接口,分别是 JavaCompiler 和JavaCompiler ...

  9. Up and running with Apache Spark on Apache Kudu

    After the GA of Apache Kudu in Cloudera CDH 5.10, we take a look at the Apache Spark on Kudu integra ...

  10. Android Studio运行报错,Cannot find System Java Compiler. Ensure that you have installed a JDK......

    详细报错信息如下 Error:Execution failed for task ':app:compileDebugJavaWithJavac'. > Cannot find System J ...

随机推荐

  1. Opencv中goodFeaturesToTrack函数(Harris角点、Shi-Tomasi角点检测)算子速度的进一步优化(1920*1080测试图11ms处理完成)。

    搜索到某个效果很好的视频去燥的算法,感觉效果比较牛逼,就是速度比较慢,如果能做到实时,那还是很有实用价值的.于是盲目的选择了这个课题,遇到的第一个函数就是角点检测,大概六七年用过C#实现过Harris ...

  2. Python JSON 使用指南:解析和转换数据

    JSON 是一种用于存储和交换数据的语法.JSON 是文本,使用 JavaScript 对象表示法编写. Python 中的 JSON Python 有一个内置的 json 包,可用于处理 JSON ...

  3. 该如何选择ClickHouse的表引擎

    该如何选择ClickHouse的表引擎 本文将介绍ClickHouse中一个非常重要的概念-表引擎(table engine).如果对MySQL熟悉的话,或许你应该听说过InnoDB和MyISAM存储 ...

  4. reverse_re3

    main函数 点击重要函数 对if里面的数字按r键,使其从ASCII码转为字符 发现wasd四个关键的移动方向键,判断为迷宫问题 判断应该是要次数为2,即次数++3(从0开始计数)次才会有flag 点 ...

  5. Navicat 基于 GaussDB 主备版的快速入门

    本文分享自华为云社区<Navicat 基于 GaussDB 主备版的快速入门>,作者:Navicat_China. Navicat Premium(16.2.8 Windows版或以上) ...

  6. [ABP] PostgreSQL在.NET 6.0使用DateTime类型抛出异常:timestamp with time zone

    今晚操起久违的 ABP 框架搭了个新项目: .NET 运行时版本:6.0.3 ABP 版本:v5.2.0-rc.2 版本. 数据库:PostgreSQL v10.x 一顿操作猛如虎,直接用 dotne ...

  7. 如何将IPv4升级到IPv6?看完你就明白了

    引言: 随着互联网的快速发展,IPv4(Internet Protocol version 4)已经无法满足日益增长的设备和用户数量的需求. IPv6(Internet Protocol versio ...

  8. MySQL 有哪些常见的面试题

    MySQL 是一种常用的关系型数据库管理系统,在面试过程中经常会涉及与 MySQL 相关的问题.以下是一些常见的 MySQL 面试题: 1. 介绍一下 MySQL 和其他数据库管理系统的区别. - M ...

  9. 公司oa是什么?一般公司oa有什么样功能?

    公司OA(Office Automation)是指通过计算机和信息技术来实现办公自动化的系统. 它提供了一系列的功能和工具,用于协调.管理和处理公司内部的日常事务和流程.OA系统旨在提高工作效率.加强 ...

  10. Tarjan 学习笔记

    萌新刚学Tarjan,啥也不会,肯定一堆错,请大佬指正谢谢 前置 强连通 强连通: 在不是强连通图的有向图\(G\)内,其顶点\(u\),\(v\)两个方向上都存在有向路径,则\(u\)和\(v\)强 ...