Opening multiple Eclipse instances on OS X (the easy way)

The one application instance only scheme of OS X can be an ache, especially when you do need to work on different workspaces simultaneously and the application at hand does not support it; such as Eclipse. The earliest mention of this problem with Eclipse I found in bug 139319; which was about starting multiple instances of Eclipse on OS X for exactly this purpose. Another related issue (bug 245339) was opened for the purpose of discussing a proper implementation of multi-workspace handling. The prior was closed as RESOLVED WONTFIX due to this.

Six years later Eclipse still cannot handle more than one workspace at a time – and OS X has become fairly popular. Thus several developers have had the same gripes and a few different solutions have come up:

These solutions are all a bit cumbersome and require labour; so I set about to write a small plugin that remedies this by adding a Open Workspace menu item just as in the original request. It will detect the application of the running Eclipse instance and start another in a fashion similar to the Switch Workspace command.

Now with all these Eclipse instances up and running I figured it would be a good idea if one would be able to tell them apart by taking a look at the icon; so the workspace name will show up in the icon badge if set (Preferences > General > Workspace).

That’s all there’s to it. You’ll find the source code at GitHub and the installer at the Eclipse Marketplace – or you can drag Drag to your running Eclipse workspace. into an running Eclipse instance.

36 Comments

  1. Have you considered contributing your code to Eclipse, maybe as a patch for bug 25339? I'd be surprised if it wasn't welcomed (assuming you're willing to commit to supporting the code going forward).

  2. Hi Eric. I did think about contributing to bug 139319. Of course, the proper way would be to fix bug 245339 by handling multiple workspaces within one Eclipse instance. In that respect this solution a bit of a kludge. It is not really a solution for the bug. What you do get is basically what Linux and Windows users have had all along; the ability to start multiple instances.

  3. Hello Torkild,
    Great Job !
    It's seems that is easy to implements this functionality for the Win32 platform. You must just change how You get the application file (laucher). For the Win32, the laucher is already an .exe file. So the code can be:

    if (Platform.getOS().equals(Platform.OS_WIN32)) {
    return new File(launcher);
    } else if (Platform.getOS().equals(Platform.OS_MACOSX)) {

    }

  4. Thanks for the tip Bibi! I did think about adding a similar feature for Windows, but I did not think it worth the effort. Windows (and Linux) users can already easily start multiple instances of Eclipse using the application icon.

    Thanks Marco! It could be added in the future, but some more refinement will be required.

  5. Nice… I’m glad someone has made other developers life easier! Thanks Torkild

  6. Trying to install and getting the following error in Luna:
    Cannot complete the install because some dependencies are not satisfiable
    no.resheim.eclipse.utils.launcher.feature.group [2.0.0.201411211032] cannot be installed in this environment because its filter is not applicable.

    1. I have more than a hunch that you are not running Eclipse on OS X. Could that be the case? Sadly there is no support for running this plug-in on other operating systems yet. If you are on OS X please file a bug on the GitHib issue tracker and I’ll take a closer look.

  7. Does this work on the latest Eclipse (Luna)? I just installed your plug-in from the marketplace and restarted Eclipse, but I don’t see an Open Workspace menu item… just the usual Switch Workspace. Thanks!

        1. Strange. Would you mind filing a bug at the GitHub site and add your .log file? It might reveal what is going on.

          1. Sure… but a question — where is the log file? I’m looking through the Eclipse dir right now and can’t find one to attach.

          2. In your workspace there is a “.metadata” folder and within that you’ll find a file named “.log”.

          3. Thanks, found the file. Created the issue but there doesn’t appear to be a way to attach it. Couldn’t paste it into the form because it’s too long. Dunno what to do with it.

  8. Thank you, I used it with Spring Tool Suite Version: 3.5.1.RELEASE and it worked like a charm.

  9. Thank you. With Eclipse Mars it’s easier to run multiple instances on OS/X than before, but this is cleaner and the label on the icon is a great improvement!

    1. Hi. The problem was caused by the new Let’s Encrypt certificate I had installed. Looks OK now.

  10. Thanks for the plugin! Very useful!
    Any idea why the workspace badge does not stick? It just disappears just seconds after I open a new workspace…

    1. Looks good at my end. Maybe you’re having some intermittent connection issues? What version of Eclipse are you using?

  11. I am unable to install. I get the following error:

    Unable to read repository at https://resheim.net/p2/eclipse-launcher/content.xml.
    sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

    Looks like an SSL cert issue. Is this on your end or mine?

    1. I did do an Apache upgrade yesterday and it appears the wrong certificate got picked up. Please try again.

  12. I’m can’t install this plugin any more — Eclipse complains about the SSL certificate?

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.