I have imported a GWT project from GIT , but when i run maven Install
it says
.m2\repository\commons-logging\commons-logging\1.1\commons-logging-1.1.jar; cannot read zip file entry
and if i simply run my application , i get this
\git\my-Search-Engine\qsse\war}: java.lang.NoClassDefFoundError: com/google/inject/servlet/GuiceServletContextListener
I tried to find out the way , one solution i found was to move the guice-servlet-3.0 from build path to \qsse\war\webinf\lib
but if i do that i start getting this exception
ava.lang.NoClassDefFoundError: com/google/inject/Injector
any idea how can i resolve this
For first question:
Can you open it in a WinZip or other compression tool.
Try deleting that jar and build again. Let Maven download it a fresh.
For Second Questin:
Which GWT version are you using ?
Verify that the required JAR is in your classpath including guice.jar and guice-servlet-3.0.jar
And also, guice-servlet-3.0.jar should not be in you launch configuration classpath. It has to be in your project classpath.
For the second question, can you also move the other guice jars to webinf\lib ? (guice-3.0.jar should be missing)
Related
I am getting an unexpected error when trying to instantiate a Configuration object in my Map/Reduce program.
The error is as follows:
java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory
I am using Hadoop 2.2.0. The program worked fine with an earlier version of Hadoop. However, now I need to write this job submitter for the version 2, and this does not seem to be working.
As a side note, I could not find all the required JAR files for this version. I have read the following solution to a similar problem: Where are hadoop jar files in hadoop 2?. However, this did not work for me. It fails with the above runtime error.
I tried using older JAR files to resolve these issues, but new error keep occurring.
Does anyone have a solution to this problem? I am using NetBeans, if that makes any difference from some reason.
Including JARs in folders listed below worked for me:
share\hadoop\common
share\hadoop\common\lib
share\hadoop\mapreduce
share\hadoop\mapreduce\lib
share\hadoop\yarn
share\hadoop\yarn\lib
I resolved the problem by downloading the JAR files from commons.apache directory and from Maven repositories. Each time I added a new JAR to the project, the application crashed with a different error (a different class was not found) until I downloaded all of the JAR files from the Maven repository. After downloading a lot of JAR files from the online repositories, most of the JAR related problems seem to be resolved.
you can try right-clicking the Project, ->Build Path -> Configure Build Path
Go to your src folder, point to "Native Library", then edit the location to the location of your hadoop native library folder (normally: ~/hadoop-x.x.x/lib/native/"folder-depending-on-your-system")
My code working well from Intellij Idea by clicking Run. But created JAR file (build artifact) doesn't run with JVM Launcher error: "A JNI error has occur, pls check your installation and try again".
Previously it's was OK with builded JAR, but recently I modified my code and made some improvements and added some external JAR files to my project (HtmlUnit, HttpClient, etc).
I suppose that problem with dependencies, but how to fix?
You haven't included whole error message. It may be either problem with dependencies (not present/found) or they signature (some java libraries are signed and the problems occurs when the archive is repacked).
I was able to fix the problem by:
Configure the archive for the project:
Choose second option: "Copy to the output directry and link via manifest"
Build artifact
The artifact will be generated in the choosen directory. Also the dependencies will be copied next to it
You can enter into the directory from command line and run the app (or create a script):
I'm trying to use the library "selenium-server-standalone-2.37.0.jar" in a project. The project was previously using "selenium-server-standalone-2.24.1.jar", but I think that is too out of date for my current version of Chrome.
When I tried to switch out the old jar for the new jar, though, I started getting the Eclipse error:
Description Resource Path Location Type
Archive for required library: 'mypath/lib/selenium-server-standalone-2.37.0.jar' in project 'BookProject' cannot be read or is not a valid ZIP file BookProject Build path Build Path Problem
So I tried unpacking the jar with 7-zip, but in there I got the error:
Can not open file 'mypath/selenium-server-standalone-2.37.0.jar' as archive
Is this jar actually broken, or is there something I'm missing here? If this one isn't working, does anyone know where I could find the previous version? I couldn't find that anywhere.
If you are unable to open the jar even using 7-zip, then it's corrupt.
I'd recommend re-downloading it. Furthermore, when using eclipse, it might be a good idea to clear your dependency cache when upgrading things.. that usually solves things.
Edit
I suppose that it could be possible that the jar itself is just corrupt. If that's the case, try going to https://code.google.com/p/selenium/downloads/list and where it says "Search: Current Downloads" Select "Deprecated Downloads"
I still use
https://code.google.com/p/selenium/downloads/detail?name=selenium-server-standalone-2.35.0.jar
I get this error
java.lang.IllegalArgumentException: already added: Lcom/google/protobuf/AbstractMessageLite$Builder$LimitedInputStream;
and at the bottom of the Log,
Conversion to Dalvik format failed with error 1
after I added the 'libs' folder that includes jar files for google map/place that I'm trying to implement to an existing package.
I've done some research and found a solution which that
Project » Properties » Java Build Path » Libraries and remove all except the "Android X.Y"
but that's not in my case since I can't remove them from the list.(I can remove the Android Dependencies folder but i'm not sure if i should do that)
This issue is that you've got two jar files with duplicate classes. Try removing protobuf, if everything still compiles happily then hey presto you're in luck.
Otherwise, one workaround I found here is:
Add the library project using project properties -> android - add library project.
Add the linked src files to your build path as well.
Build the project. You should see the class files from you library project in the bin folder.
After that, REMOVE the linked src files from the library project in your application >project.
Run your application.
If you clean the project, then repeat these steps from step 2.
I just added a plugin to my Eclipse RCP project and am getting the error: Unable to find feature.xml in directory
What does this mean?
You have probably installed the plugin incorrectly. The feature needs to be unpacked in order for it to work. What happens now is that Eclipse is looking for a feature.xml file but only finding the jar file.
Check your .../eclipse/features catalaog and you will find jar'd features. Using a program and unzipping the jar file should solve the problem.
If you install using an update site the feature will be unpacked automatically.
Discussion about this fault here:
http://www.eclipsezone.com/eclipse/forums/t92012.html
The problem occurs if you install the plugin+feature not via update site.
check configuration/org.eclipse.equinox.simpleconfigurator/bundles.info to see whether your plugins has registered here.