After many research on internet about install JavaCV in Eclipse or Net Beans. I write this text because i do not found how fix my problem.
Java SE Developement kit update 10 ( I use JDK 1.7 )
OpenCV 2.4.2 (in c:\ )
JavaCV 0.2 bin (in c:\ )
JNA 3.4.0 (C:\javacv-bin\JNA)
Windows 7 32 bits.
Eclips IDE for Java Developers 32 bits.
Microsoft Visual C++ 2010 Redistributable Package (x86) installed
I created a new project in Eclipse.
I added in environement variables: C:\opencv\build\x86\vc10\bin; C:\opencv\build\common\tbb\ia32\vc10
Added all external library
I fixed dependency problems with depends.exe and added "IEShims.dll" because missing.
And now when i launch my program i have always his errors.
Exception in thread "main" java.lang.UnsatisfiedLinkError: C:\Users\SweetLive\AppData\Local\Temp\jniopencv_core3957460997136742229.dll:
Can't find dependent libraries at
java.lang.ClassLoader$NativeLibrary.load(Native Method) at
java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1939) at
java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1864) at
java.lang.ClassLoader.loadLibrary(ClassLoader.java:1825) at
java.lang.Runtime.load0(Runtime.java:792) at
java.lang.System.load(System.java:1059) at
com.googlecode.javacpp.Loader.loadLibrary(Loader.java:403) at
com.googlecode.javacpp.Loader.load(Loader.java:342) at
com.googlecode.javacpp.Loader.load(Loader.java:316) at
com.googlecode.javacv.cpp.opencv_core.(opencv_core.java:131)
at java.lang.Class.forName0(Native Method) at
java.lang.Class.forName(Class.java:264) at
com.googlecode.javacpp.Loader.load(Loader.java:335) at
com.googlecode.javacv.cpp.opencv_imgproc.(opencv_imgproc.java:96)
at java.lang.Class.forName0(Native Method) at
java.lang.Class.forName(Class.java:264) at
com.googlecode.javacpp.Loader.load(Loader.java:335) at
com.googlecode.javacv.cpp.opencv_objdetect.(opencv_objdetect.java:96)
at java.lang.Class.forName0(Native Method) at
java.lang.Class.forName(Class.java:264) at
com.googlecode.javacpp.Loader.load(Loader.java:335) at
com.googlecode.javacpp.Loader.load(Loader.java:316) at
com.googlecode.javacv.cpp.opencv_objdetect$CvHaarClassifierCascade.>(opencv_objdetect.java:175) at DetectVisage.main(DetectVisage.java:50)
For all this, i used:
http://code.google.com/p/javacv/wiki/Windows7AndOpenCV
http://www.cs.dartmouth.edu/~cs10/install/javacv-win/
And i can't see on blogspot because this website blocked in China (I'm foreign student in China)
Someone has an idea to solve my problem? thanx in advance.
Related
Trying to get a basic setup working to run the local Google App Engine running in Eclipse using the Google Cloud Tools for Eclipse, but I keep getting the error below when starting the server using the Run As -> App Engine option.
I believe my environment is good because I am able to run the test application with a local app server from the command line using the java_dev_appserver command, so the problem seems specific to the Eclipse environment.
at com.google.appengine.tools.development.DevAppServerFactory.doCreateDevAppServer(DevAppServerFactory.java:383)
at com.google.appengine.tools.development.DevAppServerFactory.createDevAppServer(DevAppServerFactory.java:315)
at com.google.appengine.tools.development.DevAppServerMain$StartAction.apply(DevAppServerMain.java:385)
at com.google.appengine.tools.util.Parser$ParseResult.applyArgs(Parser.java:59)
at com.google.appengine.tools.development.DevAppServerMain.run(DevAppServerMain.java:259)
at com.google.appengine.tools.development.DevAppServerMain.main(DevAppServerMain.java:250)
Caused by: java.lang.ExceptionInInitializerError
at com.google.appengine.tools.development.DevAppServerImpl.<init>(DevAppServerImpl.java:136)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
at com.google.appengine.tools.development.DevAppServerFactory.doCreateDevAppServer(DevAppServerFactory.java:368)
... 5 more
Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make static java.net.URLStreamHandler java.net.URL.getURLStreamHandler(java.lang.String) accessible: module java.base does not "opens java.net" to unnamed module #49c43f4e
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
at java.base/java.lang.reflect.Method.checkCanSetAccessible(Method.java:199)
at java.base/java.lang.reflect.Method.setAccessible(Method.java:193)
at com.google.appengine.tools.development.StreamHandlerFactory.<clinit>(StreamHandlerFactory.java:53)
... 12 more
I started from a clean Windows 11 machine, installed Google Cloud SDK, added the app-engine-java component, configured a project, tested by deploying to the cloud with the CLI, installed Eclipse, added the Google Tools for Eclipse plugin, created a sample project using the Google plugin Create Project -> Google App Engine Standard project, and tried to run it.
This is probably very simple but I can't figure it out.
The problem was happening with JRE v17 that installs by default with Eclipse 2021-12. Installing Eclipse with JRE v11 solved the problem. Thanks to greg-449 for putting me on the right track.
Downgrading the JVM to jdk-11.0.13 solved this problem for me as well.
Since I didn't un-install JRE v17, I had to change my eclipse.ini file to point to JDK 11, then update the Eclipse workspace settings for installed JRE's to include JDK 11 and update my workspace properties to use that version by default instead of the JRE 17. I also updated the JDK compliance settings to be JDK 11 instead of 17 and disabled the "release" setting that wanted to still use 17.
Thanks for this post. I had been working on this problem for several days upgrade/downgrading libraries, etc.
I am already on java version 11 and after looking here and there, I have downgraded from 11 to 8 but still facing same issue with eclipse plugin.
java.lang.RuntimeException: Unable to create a DevAppServer
at com.google.appengine.tools.development.DevAppServerFactory.doCreateDevAppServer(DevAppServerFactory.java:378)
at com.google.appengine.tools.development.DevAppServerFactory.createDevAppServer(DevAppServerFactory.java:310)
at com.google.appengine.tools.development.DevAppServerMain$StartAction.apply(DevAppServerMain.java:384)
at com.google.appengine.tools.util.Parser$ParseResult.applyArgs(Parser.java:58)
at com.google.appengine.tools.development.DevAppServerMain.run(DevAppServerMain.java:258)
at com.google.appengine.tools.development.DevAppServerMain.main(DevAppServerMain.java:249)
Caused by: java.lang.ExceptionInInitializerError
at com.google.appengine.tools.development.DevAppServerImpl.<init>(DevAppServerImpl.java:135)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:78)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
at com.google.appengine.tools.development.DevAppServerFactory.doCreateDevAppServer(DevAppServerFactory.java:363)
... 5 more
Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make static java.net.URLStreamHandler java.net.URL.getURLStreamHandler(java.lang.String) accessible: module java.base does not "opens java.net" to unnamed module #133e16fd
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:357)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
at java.base/java.lang.reflect.Method.checkCanSetAccessible(Method.java:199)
at java.base/java.lang.reflect.Method.setAccessible(Method.java:193)
at com.google.appengine.tools.development.StreamHandlerFactory.<clinit>(StreamHandlerFactory.java:52)
... 12 more
Any suggestion, What can be the issue?
I'm using IBM JDK 8 for Eclipse Mars (required to connect to WebSphere, Oracle JDK doesn't work). In the eclipse.ini, I added the following:
-vm
C:\IBM\eclipseDevelopmentPackage\ibm_sdk80\jre\bin\javaw.exe
When I run latest version sonarlint 1.2 (installed from eclipse marketplace), I got the following exception. Switch back to Oracle JDK 8, no issue. Any idea?
Also, is it possible to install sonarlint in RAD 8.5.5.1(Eclipse 3.6 based) ?
Sensor JavaSquidSensor
Configured Java source version (sonar.java.source): 6
JavaClasspath initialization...
JavaClasspath initialization done: 213 ms
JavaTestClasspath initialization...
JavaTestClasspath initialization done: 214 ms
Java Main Files AST scan...
1 source files to be analyzed
Error during analysis
org.sonar.squidbridge.api.AnalysisException: SonarQube is unable to analyze file : 'C:\workspace\........\Service.java'
at org.sonar.java.ast.JavaAstScanner.simpleScan(JavaAstScanner.java:126)
at org.sonar.java.ast.JavaAstScanner.simpleScan(JavaAstScanner.java:100)
at org.sonar.java.ast.JavaAstScanner.scan(JavaAstScanner.java:80)
at org.sonar.java.JavaSquid.scanSources(JavaSquid.java:135)
at org.sonar.java.JavaSquid.scan(JavaSquid.java:128)
at org.sonar.plugins.java.JavaSquidSensor.analyse(JavaSquidSensor.java:90)
at org.sonar.batch.phases.SensorsExecutor.executeSensor(SensorsExecutor.java:58)
at org.sonar.batch.phases.SensorsExecutor.execute(SensorsExecutor.java:50)
at org.sonar.batch.phases.PhaseExecutor.execute(PhaseExecutor.java:98)
at org.sonar.batch.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:185)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:132)
at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:117)
at org.sonar.batch.scan.ProjectScanContainer.scan(ProjectScanContainer.java:249)
at org.sonar.batch.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:244)
at org.sonar.batch.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:234)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:132)
at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:117)
at org.sonar.batch.task.ScanTask.execute(ScanTask.java:55)
at org.sonar.batch.task.TaskContainer.doAfterStart(TaskContainer.java:86)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:132)
at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:117)
at org.sonar.batch.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:122)
at org.sonar.batch.bootstrapper.Batch.executeTask(Batch.java:133)
at org.sonar.runner.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:73)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:95)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
at java.lang.reflect.Method.invoke(Method.java:507)
at org.sonar.runner.impl.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:61)
at com.sun.proxy.$Proxy35.execute(Unknown Source)
at org.sonar.runner.api.EmbeddedRunner.doExecute(EmbeddedRunner.java:273)
at org.sonar.runner.api.EmbeddedRunner.runAnalysis(EmbeddedRunner.java:166)
at org.sonarlint.eclipse.core.internal.jobs.SonarRunnerFacade.startAnalysis(SonarRunnerFacade.java:55)
at org.sonarlint.eclipse.core.internal.jobs.AnalyzeProjectJob$1.run(AnalyzeProjectJob.java:254)
Caused by: java.lang.NullPointerException
at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:187)
at org.sonar.java.se.ProgramState.decreaseReference(ProgramState.java:200)
at org.sonar.java.se.ProgramState.cleanupDeadSymbols(ProgramState.java:244)
at org.sonar.java.se.ExplodedGraphWalker.cleanUpProgramState(ExplodedGraphWalker.java:224)
at org.sonar.java.se.ExplodedGraphWalker.handleBlockExit(ExplodedGraphWalker.java:232)
at org.sonar.java.se.ExplodedGraphWalker.execute(ExplodedGraphWalker.java:175)
at org.sonar.java.se.ExplodedGraphWalker.visitMethod(ExplodedGraphWalker.java:130)
at org.sonar.java.model.declaration.MethodTreeImpl.accept(MethodTreeImpl.java:215)
at org.sonar.java.se.SymbolicExecutionVisitor.visitNode(SymbolicExecutionVisitor.java:41)
at org.sonar.java.ast.visitors.SubscriptionVisitor.visit(SubscriptionVisitor.java:89)
at org.sonar.java.ast.visitors.SubscriptionVisitor.visitChildren(SubscriptionVisitor.java:115)
at org.sonar.java.ast.visitors.SubscriptionVisitor.visit(SubscriptionVisitor.java:91)
at org.sonar.java.ast.visitors.SubscriptionVisitor.visitChildren(SubscriptionVisitor.java:115)
at org.sonar.java.ast.visitors.SubscriptionVisitor.visit(SubscriptionVisitor.java:91)
at org.sonar.java.ast.visitors.SubscriptionVisitor.scanTree(SubscriptionVisitor.java:72)
at org.sonar.java.ast.visitors.SubscriptionVisitor.scanFile(SubscriptionVisitor.java:65)
at org.sonar.java.model.InternalVisitorsBridge.visitFile(InternalVisitorsBridge.java:125)
at org.sonar.java.ast.JavaAstScanner.simpleScan(JavaAstScanner.java:117)
... 33 more
I'm using Tomcat v7.0 and with Eclipse IDE for a Webapp. When trying to start the server , I get the below ClassNotFoundException
java.lang.NoClassDefFoundError: org/apache/tomcat/util/digester/Rule
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2585)
at java.lang.Class.getConstructor0(Class.java:2885)
at java.lang.Class.newInstance(Class.java:350)
at org.apache.catalina.startup.Bootstrap.init(Bootstrap.java:239)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:426)
Caused by: java.lang.ClassNotFoundException: org.apache.tomcat.util.digester.Rule
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
... 6 more
On searching, I found the apache-tomcat-util 5.23 jar containing the above class but after adding the jar to the launch configuration of Tomcat I get a series of other errors. The same server installation works good in a different work space with a different webapp. What is the issue here?
You have broken your installation, probably before you found apache-tomcat-util-5.23.jar and most certainly after adding that JAR file to your installation. That JAR you added was from a Tomcat version that is many years old and incompatible with your newer version.
Remove your existing Tomcat installation (but save the webapps/ directory if you put anything in there you want to keep) and reinstall.
If you are still getting that error, check to make sure that your IDE is configured correctly: Tomcat comes with every JAR it needs to launch, so if it won't start, it's because of a misconfiguration with the IDE's integration.
In my case the only problem was version of Apache Tomcat which I used is Apache 7.0 and when I change to Apache 8.0 It will run perfectly fine.
the exception "java.lang.NoClassDefFoundError: org/apache/tomcat/util/digester/Rule" may occur because the server installation was stopped before it was finished.
Make sure of the % of installation when you install the server since nothing appears when we click install and it seems immediate, but in reality it takes a few seconds.
No problem :-)
I get this error when I start the server. I tried everything but still not sure what the cause is . Please help
Thanks
java.lang.IllegalArgumentException: Failed to instantiate class "org.jboss.logmanager.handlers.PeriodicRotatingFileHandler" for handler "FILE"
at org.jboss.logmanager.config.AbstractPropertyConfiguration$ConstructAction.validate(AbstractPropertyConfiguration.java:119)
at org.jboss.logmanager.config.LogContextConfigurationImpl.doPrepare(LogContextConfigurationImpl.java:338)
at org.jboss.logmanager.config.LogContextConfigurationImpl.prepare(LogContextConfigurationImpl.java:291)
at org.jboss.logmanager.config.LogContextConfigurationImpl.commit(LogContextConfigurationImpl.java:300)
at org.jboss.logmanager.PropertyConfigurator.configure(PropertyConfigurator.java:542)
at org.jboss.logmanager.PropertyConfigurator.configure(PropertyConfigurator.java:97)
at org.jboss.logmanager.LogManager.readConfiguration(LogManager.java:300)
at org.jboss.logmanager.LogManager.readConfiguration(LogManager.java:262)
at java.util.logging.LogManager$3.run(LogManager.java:399)
at java.util.logging.LogManager$3.run(LogManager.java:396)
at java.security.AccessController.doPrivileged(Native Method)
at java.util.logging.LogManager.readPrimordialConfiguration(LogManager.java:396)
at java.util.logging.LogManager.access$800(LogManager.java:145)
at java.util.logging.LogManager$2.run(LogManager.java:345)
at java.security.AccessController.doPrivileged(Native Method)
at java.util.logging.LogManager.ensureLogManagerInitialized(LogManager.java:338)
at java.util.logging.LogManager.getLogManager(LogManager.java:378)
at org.jboss.modules.Main.main(Main.java:438)
Caused by: java.lang.reflect.InvocationTargetException
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:408)
at org.jboss.logmanager.config.AbstractPropertyConfiguration$ConstructAction.validate(AbstractPropertyConfiguration.java:117)
... 17 more
Caused by: java.io.FileNotFoundException: C:\Program Files\wildfly-8.0.0.Final\wildfly-8.0.0.Final\standalone\log\boot.log (The system cannot find the path specified)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.<init>(FileOutputStream.java:206)
at org.jboss.logmanager.handlers.FileHandler.setFile(FileHandler.java:154)
at org.jboss.logmanager.handlers.PeriodicRotatingFileHandler.setFile(PeriodicRotatingFileHandler.java:105)
at org.jboss.logmanager.handlers.FileHandler.setFileName(FileHandler.java:192)
at org.jboss.logmanager.handlers.FileHandler.<init>(FileHandler.java:122)
at org.jboss.logmanager.handlers.PeriodicRotatingFileHandler.<init>(PeriodicRotatingFileHandler.java:73)
... 22 more
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
The main error is this one:
Caused by: java.io.FileNotFoundException: C:\Program Files\wildfly-8.0.0.Final\wildfly-8.0.0.Final\standalone\log\boot.log
Check that the file exists and/or there are no permission restrictions which might stop Java from creating that file.
The final line in your question:
22 more Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
Seems to suggest that WildFly 8.0 is not Java 8 certified. That is, it was not designed to run on Java 8 so, while there is every likelihood that it will start under Java 8, there may be some unexpected behaviour.
I would recommend that, if possible, you either upgrade your WildFly to the latest stable release (8.2 as of this date) or if that isn't possible, downgrade your Java version to 7.
Are you using windows 10?
Similar issue with windows10
If so, try starting the server through the Command Prompt (admin) rather than just normal cmd.
To access this, just right click Start and you will see it.
Thanks,
Ben
I'm working with Eclipse Helios 3.6 (32-bit). I installed the GWT plug-in and created a new Web application. In the Client folder I was trying to open a file with GWT designer, but unfortunately I was getting an error:
Internal Error encountered unexpected internal error. This could be caused by a bug or by a misconfiguration issue, conflict, partial update, etc.
java.lang.UnsupportedClassVersionError: Bad version number in .class file
Stack trace:
java.lang.UnsupportedClassVersionError: Bad version number in .class file
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at com.google.gdt.eclipse.designer.hosted.tdt.HostedModeSupport.loadImpl
(HostedModeSupport.java:110)
at com.google.gdt.eclipse.designer.hosted.tdt.HostedModeSupport.<init>
(HostedModeSupport.java:83)
at com.google.gdt.eclipse.designer.hosted.tdt.HostedModeSupportFactory.create
(HostedModeSupportFactory.java:32)
at com.google.gdt.eclipse.designer.model.widgets.support.GwtState.getHostedModeSupport
(GwtState... (missing part here)
...org.eclipse.wb.internal.core.editor.errors.ExceptionComposite$3.widgetSelected
(ExceptionComposite.java:129)
--- etc
I have JavaCompiler in project properties 1.6 and from preferences->java->installed JDK/JRE using 1.6.
I am not sure of the specifics but most likely you are trying to run the designer with JDK 1.5. That is the cause of that error. I would recheck everything.
Also off the top of my head I would verify 32 bit versus 64 bit java sdk.
Generally when anything is wrong in JavaCompiler Project properties it will throw error of major/minor version 51.0 . So here most probably by checking the java version installed in the system and the version through which you are working are differnet. Make both of them compatible and the error will be solved.