Community
Participate
Eclipse IDE
Hello, My work environments are like the following. Eclipse: 3.1 J2SDK: j2sdk1.4.2_08 OS: Windows XP Professional Plug-in: MyEclipse, XMLBuddy Framworks in the working project: Hibernate 3.0.5, Struts, ... After newly installing Eclipse 3.1, I imported a project created by earlier versions of Eclipse from v2.1. After importing, a list of Problems were detected. Many of them were "The serializable class XxxxXxxx does not declare serialVersionUID..." in the "Problems" view. For the problems, I used the Quick Fix (Cntr-1) menu to "Add generated serial version ID." By doing this way, I created many sercialVersionUID for classes missing them. But the system got halt when I did the same thing for some classes. Those classes are marked with [*] in the list below, as examples. [*] public class FileUploader extends HttpServlet {...} [*] public class SysProfileWrapperImpl implements ProfileWrapper, HttpSessionBindingListener {...} public interface ProfileWrapper extends Serializable {...} [*] public class TimestampTag extends MyTagSupport {...} abstract public class MyTagSupport extends TagSupport {...} The error message poped up in the [Progress Information] dialog box is +---------------------------------------------------------+ | Computing serial version ID... | | |||||||||||||||||||||||||||||||| | | Starting virtual machine... | | [Cancel] [Details >>] | +---------------------------------------------------------+ And it never advanced from a certain point. I clicked the [Cancel] button, and the button became disabled. I waited but nothing happened after that. I couldn't kill the dialog box and so I could get back to the main eclipse window. The [Detail >>] button initially appeared with disabled status. I hope you may simulate the situation I had and fix the problem whatever the solution is... I thank you very much for providing Elipse, very nice development tool for developers like me... Sincerely, Yunseuk Kim
Tobias, can you please investigate. Might be a 3.1.1. candidate.
Tagging as 3.1.1. Tobias, can you please investigate and explain how risky a fix would be.
Just want to note that I also have this problem - for some classes, quick-fixing to generate the serial version ID hangs with the same dialog box reported above. Note that I have MyEclipse installed - the 4.0M2 development release. (In reply to comment #2) > Tagging as 3.1.1. Tobias, can you please investigate and explain how risky a fix > would be.
Yunseuk or Larry: Could you please attach a code snippet where the defect is reproducible?
Tobias: I was kind of busy... Here I attached the code produced the defect. Please let me know if you need more info. Thanks! ---------------------------------------- package abc.servlet; import javax.servlet.ServletException; import javax.servlet.http.HttpServlet; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; ... public class FileUploader extends HttpServlet { private static boolean COMPLETED_CLEANING = false; public FileUploader() { super(); } public void destroy() { super.destroy(); ... } public void doPost(HttpServletRequest request, HttpServletResponse response) ... } public void init() throws ServletException { ... } ... } ----------------------------------------------
I could not possibly reproduce the defect with this snippet. You would best attach the project which contains the class FileUploader (or at least a compilable subset)
Found another test case: Class path containers which are explicitely put on the bootstrap class path. This is the setup used to put j2ee.jar on the class path Attaching patch...
Created attachment 26369 [details] Patch to correctly handle bootstrap class path entries
Dirk, Markus, can you please cast your vote?
Tobias, it looks like that classes that are on the boot class path for the project are passed as normal class path entries to the target VM. Can this cause any problems ?
The only thing that matters is the order on the class path of the secondary VM. The appropriate JRE is the only thing which is put on the system class path, the rest is put on the user class path in correct order. The only case where problems could occur are nameclashes with JRE classes.
Fix looks good and solves the problem. Go for 3.1.1.
Fixed in 3.1.1 maintenance branch > 20050823
Fixed in HEAD > 20050824 File bug 107826 for remaining issues and improvements
Markus please set to Verified in M20050831-1200
Hi, im new here. How do I apply this patch in my eclipse ? tks, Rafael
You don't need to. This is fixed in Eclipse 3.1.1, 3.1.2 or any version released after 2005 08 24. You can create a patch in the Team Synchronizing perspective. You can apply a patch by right clicking on any package in the package explorer -> Team -> Apply Patch...
Hi, I had the mentioned problem, saw this bug and installed Eclipse 3.1.2, but I still have the problem. Can anyone tell me, how this can happen? Thanks Susanne
Remaining issues have been fixed with bug 107826
Thank you for the hint, Tobias and sorry for bothering you again: Now I've installed Version 3.2M5. When I choose "Add generated serial Version Id", eclipse only generates "private static final long serialVersionUID = 1L;" Is it my fault or yours? Thanks, Susanne
Does the class to generate an SUID for reference any SWT classes? If yes, we cannot fix this right now, since we are missing information about native libraries on the classpath. If not, please file a new bug report against JDT UI with exact steps to reproduce.
FYI: The problem with SWT (and therefore most Eclipse UI plugins) is bug 127647.
Hi, I've got the mentioned bug with Eclipse 3.1.2 with the following plugins: CDT, WTP (with prerequisites EMF,GEF,JEM and XSD), ResourceBundleEditor_0.7.2. All plugins except for the last one were downloaded yesterday. The same is for the Eclipse itself. I use JDK 1.5.0. The problem reliably exists while generating Serial ID for the class: package performance.monitoringagent.agent; import java.util.Properties; import java.io.FileInputStream; import java.io.IOException; /** * User: Peskovsky * Date: 23.01.2006 * Time: 18:45:15 */ public class AgentProperties extends Properties { public static final String FILENAME = "./agent.properties"; public static final String LISTENING_PORT = "listeningPort"; public static final String MEASUREMENTS_GETTING_PERIOD = "measurementsPeriod"; public static final String HISTORY_PERIOD = "historyPeriod"; public static final String CONNECTION_ACCEPTING_TIMEOUT = "connectionAcceptingTimeout"; public static final String MEASUREMENTS_CLEANING_PERIOD = "measurementsCleaningPeriod"; public static final String MEASUREMENTS_OVERFLOW_CHECK_DELAY = "measurementsOverflowCheckDelay"; public static final String INTER_REQUESTS_DELAY = "interRequestsDelay"; private static AgentProperties agentProperties = new AgentProperties(); static { try { agentProperties.load(new FileInputStream(FILENAME)); } catch (IOException e) { System.out.println("Error reading agent.properties file."); e.printStackTrace(); } } public static final String getValue(String property) { return AgentProperties.agentProperties.getProperty(property); } } Thanks for paying attention. Peter
Sorry, I've not mentioned your last comment.
Please do not comment on already closed bugs, but rather open a new one if the problem has not been fixed in the 3.2 stream.