Archive for the ‘Eclipse’ Category

Eclipse IDE improvements: Photon is followed by 2018-09

September 23, 2018

With the first quarterly simultaneous release the naming scheme was changed: Photon, which was released in June, is followed by 2018-09 in September now. Many thanks to all the heroes who made the Eclipse IDE a bit better again!

I have made two short videos each for Photon three months ago and now for 2018-09, showing Eclipse IDE improvements in action: one about general and Git improvements and the other exclusively for Java developers. Below the two videos, you will find a list of the improvements with time stamps and links to details. If you dislike something, let me know what you want me to change next time (for example, if you prefer one longer video like before instead of several short videos like the current ones).

2018-09 general and Git improvements

Eclipse 2018-09 IDE Improvements: General and Git

2018-09 Java improvements

Eclipse 2018-09 IDE Improvements: Java

Photon general and Git improvements

Eclipse Photon IDE Improvements: General and Git

Photon Java and Maven improvements

Eclipse Photon IDE Improvements: Java and Maven

Several Eclipse 2018-09 IDE packages are available for download. Since Photon there has existed an Latest Eclipse Release update site in Window > Preferences: Install/Update > Available Software Sites. If you enable it, you can upgrade to 2018-09 via Help > Check for Updates. If automatic updates (Window > Preferences: Install/Update > Automatic Updates) have not been disabled, a dialog will ask you on December 19 if you want to upgrade to 2018-12.

Eclipse Oxygen.3a IDE Improvements: Java 10

April 12, 2018

Three weeks after the Oxygen.3 and the Java 10 release, Oxygen.3a now adds official support for Java 10 which was previously offered only as a pre-release via the Eclipse Marketplace. Because Oxygen.3a also contains some bug fixes, an upgrade is also recommended for Java developers who do not (yet) want to use Java 10.

The main innovation and the only language change of Java 10 is the so-called Local-Variable Type Inference: within code blocks, in variable declaration, you can use var instead of the type. The specific type is determined implicitly from the assigned value. With var ArrayList<String> list = new ArrayList<>(); can be shortened to var list = new ArrayList<String>();. This is often handy (e. g. in try-with-resources statements like try (var reader = new BufferedReader(new FileReader(path))) { /*...*/ }), but in some cases it can also lead to less readable code (in my opinion e. g. in enhanced for-loops like for (var item : x.getItems()) { /*...*/ }).

var is not a keyword, just a reserved type name. This means that var can still be used as a variable name but not as a type name: int int = 1; and var int = 1; are invalid, but int var = 1; and var var = 1; are both valid Java code. Hopefully I will never have to explain to anyone why a module can be named “module” and a var can be named “var”, but an int cannot be named “int” and a class cannot be named “class” and why “module” is a valid class name whereas “var” is not. And because var is just a reserved type name, final var invar = 1; may look weird but is valid.

Nonetheless, the Eclipse developers did a great job enhancing the Eclipse Java IDE to support var. The inferred type will be shown on mouse over and in the Javadoc view, the content assist is aware of the inferred type and offers the corresponding proposals and in Mark Occurences var is handled as a substitute for the inferred type:

Furthermore, the incremental Eclipse Java compiler had to be adapted for Java 10. Unlike Oracle’s Java compiler javac the Eclipse compiler, however, does not stumble over var s=List.of("a",1).

For Java and other developers, several Eclipse Oxygen.3a IDE packages are available for download. Older versions of Oxygen will prompt you to upgrade to Oxygen.3a unless the built-in automatic update is disabled. Oxygen.3a is the last update for Eclipse Oxygen. Numerous major changes are currently being finalized for the next major release, Eclipse Photon, on June 27. If you want you can already test a pre-release of Eclipse Photon.

Happy coding!

Eclipse Oxygen.3 IDE Improvements: Java, Gradle and PHP

March 21, 2018

Eclipse Oxygen.3 is the last quarterly update of Oxygen. Thanks to everyone who has contributed in any way! Even if the main focus is already on Photon, which will be released on June 27, it is worth updating your Eclipse IDE (unless you want to test a pre-version of Photon instead).

As usual, I have made a short video that shows the IDE improvements that I find most noteworthy in action:

Java:

Gradle (see also Buildship 2.2):

