Maven error ContextConfigApplicationContext cannot be resolved - eclipse

I tried to import the spring starter pom.xml in my Eclipse Luna. I was getting the below error. I dont remember getting this error before after I installed and reinstalled it. Any thoughts
The type org.springframework.context.ConfigurableApplicationContext cannot be resolved. It is indirectly referenced from required .class files
I tried the below thread, but didnt help.
https://java.net/jira/browse/PINEAPPLE-764

Your maven cache seems corrupted. You need to purge local repository.
See my answer at this link for the detailed steps to solve this problem.

Related

How to solve the error "Webdriver cannot be resolved to a type"?

To clear and run my code.
Webdriver cannot be resolved to a type
Please check and cross-verify the following to resolve the issue.
1: You might have unknowingly removed webdriver jars, try adding the webdriver(ChromeDriver) and selenium jars again.
2: Try using MAVEN and make sure while editing pom.xml you have provided the accurate scope and version of dependencies.
Hope this helps.

Cannot connect to RemoteNG Client. Check if old version of testng.jar is being used error-Eclipse Luna

I am getting an error like -
Cannot contact RemoteTestNG Client.Make sure you do not have older versions of testing.jar on your classpath.
Reason:Timeout while trying to contact RemoteTestNG.
I tried various solutions already present in stack overflow:
Check "Use project testng" option
Add latest testing.jar in classpath.
Check for duplicate testng jars in classpath.
Delete old testNG testsets ,clean workspace and restart workspace
But all the above solutions did not work for me and I ended up getting the same error again.
Please help me out here.
the latest release of testng eclipse 6.9.11 should fix this issue, please let me know (or fire an issue here https://github.com/cbeust/testng-eclipse/issues)
Noted: since this version, option "Use Project TestNG jar" was removed, to always respect the Project's TestNG lib.

Eclipse: Import Maven project, missing maven-gae-plugin

Coming from Visual Studio, I'm pretty new to the Eclipse IDE.
And finding it very difficult. I seem to get error messages of the type "missing ..." a LOT.
The latest issue I'm having, where I just can't get around is this:
I"m trying to compile & run this sample project: http://code.google.com/p/gwtgae2011/
When I choose "checkout maven projects from SCM" my SCM drop down is empty...
So I just checked it out with Hg manually. No problem.
Trying Import > Existing Maven Project. Seems to read the pom.xml alright, but shows an error:
"No marketplace entries found to handle maven-gae-plugin:0.8.1:unpack in Eclipse. Please see Help for more information."
Since I can't find it through updates or market within eclipse I downloaded maven-gae-plugin (http://code.google.com/p/maven-gae-plugin/downloads/list). I figured just dropping it into the "plugins" or "dropins" folder should be enough. Apparently not so...
Question: How do I fix this error?
(I tried both 3.6 & 3.7)
Links to some good eclipse tutorials covering these kinds of topics are very welcome too!
THANKS!
maven-gae-plugin is in central repo so it should be found.
Did you set the path to your local repo? http://united-coders.com/phillip-steffensen/maven-2-part-3-configuring-eclipse-for-apache-maven-2-projects
I ran into this error, what worked for me was:
Comment the plugin
Import into eclipse
Uncomment the plugin
Discover an error in the plugin XML
Fix error found in the plugin XML
I am not certain, but it seems like this is a unclear error that something about the pom.xml is invalid.

GlassFish NoClassDefFoundError - Netbeans project

I'm sometimes getting NoClassDefFoundError after deploying web application in Netbeans (6.9.1). It's actually problem with Netbeans not deploying entire project (not copying class files or other relevant files), but only part of it.
Running "Clean & Build" a few times and/or copying rest of the files solves the problem, but it's very inconvenient.
Anyone knows the cause or solution of this problem?
Try clearing your Netbeans cache, or check out the bug fixes for Netbeans 7.
The cache is at ~/.netbeans/6.9/var/cache. I found instructions to just delete the index/ folder in the cache, but that didn't seem to be enough.
EDIT: Deleting the entire cache didn't seem to resolve it, either.
Your answer is not much clear but,
I suggest to add your required jar files in Netbeans library then import the library into your project..
If this does not work then i'll be glad to having the complete situation and errors to be written here...

Eclipse & JSP: java.lang.NoSuchMethodError: javax.servlet.jsp.tagext.TagAttributeInfo.<init>(Ljava/lang/String;ZLjava/lang/String;ZZ)V

I'm using Eclipse 3.4 with WTP 3.0.2 and running a fairly large Dynamic Web Project. I've set up the project so that I can access it at http://127.0.0.1:8080/share/ but whenever I do, I get the following error:
java.lang.NoSuchMethodError: javax.servlet.jsp.tagext.TagAttributeInfo.(Ljava/lang/String;ZLjava/lang/String;ZZ)V
at org.apache.jasper.compiler.TagLibraryInfoImpl.createAttribute(TagLibraryInfoImpl.java:572)
at org.apache.jasper.compiler.TagLibraryInfoImpl.createTagInfo(TagLibraryInfoImpl.java:401)
at org.apache.jasper.compiler.TagLibraryInfoImpl.parseTLD(TagLibraryInfoImpl.java:248)
at org.apache.jasper.compiler.TagLibraryInfoImpl.(TagLibraryInfoImpl.java:162)
at org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:423)
at org.apache.jasper.compiler.Parser.parseDirective(Parser.java:492)
at org.apache.jasper.compiler.Parser.parseElements(Parser.java:1552)
at org.apache.jasper.compiler.Parser.parse(Parser.java:126)
at org.apache.jasper.compiler.ParserController.doParse(ParserController.java:211)
at org.apache.jasper.compiler.ParserController.parse(ParserController.java:100)
at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:155)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:303)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:875)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
at java.lang.Thread.run(Unknown Source)
As none of the above files is my own, pointing out the cause of the problem is quite hard. Any ideas where to start looking?
I ended up answering my own question: the problem was that among the necessary JARs that I had added to Tomcat was a conflicting servlet.jar. When I removed this, the error disappeared.
Did you set a Tomcat path in "Preferences->Tomcat->Advanced->Tomcat base" ?
Try to clean that path (getting back to default configuration), and check if that does solve the problem.
most probably the tomcat plugin in the eclipse cause the conflict problem, i manage to solve the problem by getting the same version jar file and override it in the tomcat plugin in the eclipse.
I had similar problem and I had fixed this problem by Ensuring that i have correct version of servlet.jar in the classpath that is being taken by my application and also i had kept old J2EE.jar file in the classpath and that was causing the main problem. Hence I removed it from the classpath to ensure that it uses by default files.
I had the same problem running Eclipse Helios, with Maven handling dependencies and using Jetty as webserver. After updating to Spring 3.1 I suddenly got this problem, but only on my local development machine.
I first deleted the spring and jetty folders in my local maven repository and updated the dependencies, but that didn't improve the situation.
Then I just deleted the servlet-api and servlet-api-2.5 folders that comes with jetty (but leaving everything else), I got it to work.
All hail the magic of the classpath.