News

Red Hat Java Tool for VS Code Released in Version 1.0

Five years in the making, a Visual Studio Code extension providing Java language support from Red Hat has shipped in version 1.0.

The Language Support for Java by Red Hat extension, like many in the VS Code marketplace, leverages an open source language server (Eclipse JDT Language Server) to provide language-specific features and functionality when working on Java files.

It has already been installed some 12.4 million times and is among the top 10 most popular VS Code marketplace offerings, which speaks to the community gravitas of the extension, which was announced back in September 2016, sporting this "modest" feature list:

  • Maven based project support
  • As you type compilation error reporting
  • Code completion
  • Javadoc hovers
  • Code outline
  • Code navigation
  • Code lens for references
  • Highlights
  • Code formatting

Over the years that feature list has steadily grown, with one of the new features in the v1.0 release being type hierarchy, described as "one of the top asks in the Java community." It allows developers to view type hierarchy in class, supertype, or subtype view.

Type Hierarchy in Animated Action
[Click on image for larger, animated GIF view.] Type Hierarchy in Animated Action (source: Microsoft).

With the addition of type hierarchy and more, the tool's feature list now looks like this:

  • Supports code from Java 1.5 to Java 17
  • Maven pom.xml project support
  • Basic Gradle Java project support (Android not supported)
  • Standalone Java files support
  • As-you-type reporting of parsing and compilation errors
  • Code completion
  • Code/Source actions / Refactoring
  • Javadoc hovers
  • Organize imports
    • triggered manually or on save
    • when pasting code into a java file with Ctrl+Shift+v (Cmd+Shift+v on Mac).
  • Type search
  • Code outline
  • Code folding
  • Code navigation
  • Code lens (references/implementations)
  • Highlights
  • Code formatting (on-type/selection/file)
  • Code snippets
  • Annotation processing support (automatic for Maven projects)
  • Semantic selection
  • Diagnostic tags
  • Call Hierarchy
  • Type Hierarchy

The tool comes bundled with others for Java, wrapped up in the Extension Pack for Java, still in preview with some 9.8 million installs.

"Over the past few years, Microsoft have been working together closely with Red Hat and adding new features to this language server," said Nick Zhu, senior program manager, in an Oct 20 announcement. "We have also been fine-tuning the performance of the language server and improving the stability by addressing issues and bugs.

"In addition to the main Java language support, we have built various Java extensions based on the language server and expanded the Java tooling features on Visual Studio Code including project management, build tools support for Maven/Gradle, and better testing support. Our goal behind is to provide the best Java development experience possible on Visual Studio Code."

His list of highlights for the release includes Java 17 support, performance improvements, basic Gradle Kotlin support and more.

For future development, some planned improvements include:

  • Make it easier to configure compiler error/warnings and code formatting options
  • More useful auto-completion suggestions (eg. Postfix completion)
  • Keep adopting convenient code actions (eg. new Java language features) and eventually reach feature parity with those provided by the Eclipse Java IDE
  • Further improving the overall performance of the language server and startup time
  • Embedding a Java runtime in the extension to improve the overall "Getting Started" experience

"We believe the 1.0 release of the language support for Java by Red Hat is an important step for the overall Java journey on Visual Studio Code, and we still have a long way to go," Zhu said. "Going forward, we plan to collaborate with Red Hat and invest in fundamental Java language support and we are committed to delivering an outstanding Java development experience."

About the Author

David Ramel is an editor and writer at Converge 360.

comments powered by Disqus

Featured

  • Compare New GitHub Copilot Free Plan for Visual Studio/VS Code to Paid Plans

    The free plan restricts the number of completions, chat requests and access to AI models, being suitable for occasional users and small projects.

  • Diving Deep into .NET MAUI

    Ever since someone figured out that fiddling bits results in source code, developers have sought one codebase for all types of apps on all platforms, with Microsoft's latest attempt to further that effort being .NET MAUI.

  • Copilot AI Boosts Abound in New VS Code v1.96

    Microsoft improved on its new "Copilot Edit" functionality in the latest release of Visual Studio Code, v1.96, its open-source based code editor that has become the most popular in the world according to many surveys.

  • AdaBoost Regression Using C#

    Dr. James McCaffrey from Microsoft Research presents a complete end-to-end demonstration of the AdaBoost.R2 algorithm for regression problems (where the goal is to predict a single numeric value). The implementation follows the original source research paper closely, so you can use it as a guide for customization for specific scenarios.

  • Versioning and Documenting ASP.NET Core Services

    Building an API with ASP.NET Core is only half the job. If your API is going to live more than one release cycle, you're going to need to version it. If you have other people building clients for it, you're going to need to document it.

Subscribe on YouTube