PHP (see also PDT 5.3):

Eclipse Oxygen IDE Improvements: General, Java and Git Eclipse Oxygen.1a IDE Improvements: Java 9, JUnit 5, General, Gradle and PHP Eclipse Oxygen.2 IDE Improvements: Java IDE, Git, C/C++

Together with the previous Oxygen videos, you can view 72 improvements in action, in total about half an hour. Here are the direct chapter links (number of improvements in brackets):

Thank you for watching and happy coding!

Hello OpenJ9 on Windows, I didn’t expect you so soon!

March 9, 2018

Faster startup time, lower memory footprint and higher application throughput only by replacing the Java virtual machine (VM)? That sounds too good to be true. So far there has been no real alternative to Oracle’s Java HotSpot VM on Windows. With Eclipse OpenJ9, which emerged from open-sourcing IBM’s J9 VM, there is now the alternative that promises exactly this.

At the end of January the first OpenJDK 9 with Eclipse OpenJ9 nightly builds for Windows were published, but they were not very stable at that time. This week I tested the nightly builds again to run the Eclipse IDE and I was pleasantly surprised: OpenJ9 ran without crashing. Here are my results: the start time of the Eclipse Oxygen.2 Java IDE improves with OpenJ9 from 20 to 17 seconds, with some tuning (see below) even to 12 seconds compared to the Java 9 JDK with Oracle’s HotSpot VM on my more than six-year-old laptop. Also the Windows Task Manager shows less memory used by the Eclipse IDE and tasks like compiling a large project are a bit faster with OpenJ9.

To start the Eclipse IDE with OpenJ9, in eclipse.ini add the following two lines above -vmargs:

-vm
C:\path\to\jdk-9+181\bin\javaw.exe

Embedding the JDK into an Eclipse installation directory as jre subdirectory does not yet work, but as long as you do not start the Eclipse IDE from the command line from another directory you can use -vm with jre\bin\javaw.exe. To further improve the startup time, add the following two lines below -vmargs:

-Xtune:virtualized
-Xshareclasses:cacheDir=C:\path\to\shareclasses

The cloning of a GitHub repository fails due to missing certificate authority (CA) certificates. You can fix this OpenJDK 9 issue by replacing the lib\security directory (which contains the cacerts file) with the same directory of an OpenJDK 10 early access build.

In the Eclipse IDE that is running on OpenJDK the standard basic text font defaults (for reasons I don’t know) to Courier New 10 instead of Consolas 10. You can change this in Window > Preferences: General > Appearance > Colors and Fonts by selecting Basic > Text Font and pressing Edit… (if you like, you can also use Source Code Pro 9 like the Clean Sheet theme does).

I have not noticed so far any further differences between the Eclipse IDE running on Oracle’s JDK 9 and the Eclipse IDE running on the current OpenJDK 9 with OpenJ9 nightly build. Debugging and hot code replace works as expected.

Many thanks to the OpenJ9 team! I look forward to the final release. It’s great to have two good open source Java virtual machines for Windows. Who knows, but with only one of the two, neither of the two might be open source today.

PS: If the Eclipse IDE still starts too slowly for you, have a look at a developer build of the upcoming Eclipse Photon IDE. 😉

Eclipse Oxygen.2 IDE Improvements: Java IDE, Git, C/C++

December 21, 2017

As usual, I have made a short video that shows some IDE improvements of the latest Eclipse release (thanks to all of you who have contributed) in action:

Eclipse Oxygen.2 IDE Improvements: Java IDE, Git, C/C++

Java IDE:

Git (see also EGit 4.9):

C/C++ (see also CDT 9.4):

In case you missed it:

Eclipse Oxygen IDE Improvements: General, Java and Git

Next releases (calendar / ICAL):

Eclipse Oxygen.1a IDE Improvements: Java 9, JUnit 5, General, Gradle and PHP

November 11, 2017

Oxygen.1a (4.7.1a) was released two weeks after Oxygen.1 (4.7.1) on October 11, 2017. Oxygen.1 includes bug fixes and minor improvements. Since Oxygen.1a, the Eclipse IDE runs out of the box with Java 9 and supports development for Java 9 as well as testing with JUnit 5. Many thanks to all of you who have contributed in any way.

