Workspace unsaved changes mystery demystified

by Szymon Ptaszkiewicz ( at October 01, 2014 01:43 PM

Are you an Eclipse plug-in developer and you have seen at least once a warning saying something about unsaved changes in the previous session like the one below?

Well, I bet you did, although you probably never paid attention to it since the warning is quite harmless, although can be very annoying. Let me explain why...

The warning is generated during Eclipse startup if your workspace was not properly saved during the previous session. Not properly saved means that something bad happened like process crash, blue screen, power down, etc., and normally you would lost your work. However, Eclipse is able to detect this situation and recover. Not a very fancy recovery, but it does the job and so the warning message is very informative because it's good to know that Eclipse just recovered your work behind the scenes. So far so good.

The annoying part is that it can happen even if you are 100% sure that you closed your Eclipse the right way without any crash and all looked good when you closed it the last time. So, why Eclipse tries to recover something if there is should be nothing to recover?

The answer is that in most cases you didn't do anything wrong and the unsaved change was generated by some badly written plug-in that modified your workspace after you already asked Eclipse to shut down. If you are a curious person like I am, you will probably ask "Fine, but which of the plug-ins is the bad one?" Well, easier said that done. Especially because it happens during shutdown and you will be warned there was some unsaved change during next Eclipse startup. This is a bit too late...

The warning became so annoying that I decided to spend some time to adjust the workspace save behaviour so that we can distinguish unsaved change caused by power down from the one caused by a badly written plug-in and then find out in a semi-automatic way which plug-in is the culprit. Since Eclipse SDK 4.5 build-id I20140930-0800 additional error message will be logged if there is any code that tries to modify your workspace after you already asked Eclipse to stop. Here is an example:

!ENTRY org.eclipse.core.resources 4 10035 2014-09-30 17:27:37.511
!MESSAGE The workspace will exit with unsaved changes in this session. Snapshot requestor:$NotifyJob(Updating workspace)
java.lang.RuntimeException: Scheduling workspace snapshot
at org.eclipse.core.internal.resources.SaveManager.rememberSnapshotRequestor(
at org.eclipse.core.internal.resources.SaveManager.snapshotIfNeeded(
at org.eclipse.core.internal.resources.Workspace.endOperation(

If you have auto-build enabled, in most cases the error will mention one of these classes:

This is the code that requested additional workspace save after you manually asked Eclipse to stop but in reality, this is not the problematic part of the code. So, how can you tell which workspace operation triggered an auto-build which in turn requested additional workspace save? Here is where the "semi-" part of the solution plays a role.

Whenever you see an error saying that The workspace will exit with unsaved changes in this session., you already know that some plug-in modified your workspace without your knowledge after you asked Eclipse to stop. In order to find this plug-in you need to enable a few debug options including the new debug option for resource change notifications and then capture the console output to a file.

In the case I investigated, here is what I did:

1. Add -consoleLog to your eclipse.ini file.
2. Run Eclipse using the following command:

eclipsec.exe >> trace.txt 2>&1
3. Go to Window > Preferences > General > Tracing preference page.
4. Enable the Enable tracing option.
5. Expand the Platform Core Resources node and enable the following options:
Not all of them are strictly necessary, but since you don't want to do this more than once, it's better to gather all the data at first attempt.
6. Start using your Eclipse normally and observe the Error Log view. If you see "The workspace will exit with unsaved changes in this session." error followed by "The workspace exited with unsaved changes in the previous session;..." warning, it is time to look at the trace.txt file.

The relevant part of the trace file is between the line that says:

Tue Sep 30 17:27:34 CEST 2014 - [ModalContext] Job): Full save on workspace:  starting...
and the first line that contains
java.lang.RuntimeException: Scheduling workspace snapshot

Any resource change event that happened between this two lines could be the culprit of unsaved changes so now you need to read the trace file and see which event is suspicious. In my example, it was quite easy because the following event was generated after every full save on workspace:

Build kind: 0
Resource: null
/[*]: {}
/External Plug-in Libraries[*]: {}
/External Plug-in Libraries/.searchable[*]: {CONTENT}

What it means is that whenever I ask Eclipse to stop, some plug-in modifies the content of /External Plug-in Libraries/.searchable file as part of the save operation. This results in subsequent resource change events being populated and triggering auto-build and in the end workspace snapshot which will give the unexpected change warning during next startup. Having all this data, the only thing that is left is to find out which plug-in is responsible for /External Plug-in Libraries/.searchable and then fix it.

If you want to see an example how the whole investigation was done in practice, take a look at bug 444988 where one of the problematic plug-ins was identified and will be fixed in the near future hopefully.

Happy hunting! :)

by Szymon Ptaszkiewicz ( at October 01, 2014 01:43 PM

Building the Collatz Graph in Henshin

by Christian Krause ( at September 30, 2014 08:30 PM

The other day I saw an online video about a number-theoretical problem called the Collatz conjecture. The video included some visualizations of the problem which were based on force-directed graph drawing. It was immediately clear to me that such visualizations could be also easily done in Henshin. So I built a minimalistic EMF model and sketched two simple rules:

The first one multiplies x by 2, the second one is the inverse of the 3x+1 rule. Technically, it is not exactly the inverse of the Collatz function, but the conjecture is still true if and only if these two rules can generate every natural number (if we ignore the upper bound in the first rule).
Finally I created an instance model for the initial state and set up a state space. In the following video you can see how to use Henshin's state space explorer to generate the Collatz graph. Have fun. 

by Christian Krause ( at September 30, 2014 08:30 PM

Little Known Things about the Eclipse Infocenter: Language Switching (4/5)

by howlger at September 30, 2014 12:44 PM

The Eclipse Infocenter is the Eclipse help system launched as a web application. Three of five well-hidden features about the Infocenter have already been presented: Basic and Bot Mode, Deep Linking and Search Links. Here comes little known thing number four: Language Switching.

The Infocenter is multilingual. The Eclipse Babel project provides languages packs for the user interface. When the content is available in different languages it depends on your web browser settings which language will be chosen. The language setting of your web browser can be overruled by appending ?lang=… to the URL. Eclipse Luna Help is in English only, but for example the Infocenter for IBM Rational Team Concert for System z 2.0 is available in French (lang=fr), Spanish (lang=es), Japanese (lang=ja), Korean (lang=ko) and many other languages. It is also possible but rarely used to distinguish between American English (lang=en_US) and British English (lang=en_GB). In IBM’s Infocenter for Content Analytics Version 2.2 you can even switch the user interface language to Arabic (lang=ar) with right-to-left layout:

In Arabic: IBM's Infocenter for Content Analytics Version 2.2

By the way, to confuse your colleagues you can switch the layout of their non-Arabic Eclipse IDE including help to right-to-left with the runtime option -dir rtl. ;-)

Eclipse with -dir rtl

Sometimes it make sense to provide only parts of the help content in different languages. For instance, often the user manual is available in several languages, whereas the API documentation is available in English only. But also if the content is not multilingual the chosen (user interface) language affects searching. This is caused by the language-dependent stemming: searching in English for plan without quotes will find topics that contain planning or plans, the same query in Korean does not find these English topics. Infocenter administrators can limit the list of supported user interface languages via the runtime option -locales.

Stay tuned for the last little known thing about the Eclipse Infocenter on my list: Debugging Information!

Flattr this

by howlger at September 30, 2014 12:44 PM

Save the date: Eclipse DemoCamp December 3rd 2014

by Jonas Helming at September 30, 2014 10:06 AM

Like in the past years, we continue in our tradition of hosting a “Christmas DemoCamp”. Please save the following date and mark your calendars on December 3rd 2014 for the next Eclipse DemoCamp in Munich!

We offer 80 seats, but we usually receive around 200 registrations. To give everybody the same chance, registration for the event will start exactly on October 13th 2pm. There you’ll also find detailed information on the location, time and more.

The agenda is not completely set, as soon as it is ready there will be another announcement. If you are interested in giving a talk, please contact me.

We are looking forward to your registration and seeing you in December!



Leave a Comment. Tagged with democamp, eclipse, democamp, eclipse

by Jonas Helming at September 30, 2014 10:06 AM

My Fav Tips and Tricks in Eclipse IDE - PART 1

by Its_Me_Malai ( at September 30, 2014 08:52 AM

Even today, many a times participants ask me for a shortcut to create Local Variables, organise imports etc during my training sessions. But i never thot of making notes of these Short Cuts or Quick programming Support available in Eclipse for Smart Programmers.

Inspired by My Top 10 Tups on how to be more productive with Eclipse IDE written by of eclipsesource, i decided to blog about some of the interesting shortcuts that really increase your productivity.

Tip 1 : Copy Pasting of Path from Windows Explorer to Eclipse JDT Editor.
Typically Windows path would be "C:\Program Files\Java" but in Java \ is considered as escape character, so it has to be \\ or /. So to solve this problem, there is an option in windows/preferences.
1. Open Preferences Dialog and in the Filter Text, enter typing.
2. Select Typing under Java/Editor
3. On right hand side, you will find a group named In string literails, inside which you have 2 checkboxes. Enable "Escapt texts when pasting into a String literal"
4. Now copy the Path from Windows Explorer and paste within "" to see the magic.
5. All '\' should be converted to '\\' while pasting itself.

Tip 2 : Generating Getters and Setters in a bean class.
1. Highlight the class level variable for which you need Getters and Setters.
2. Press Ctrl + 1 [Shortcut for QuickFix] and select the option Create Getters and Setters for 'var'
Tip 3 : Use of Code Templates. Most of the Java Keywords or SWT Keywords would be available as Code Templates in Eclipse. Using those templates makes life definitely a lot easier.
1. Type instanceof and press Ctrl + Space
2. You will see a template being offered with a Yellow Sticky icon.
3. Select on that and the complete syntax of instanceof along with if condition, temporary variable etc would be provided.

This definitely increases your typing speed and not worrying about syntax errors or variable initialisation etc. List of templates supported can be found in windows/preferences. Go to windows/preferences and type templates in the filter box and you would see that every editor plugin will provide variety of templates that is offered on the editor via Content Assist.

Tip 4 : Filtering Imports package during Ctrl + O or Ctrl + Space.
When you type button and do Ctrl + Space, you will always find button from java.awt and org.eclipse.swt, but we are interested only in buttom from swt. So y show from java.awt. So you can define a filter over packages to show on Ctrl + O or Ctrl + Space.

Go to windows/preferences and type Type Filters in filter box. You will see a screen as shown below. add the packages that you want to filter from Ctrl + O or Ctrl + Space.

Learned from of eclipsesource. Link provided above.

Tip 5 : Short Cut for Extracting as Local Variable [Alt + Shift + L] 
Many a times we will use codes like PlatformUI.getWorkbench(); and then we will want to store that into a variable. We can select that line, right click > refactor > extract to local variable. But this also has a shortcut. Highlight the line and press Alt + Shift + L and this will create a local variable to store the method return value.

These are some of the tips that i really like and use to keep my programming productivity high.

by Its_Me_Malai ( at September 30, 2014 08:52 AM

Eclipse Luna SR1 Now Available

September 29, 2014 06:06 PM

The SR1 release of the Eclipse Luna release train is now available for download.

September 29, 2014 06:06 PM

Looking for Eclipse Standard download?

by Gunnar Wagenknecht at September 29, 2014 01:35 PM

This is just a heads up that with Luna SR1 the formerly called “Eclipse Standard” package is no longer available. It has been renamed to “Eclipse IDE for Committers“.

For details/background please have a look at bug 441957.

The main reason for this change is because the name “Eclipse Standard” meant very different things for people so we decided on a name which clearly identifies the target audience of that package. It contains tools for Java and OSGi/Plug-in development and the source code of Eclipse itself. The history of that package is the Eclipse SDK which IMO shouldn’t be a recommended standard download of Eclipse.

Bug what if I just want an unbranded bare minimum Eclipse?

Here are the steps I suggest in order to build your own Eclipse base:

  1. Download an Platform Runtime Binary archive from
  2. Unzip to your local disc and start Eclipse
  3. Install the Eclipse Marketplace Client
    1. Got to Help → Install New Software…
    2. Select Work with: Luna –
    3. Check General Purpose Tools → Marketplace Client
    4. Click Next
    5. Review the installation details and click Next
    6. Accept the license and click Finish
    7. Restart Eclipse

Now you have an absolute bare minimum, unbranded Eclipse package built by yourself. From here it’s easy to install additional plug-ins from the Eclipse Marketplace (got to Help → Eclipse Marketplace…).

I recommend at least the following plug-ins:


by Gunnar Wagenknecht at September 29, 2014 01:35 PM

Getting Started with IoT and Java:

by Ian Skerrett at September 29, 2014 01:22 PM

Today at JavaOne we announced the Open IoT Stack for Java, a set of open source technologies that will make it easier for Java developers to build IoT solutions. The focus of the technology is to enable developers to connect and manage the devices, sensors and actuators that are part of their IoT solution. VisionMobile estimates there will need to be 4.5 million IoT developers by 2020.  The Open IoT Stack for Java is intended to help Java developers be some of those developers that are building IoT solutions.

To get started consider the following:

  1. Purchase some hardware, like the Raspberry Pi, and start experimenting.
  2. Check out the tutorial to build a smart greenhouse.
  3. Take the time to research and learn two new IoT standards, MQTT and CoAP. Eclipse Paho and Californium provide implementations of each.
  4. For the home automation DIY, learn about Eclipse SmartHome , a Java based framework for home automation.
  5. Discover the developer resources available at different sites, like and

If you are at JavaOne, please make sure you drop by our booth to see some very cool demos.

by Ian Skerrett at September 29, 2014 01:22 PM

Eclipse Simplifies Development of Internet of Things (IoT) Solutions with Open IoT Stack for Java

September 29, 2014 12:46 PM

The Eclipse IoT community is making it easier for Java developers to connect and manage devices in an IoT solution by delivering an Open IoT Stack for Java.

September 29, 2014 12:46 PM

Modeling Symposium @ EclipseCon Europe 2014

by Jonas Helming at September 29, 2014 11:46 AM

The modeling symposium at EclipseCon Europe 2014 takes place on Tuesday, October 28th from 5.30pm-6.30pm (see session details at EclipseCon Europe website).

I’m happy to present the agenda of the selected talks:

  1. Ecrit – Marco Descher

  2. UML-RT in Papyrus – Charles Rivet

  3. EMF Parsley N&N – Vincenzo Caselli

  4. MPS-IncQuery – István Ráth

  5. Interactively Developing Generators and Transformations – with Xtendency – Marco Eilers, Klaus Birken

  6. The 13 Most Important Functions of CDO – Eike Stepper

In this year’s format each presenter will have 10 minutes. I’m looking forward to this event and interesting discussions afterwards. Hope to see you there!


Leave a Comment. Tagged with eclipse, eclipsecon, eclipse, eclipsecon

by Jonas Helming at September 29, 2014 11:46 AM

Changing the Order of PreferencePage

by Its_Me_Malai ( at September 29, 2014 06:12 AM

Many a times in a training, i am asked how do you change the order of Preference Page? Can we make our preference page appear 1st ? Most of the time i would answer PreferencePage order cannot be altered as it is fixed to be Alphabetic. And this is a default implementation that cannot be changed as there are so many plugins in eclipse and everyone will then want their preferencepage to appear 1st.

But GENERAL section in preferences was always an exception to this rule. It always appears 1st in Eclipse IDE. But if used in our own RCP, the alphabetic rule applies. That made it evident that somehow the 1st preference page could be changed.

Further investigation took me into understanding that this can be achieved only in the case of RCP when you can control ApplicationWorkbenchAdvisor. In ApplicationWorkbenchAdvisor you need to override getMainPreferencePageId() method and return the ID of the preferencePage that should appear 1st in your RCP similar to General in Eclipse.

Run your RCP to see your PreferencePage appear 1st.

by Its_Me_Malai ( at September 29, 2014 06:12 AM

Shellshock bug, open source maintenance and quality

by Scott Lewis ( at September 26, 2014 06:02 PM

Interesting NY Times article about shellshock bug, and it's relationship to open source maintenance and quality

by Scott Lewis ( at September 26, 2014 06:02 PM

Get a handle on Handly!

by Vladimir Piskarev at September 26, 2014 02:47 PM

Concurrently with the Handly releases announced today, we are also making available (under the Eclipse Public License v1.0) a step-by-step guide to getting started with Handly. It is hosted on GitHub. Despite being a work in progress, we do hope that even in its current form it will be useful for Handly adopters. Early feedback is welcome.

The Guide

by Vladimir Piskarev at September 26, 2014 02:47 PM

Announcing Handly 0.2 and 0.1.1 Releases

by Vladimir Piskarev at September 26, 2014 02:47 PM

In celebration of Eclipse Luna SR1, I’m very pleased to announce the simultaneous availability of two Handly releases.

Version 0.2

This is a major Handly release with the following themes:

Integration with Xtext 2.7.x — The most important goal of this release is to provide integration with Xtext 2.7.x. It will not support previous Xtext versions due to breaking changes introduced in Xtext 2.7 (see bug 442674 for a discussion).

Scalability — Handly 0.1 has been tried out on source files containing tens of thousands of lines of code. From those tests it seems that the JDT-inspired design would scale pretty well. Of course, there is always room for improvement, and this release is going to be even better in this regard.

API Quality — This release includes a number of API enhancements.

No major release can happen without some API breakage. Here is a summary of breaking changes in this release.

Version 0.1.1

Concurrently with 0.2, we are also shipping 0.1.1 release to bring important bug fixes to those adopters who still rely on the 0.1.x line. Please note that this release (as well as the 0.1) will not work with Xtext 2.7 or greater due to breaking changes introduced in Xtext 2.7.

We are making available these two Handly releases simultaneously to minimize disruption for adopters who use Handly integration with Xtext. While Handly 0.1.1 remains compatible with Xtext 2.5, it will not work with Xtext 2.7 or greater; the 0.2 release is integrated with Xtext 2.7.x but doesn’t support previous Xtext versions.

Enjoy and don’t forget to leave your feedback on the adopter forum.


by Vladimir Piskarev at September 26, 2014 02:47 PM

Eclipse 4.5 (Mars) requires Java 7

by Lars Vogel at September 26, 2014 10:24 AM

FYI: Our Eclipse 4.5 (Mars) release requires Java 7. I think these are great news. See Eclipse PMC wiki for details.

by Lars Vogel at September 26, 2014 10:24 AM

Javascript ES6/ JSHint configuration support in LiClipse 1.2.0

by Fabio Zadrozny ( at September 26, 2014 01:24 AM

The latest LiClipse 1.2.0 release is out.

The Javascript editor now supports ES6 (EcmaScript 6) constructs (but JSHint analysis must be manually configured to accept those constructs) and regular expressions on javascript are now properly colored.

Now it's also possible to specify the JSHint and HTML code analysis/code formatting configuration for a project. The main thing to note is that this must be done per-project with a YAML file (as explained at: and

I'm not sure if having a way to change the globals will be added in the future -- mostly, I think that setting the globals is usually cumbersome, and if someone gets your project and it's not configured in itself, different users may have different results, which isn't really nice... on PyDev from the beginning things were only global, but as time passes by, I'm pretty sure that having the local from the start would be much better (which is something I plan to add in the future)!

Enjoy :)

by Fabio Zadrozny ( at September 26, 2014 01:24 AM

Eclipse Newsletter - Project Quality

September 25, 2014 03:22 PM

This month, we bring you a newsletter focused on Project Quality. Read it now.

September 25, 2014 03:22 PM

Eclipse Day India 2014 - Presentations and Photos are Available

by Its_Me_Malai ( at September 25, 2014 11:35 AM

Eclipse Day India 2014's success can be viewed thru the uploaded Presentation and Photos.

Eclipse Day - Photos

Eclipse Day India 2014 - Presentations

Click on the Pics above to get more details on them. Thanks once again to the organiser for organising such a successful event and looking forward to meet the Indian Eclipse Group @ Demo Camp to be held towards the end of the year.

by Its_Me_Malai ( at September 25, 2014 11:35 AM

What makes EclipseCon Europe a good conference ?

by Cédric Brun ( at September 25, 2014 09:12 AM

EclipseCon Europe 2014 is getting close and it will only get harder to book hotel rooms and flights. It's probably time to decide whether you come or not. Let me tell you what you can expect from such an event :

Getting in touch with the technology,  the people behind it and its users.
I would argue that this is the main point of such a conference. Those 3 days are filled with presentations either from the project commiters giving a glimpse of what you could expect, or from users of the technology giving experience reports about how it helped them and what you might want to keep an eye on. Furthermore, presenters are sticking around during the conference and the friendly spirit makes it very easy to start a discussion and learn more.
This content is something you won't find anywhere else.

A lot of Modeling content
If you are into modeling or using it at work, going to this conference should be a no brainer. Xtext, Sirius, EMF Compare and many more technologies are represented during those days.

Speakers are good
In the last five years we have seen an impressive boost of quality regarding the talks and the way they were given. Most of the talks are kept in a 35 minutes slot and with the Program Commitee we worked hard to make sure the sessions will have good content but also good speakers.

Tutorials,  Unconference
3 hours sessions are planned so that you can get your hands dirty using some of the Eclipse Technologies. IoT,Cloud , Java, OSGi, EMF or Xtext are covered for the 2014 edition of the conference. Not only that but rooms are booked for the "Unconference"  so that working groups can collaborate or projects can setup a "mini hackaton", that's a rare chance to gather people from different countries to work with.

Social Events 
The Circus, the concert, the receptions. Many occasions to enjoy yourself and to meet the Eclipse family.

If you haven't registered yet you might consider doing it now as the price will rise at the end of the month.  I'm looking forward to meet you there !

by Cédric Brun ( at September 25, 2014 09:12 AM

How Should I Use Guice/Spring/Blueprint Inside My Bundle?

by Peter Kriens ( at September 25, 2014 08:05 AM

Someone asked me over mail: How should I use Guice (or any other injector) inside my bundle? The short answer is: don't. The slightly longer answer follows hereafter. Injectors like Spring and Guice were invented because around 2000 large monolithic applications were brought down to their knees because of their internal coupling. Even though a lot of code was written as POJOs, the

by Peter Kriens ( at September 25, 2014 08:05 AM