I'm facing a strange issue while using Eclipse-Indigo (32 bit).
I'm running my code on my machine and code is not getting executed correctly, there is no exception/error shown but files with extenion ".bs" are getting generated.
The same code is executed correctly on a different machine. Can anyone suggest what might be the issue here?
Can anyone please atelast answer what does ".bs" files stand for? Is it bitstream?
Yes, so finally after lots of debugging, I was able to find solution to this.
Before I talk about solution, first thing, this has nothing to do with different eclipse versions or different java versions.
So, the .bs files were generated because the client and server had different versions of project jars (not the third party jars).
My client project in Eclipse was referring to older jars while the server had latest jars.
I think this problem will only occur if you have multiple dependent projects or project jars.
Related
I have a code snippet that is part of my eclipse plugin. When testing it in a runtime eclipse version (That means it is not packed into a jar afaik) it runs just fine.
However if I pack my plugin into a jar and then run the respective code snippet it results in a complete crash of eclipse without any error logs (I'm assuming that it even crashes the JVM).
I'm running this on Linux Mint.
According to this post the Desktop API is broken in older Java versions but it should be fixed in Java 8.
Has anyone an idea why this is still happening?
Although this is not an answer to the question why the Desktop API breaks down when used inside a jar file, I want to point out an alternative that I have found (thanks to #Holger) for my case (working with the eclipse APIs):
You can simply use PlatformUI.getWorkbench().getBrowserSupport().getExternalBrowser().openURL(<YourURL>); in order to open the given URL in the system's default browser.
So my minecraft server has an economy plugin I've been working on. After battling a couple of days, I realised this is a common problem with Java that it won't unload the classes which are already loaded. So when I tried the plugin on a fresh server instance, it was working correct.
My question is how can I fix the original server? I tried deleting the updated JAR file from that server, ran and stopped the server as a guess that it'd remove the pre-loaded classes but instead that generated the files related to the previous version of plugin, even though the plugin's JAR wasn't in the directory.
First, what is not working? If it's crashing, please edit this and add a bit of the console log where the error is happening.
If it's working properly on another server make sure the JARs are all compiled from the latest source.
There could also be a conflict with another plugin. Try disabling all other plugins and see if it works than.
I'm currently working on a GWT project in my company. Although DevMode works perfectly fine in eclipse, I still want to use Intellij Ultimate Edition for development.
But after all setups were done (Facet, Run/Debug configuration) I'm getting this weird processing window saying "Deleting Obsolete Files..." when I run the program and after that all my pre-deployed resource files in the war directory were gone (recursively...).
BTW, I use a script to deploy all my stuff. And the only argument I set for DevMode is:
-war /absolute/path/before/war/folder/war
Does anyone know the reason why Intellij is deleting my files?
After sending a request to Intellij support team, they gave me the following answer:
Adding the following two lines to the IDEA_HOME/bin/idea.properties file:
idea.gwt.clear.unit.cache.before.run=false
idea.gwt.clean.files.created.by.dev.mode=false
Which makes sense, because the only thing I need is to prevent Intellij from deleting my local cached files. Problem solved.
I switched to IntelliJ from Eclipse and never had a problem with GWT debugging in IntelliJ. It is most likely deployment-related.
First, I use Tomcat on the client side just like I'd use it in production. No built-in Jetty. Specify -noserver in Dev Mode Parameters. And make sure to start you server (in Debug mode since you are likely to debug it as well).
Other than that you may be doing custom build/deployment which is causing it. I do everything by the book. IntelliJ is Maven-centric, so it needs to be a textbook Web App module. Unlike Eclipse you don't need to specify where you war directory is. It is "webapp" per Maven convention. I suggest recreating the module from scratch.
if someone could help that would be amazing.
This project is being started in the NetBeans IDE EE version that comes with GlassFish Server. I've used Lucene to make a searchable twitter index of ~5G and am getting the NoClassDefFoundError only when called from the server giving a 500 Page Error.
The problem really confuses me, NetBeans is able to compile and run the code. When I call my functions from the same project in the IDE I'm able to use it perfectly. When I compile to a WebProject and launch it seems like GlassFish isn't able to find the files but I've made sure it has all the jars in the WAR file in the proper directories.
I've tried this both manually adding all the library files and by using Maven. Neither have worked, I've even added classpaths to the files elsewhere and added the files to glassfishes /lib folder.
Here is my setup.
http://imgbin.org/images/22748.PNG
I guess the problem is that you are mixing two different versions of lucene together (3.4 and 4.0).
I don't know why this works on your local Glassfish instance but you should update your dependencies so that they all have the same version.
I'm trying to write a simple java applet program, but it seems that I'm missing the javax.servlet.* class definitions.
Using:
apple snow
eclipse Java EE ide
Do I need to add a specific JAR file to my project and if so, which one?
I have Macports installed in case something from the ports might be helpful.
This is all result of misconceptions (Applets have nothing to do with the actual problem) and ignorance about Eclipse (if offers builtin ways to seamlessly integrate and link the one and the other, the Java EE variant has already a Tomcat plugin, you just have to integrate the server and associate it with the web project).
In the future you should be more precise and detailed about the problem (and thus not telling like "...it seems that..."). Post the relevant code snippet which caused the problem. Post the actual error message (with stacktrace, if any). Post the steps to accomplish to reproduce the problem. Also see: How To Ask Questions The Smart Way.
I've answered several times before how to get started with Eclipse+Tomcat+Servlets, you may find it useful as well:
Question about installing Java EE locally?
Tomcat servlet problem - class not found
CLASSPATH, Java Buld Path (eclipse), and WEB-INF\LIB : what to use, when, and why?
Thank for all of your helpful comments.
I installed tomcat 6 and it contains the missing jar in order to compile the project.
Nice plug-in to load tomcat applications :
Sysdeo Eclipse Tomcat Launcher plugin - http://www.eclipsetotale.com/tomcatPlugin.html
Using Netbeans i was able to properly compile tomcat applications just by creating a new java web application. for now i'll stick to netbeans, it also has a nice gui for connecting to the server and seeing the installed applications and their status.