As usual I made a short video that shows some improvements in action:

Eclipse Oxygen.1a IDE Improvements: Java 9, JUnit 5, General, Gradle and PHP

Java 9

(see also Eclipse Project 4.7.1a New and Noteworthy – Java 9 and Eclipse Wiki – Java 9 Examples)

JUnit 5

(see also Eclipse Project 4.7.1a New and Noteworthy – JUnit 5)

General

(see also in Eclipse 4.7.1/4.7.1a closed bugs)

Gradle

(see also Eclipse Buildship 2.1.0 New and Noteworthy)

PHP

(see also in PDT 5.1 closed bugs)

More details about Java 9, JUnit 5 and other Eclipse topics can be seen in the recently uploaded 177 EclipseCon Europe 2017 videos with a total duration of more than 3 days and 19 hours.

Next releases (calendar / ICAL):

Upgrade to Eclipse Oxygen.1a or download Eclipse Oxygen.1a and happy coding!

Eclipse Oxygen Webinars: 6 talks with a total of almost 5 hours

July 17, 2017

Like last year, also this year the Eclipse simultaneous release was accompanied by a series of talks in which developers present their new developments (thanks Kat Hirsch for hosting it). Here is my summary of these six so-called webinars about Eclipse Oxygen; the first three are for IDE users, the other three about Eclipse frameworks:

Lakshmi P Shanmugam:
What’s New in the Eclipse Platform? (57:07)

If you have already seen my 10-minute Oxygen video, you can skip the first half on Eclipse Platform and Java development tools (JDT) improvements. If you watch the talk from the beginning, you can skip the part from 23:11 and 33:18, where the screen sharing is interrupted and afterwards some improvements are shown again. In the second half, Trace Points, which are missing in my video, are explained. Also Plug-in Development Environment (PDE) and the API Tooling improvements are demonstrated. I recommend Java developers to watch at least this and the following video. In addition, you might also watch the three-month old video of the Devoxx talk Eclipse 4.7 Platform News by Lars Vogel (23:38), which gives a deeper insight into some of the Platform, JDT and PDE improvements.

Marc R. Hoffmann:
EclEmma – Code Coverage in Practice (48:57)

AsEclEmma became an Eclipse project, the Java IDE packages are shipped with built-in Java code coverage analysis now. This webinar gives a general introduction to EclEmma, but also shows how to use the Java Code Coverage feature to find unused code or JAR dependencies.
A nice trick is to find the code of a particular function of an application by differential code coverage: launch the application in coverage mode, reset already collected coverage data, execute the function and dump the coverage data. The code executed by the function is shown as covered. At the end of the webinar, some tips are given how common pitfalls can be avoided.

Kaloyan Raev:
PHP Development Tools (PDT) 5.0 (46:26)

This webinar is much more detailed and comprehensive than the Eclipse Newsletter article What’s new in Eclipse PHP Development Tools (PDT) 5.0. In contrast to the previous videos, the improvements are not shown in action, but inmany screenshots. PDT 5.0 supports PHP 7.1 and integrates the Composer (a PHP dependency manager: similar what npm is for node.js or Maven is for Java) as well as PHPUnit. New in PDT are also functions to organize use statements (similar to Organize Imports in JDT). It is nice to know that the activity and diversity with regard to the involved developers and companies is growing. Maybe in a future version code completion proposals will come from a PHP language server instead of as before from PDT. An experimental integration of a PHP language server implemented in PHP already exists. If you want to know more about general Eclipse integration of language servers, see the next webinar.

Sopot Cela and Mickael Istria:
Generic Editor and Language Server Protocol (LSP) (53:55)

At the beginning the new Generic Editor is shown. The Generic Editor is extended by the new LSP4E Eclipse project to support the Language Server Protocol (LSP). The term server is somewhat misleading as the most likely use case will be that the server will be installed and run locally or where the files are (see Mickael’s comment below). The explanation of LSP is followed by the demonstration of two experimental language server integrations, aCute for C# and BlueSky for HTML, CSS, JavaScript and TypeScript files. Although LSP is only about a year old, LSP support has already been announced for 27 languages. Up to now LSP is limited to editing files: no debugging support, no refactorings apart from renaming and no possibility to show a type hierarchy and syntax highlighting is done via TextMate grammars. Like EGit and JGit for Git, the LSP support is realized via the two new Eclipse projects LSP4E and LSP4J, so that not-Eclipse-based applications can use the LSP4J framework. In the next webinar one of such applications is shown.

