解决Run As -> Java Application不能运行问题
转自:https://breakshell.iteye.com/blog/467130
点 Run As -> Java Application 不能运行,报的错误如下:
- Plug-in org.eclipse.ajdt.ui was unable to load class org.eclipse.ajdt.internal.ui.ajde.CachedRuntimeClasspathEntryResolver.
- org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter$TerminatingClassNotFoundException: An error occurred while automatically activating bundle org.eclipse.ajdt.ui (745).
- at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:125)
- at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:449)
- at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:211)
- at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:376)
- at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:452)
- at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:405)
- at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:393)
- at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:105)
- at java.lang.ClassLoader.loadClass(Unknown Source)
- at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:321)
- at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:231)
- at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1193)
- at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:160)
- at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:874)
- at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
- at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:51)
- at org.eclipse.jdt.internal.launching.RuntimeClasspathEntryResolver.getResolver(RuntimeClasspathEntryResolver.java:52)
- at org.eclipse.jdt.internal.launching.RuntimeClasspathEntryResolver.resolveRuntimeClasspathEntry(RuntimeClasspathEntryResolver.java:44)
- at org.eclipse.jdt.launching.JavaRuntime.resolveRuntimeClasspathEntry(JavaRuntime.java:924)
- at org.eclipse.jdt.launching.StandardClasspathProvider.resolveClasspath(StandardClasspathProvider.java:75)
- at org.eclipse.jdt.launching.JavaRuntime.resolveRuntimeClasspath(JavaRuntime.java:1205)
- at org.eclipse.jdt.launching.AbstractJavaLaunchConfigurationDelegate.getClasspath(AbstractJavaLaunchConfigurationDelegate.java:417)
- at org.eclipse.jdt.launching.JavaLaunchDelegate.launch(JavaLaunchDelegate.java:71)
- at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:853)
- at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:703)
- at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:866)
- at org.eclipse.debug.internal.ui.DebugUIPlugin$8.run(DebugUIPlugin.java:1069)
- at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
- Caused by: org.osgi.framework.BundleException: The activator org.eclipse.ajdt.ui.AspectJUIPlugin for bundle org.eclipse.ajdt.ui is invalid
- at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:157)
- at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:750)
- at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:352)
- at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:280)
- at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:408)
- at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:111)
- ... 27 more
- Caused by: java.lang.NoClassDefFoundError: org/eclipse/ajdt/core/ras/FFDC
- at java.lang.Class.getDeclaredConstructors0(Native Method)
- at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
- at java.lang.Class.getConstructor0(Unknown Source)
- at java.lang.Class.newInstance0(Unknown Source)
- at java.lang.Class.newInstance(Unknown Source)
- at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:152)
- ... 32 more
- Caused by: org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter$TerminatingClassNotFoundException: An error occurred while automatically activating bundle org.eclipse.ajdt.core (740).
- at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:125)
- at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:449)
- at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:211)
- at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:376)
- at org.eclipse.osgi.internal.loader.SingleSourcePackage.loadClass(SingleSourcePackage.java:33)
- at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:440)
- at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:405)
- at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:393)
- at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:105)
- at java.lang.ClassLoader.loadClass(Unknown Source)
- at java.lang.ClassLoader.loadClassInternal(Unknown Source)
- at java.lang.Class.forName0(Native Method)
- at java.lang.Class.forName(Unknown Source)
- at org.springframework.ide.eclipse.core.java.JdtUtils.isAjdtPresent(JdtUtils.java:383)
- at org.springframework.ide.eclipse.core.java.JdtUtils.<clinit>(JdtUtils.java:73)
- at org.springframework.ide.eclipse.aop.core.internal.model.AopResourceChangeEvents.isSpringProject(AopResourceChangeEvents.java:33)
- at org.springframework.ide.eclipse.core.internal.model.resources.SpringResourceChangeListener$SpringResourceVisitor.resourceChanged(SpringResourceChangeListener.java:216)
- at org.springframework.ide.eclipse.core.internal.model.resources.SpringResourceChangeListener$SpringResourceVisitor.visit(SpringResourceChangeListener.java:143)
- at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:68)
- at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:79)
- at org.springframework.ide.eclipse.core.internal.model.resources.SpringResourceChangeListener.resourceChanged(SpringResourceChangeListener.java:75)
- at org.eclipse.core.internal.events.NotificationManager$2.run(NotificationManager.java:291)
- at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
- at org.eclipse.core.internal.events.NotificationManager.notify(NotificationManager.java:285)
- at org.eclipse.core.internal.events.NotificationManager.broadcastChanges(NotificationManager.java:149)
- at org.eclipse.core.internal.resources.Workspace.broadcastBuildEvent(Workspace.java:297)
- at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:136)
- at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:238)
- ... 1 more
- Caused by: org.osgi.framework.BundleException: Exception in org.eclipse.ajdt.core.AspectJPlugin.start() of bundle org.eclipse.ajdt.core.
- at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:805)
- at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:754)
- at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:352)
- at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:280)
- at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:408)
- at org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:111)
- ... 28 more
- Caused by: java.lang.NoClassDefFoundError: org/aspectj/ajde/core/ICompilerConfiguration
- at org.eclipse.ajdt.core.AspectJPlugin.start(AspectJPlugin.java:131)
- at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:782)
- at java.security.AccessController.doPrivileged(Native Method)
- at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:773)
- ... 33 more
- Caused by: java.lang.ClassNotFoundException: org.aspectj.ajde.core.ICompilerConfiguration
- at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:489)
- at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:405)
- at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:393)
- at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:105)
- at java.lang.ClassLoader.loadClass(Unknown Source)
- at java.lang.ClassLoader.loadClassInternal(Unknown Source)
- ... 37 more
- eclipse.buildId=I20090611-1540
- java.version=1.6.0_16
- java.vendor=Sun Microsystems Inc.
- BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=zh_CN
- Framework arguments: -product org.eclipse.epp.package.jee.product
- Command-line arguments: -os win32 -ws win32 -arch x86 -product org.eclipse.epp.package.jee.product
我的Eclipse3.5版本是:
Eclipse Java EE IDE for Web Developers.
Build id: 20090621-0832
原来是我之前安装Maven插件的时候选择安装了AJDT,只要不安装AJDT插件,程序运行正常。
我想这个应该是AJDT的一个BUG吧。。。
解决Run As -> Java Application不能运行问题的更多相关文章
- win10+eclipse+hadoop2.7.2+maven+local模式直接通过Run as Java Application运行wordcount
一.准备工作 (1)Hadoop2.7.2 在linux部署完毕,成功启动dfs和yarn,通过jps查看,进程都存在 (2)安装maven 二.最终效果 在windows系统中,直接通过Run as ...
- eclipse中的项目运行时不出现run as→java application选项
eclipse中的运行java project时不出现run as→java application选项? 解决方案☞必须有正确的主方法,即public static void main(String ...
- Eclipse中run as run on server和run as java application
一.run java application (作为Java应用程序运行)是运行 java main方法 run on server是启动一个web 应用服务器 二.两者的区别: Eclipse中 ...
- spring boot: 热部署(一) run as – java application (spring-loader-1.2.4.RELEASE.jar)
spring boot: 热部署(一) run as – java application (spring-loader-1.2.4.RELEASE.jar) 如果使用的run as – java a ...
- maven project中,在main方法上右键Run as Java Application时,提示错误:找不到或无法加载主类XXX.XXXX.XXX
新建了一个maven project项目,经过一大堆的修改操作之后,突然发现在main方法上右键运行时,竟然提示:错误:找不到或无法加载主类xxx.xxx.xxx可能原因1.eclipse出问题了,在 ...
- How to run a (Tomcat)Java application server on a Azure virtual machine
http://www.windowsazure.com/en-us/documentation/articles/virtual-machines-java-run-tomcat-applicatio ...
- maven: 打包可运行的jar包(java application)及依赖项处理
IDE环境中,可以直接用exec-maven-plugin插件来运行java application,类似下面这样: <plugin> <groupId>org.codehau ...
- SpringCloud异常(Euruka):Application run failed java.lang.NoSuchMethodError: org.springframework.boot.builder.SpringApplicationBuilder
在测试Euruka作为服务注册中心的时候碰到了这个问题,错误提示如下: "C:\Program Files\Java\jdk1.8.0_161\bin\java" -XX:Tier ...
- Jenkins 解决Jenkins下java无法运行slave-agent jnlp程序连接Windows Slave主机
解决Jenkins下java无法运行slave-agent jnlp程序连接Windows Slave主机 by:授客 QQ:1033553122 测试环境 java下载地址:http://www ...
随机推荐
- bzoj5020: [THUWC 2017]在美妙的数学王国中畅游
Description 数学王国中,每个人的智商可以用一个属于 [0,1]的实数表示.数学王国中有 n 个城市,编号从 0 到 n−1 ,这些城市由若干座魔法桥连接.每个城市的中心都有一个魔法球,每个 ...
- Linux环境下配置maven环境
1.下载安装包并解压 安装包直接去apache官网下载:https://maven.apache.org/download.cgi 将安装包放在自己指定的目录:/home/software/apach ...
- Jquery的ajax在IE提交数据乱码解决方法
原文地址:http://fatkun.com/2010/12/jquery-ajax.html 乱码是因为编码不同而造成的.在ajax post 或 get时都有可能出现乱码. 为了避免乱码,可以做到 ...
- ZBench: 服务器一键测试脚本 / 自带结果导出vps网络测试
zbench主站: https://blog.liyuans.com/archives/Zbench.html 脚本来自友链 主机博客,项目地址为 https://github.com/Functio ...
- Android多线程下载
所用知识点: 1.设置http协议字段Range “bytes=“start+”-”+end conn.addRequestProperty("Range", "byte ...
- arcgis for android 读取shp文件中文乱码解决方法
设置注册表默认字符,即可解决中文乱码问题. 'dbfDefault' 设置方法1.开始--运行,输入”Regedit“,打开注册表.2.如是用的是 10.x 版本 ArcGIS Desktop,定位到 ...
- delphi正则表达式学习笔记(三)
Delphi 中经常使用的正则表达式 在 Delphi 中使用正则表达式, 目前 PerlRegEx 应该是首选, 准备彻底而细致地研究它. 官方网站: http://www.regular-e x ...
- 用tmux工具给linux命令行分栏
介绍 有时候我们需要在命令行里同时开多个程序,但是每个程序都会占用命令行,这时候可以用tmux,给命令行界面分栏. 基本概念 tmux是分多层的 会话>窗口(我下文称作:页)>面板(或者叫 ...
- react 数据管理之state思想指南
react的数据管理库有不少,最常听到的可能是mobx redux altjs之类的,当然还有很多其他,可以自己搜索. 为什么需要数据管理库呢,因为react本身只是为了实现view的表现,而不是数据 ...
- MapReduce高级编程2
MapReduce Top N .二次排序,MapJoin: TOP N 对于一组输入List(key,value),我们要创建一个Top N 列表,这是一种过滤模式,查看输入数据特定子集,观察用户的 ...