Sven Efftinge and Miro Spönemann:
New in Xtext: Core Framework, LSP, Tracing Code Generators (51:00)

The webinar starts with the history of Xtext, a framework and tools to build and support domain-specific languages. Since Eclipse IDE lost market share, Xtext support has been extended to IntelliJ IDEA and will be extended to code editors and other IDEs via LSP. The Xtext language server is shown in action in the Eclipse IDE as well in Theia, a cloud and desktop IDE framework implemented in TypeScript. After the demos the new Xtext feature to generate trace code is explained.

Mélanie Bats and Stéphane Bégaudeau:
Eclipse Sirius 5.0, All about UX (32:40)

The last webinar is about Sirius. Sirius is for graphical editors what Xtext is for text editors. The new features are especially – as the title suggests – user experience improvements. They are explained by slides and shown in action. For instance, the decorator mechanism has been improved, e. g. the decorator icons on boxes and on images are placed in such a way that they do not accidentally overlap anymore. There is also an Eclipse Newsletter article about these Sirius user experience improvements, but it is certainly more interesting to see Sirius in action in the webinar.

These were the six Eclipse Oxygen webinars with a total duration of almost five hours, presented by ten people from all over the world. In case this is not enough, check out my Recommended Eclipse Videos playlist. If you have any recommendation for an Eclipse video, please drop a comment.

Eclipse Oxygen IDE Improvements: General, Java and Git

June 28, 2017

Eclipse Oxygen has just been released! Thanks to all committers and contributors. Good job!

Watch 26 general, Java and Git IDE improvements in action:

Eclipse Oxygen IDE Improvements: General, Java and Git

General IDE

Java

Git

Please note that my video does not cover C/C++, PHP, JavaScript and other improvements.

The six Oxygen webinars (each of them about 50 minutes long) provide or will provide a deeper insight. Java users are recommended to follow @EclipseJavaIDE on Twitter, which provides daily tips and tricks.

Download Eclipse Oxygen as long as it is still warm and happy coding!

Eclipse Neon.2: quick demo of three improvements

January 19, 2017

In December 2016 Neon.2 was released with only a few but nonetheless very helpful improvements. My Eclipse Neon.2: quick demo of 3 improvements shows three of these improvements:

  1. IDE – Compare Editor: Swap Left and Right View
  2. Java – Open Projects from File System: new Java and JDK detectors
  3. Arduino C++ Tools

Eclipse Neon.2: quick demo of 3 improvements

Opening a Java project that has not been created with Eclipse becomes a no-brainer with the new Java detector that is used by File > Open Projects from File System. Also the Arduino Downloads Manager of the Arduino C++ Tools shows how simple things can be: Just choose your Arduino board or compatible system and the libraries you want to use. Everything required, e. g. C++ compiler, will be downloaded and configured for you. Watch Doug‘s 11-minute video for more details.

There are also Eclipse IDE Git integration improvements, but EGit and JGit forgot to contribute their version 4.5 (I like auto-stage selected files on Commit…) and 4.6 to Neon.2. To get the latest Git improvements add the update site http://download.eclipse.org/egit/updates to Window > Preferences > Install/Update > Available Software Sites.

If you missed the last two releases, here are my quick demos of 10 Neon.1 and 22 Neon.0 improvements:

Eclipse Neon: 5:30-minute demo of 22 nice improvementsEclipse Neon: 5:30-minute demo of 22 nice improvements

The next and last Neon update Neon.3 will be released on March 23 before the next annual main release Oxygen on June 28.

Eclipse Neon.1: 4:00-minute demo of 10 improvements

September 28, 2016

Eclipse Neon.1 has arrived. Watch a 4:00-minute demo of 10 Eclipse Neon.1 improvements, including the IDE/platform, Java (WindowBuilder and Code Recommenders), Web/JavaScript and Docker Tooling:

Eclipse Neon.1: 4:00-minute demo of 10 improvements

And in case you missed it, the 5:30-minute video showing 22 Neon.0 improvements.