Adventures in Xtext -- Modernizing an Eclipse Plugin for the Language Server Protocol (LSP)

The Language Server Protocol (LSP) creates the opportunity to reduce the complexity involved in supporting any programming language in any editor, IDE, or client endpoint. Eclipse Che leverages the LSP to provide an extensible platform to develop multi-language Cloud & Desktop IDEs with state-of-the-art web technologies.

The following is the first in a series where we take a deep dive into Xtext, Eclipse, and the LSP, by getting Natural, an Eclipse plugin for Cucumber and JBehave, up and running in the cloud with Eclipse Che.

Setting the Stage

Our story begins with Natural, the only Cucumber/JBehave editor that can link to and validate matching step definitions in your project live as you type. Created by Roberto Lo Giacco et al., Natural goes above and beyond simple syntax highlighting and formatting to define a formal LL(*) grammar used to generate a Gherkin lexer-parser using ANTLR.

Having enjoyed the benefits of this plugin for some years now, and upon encountering a bug in Groovy support, we decided to pop on over to the GitHub repo to see if we could help. Sadly we find a project no longer being maintained and a litany of new issues going unresolved. While Eclipse APIs tend to be very stable over time, this plugin still targeted Java 1.4 and the original Xtext 1.x API. This meant no Groovy, no Kotlin, no Scala, and, most importantly, to us, no LSP support. Clearly, some work needs to be done here.

Project Inception

Rather than attempt a hostile coop, we reached out to Mr. Giacco to get his vision and direction for the project and see how we may help achieve those ends. His enthusiastic response was music to our ears. He didn't want to see all his hard work widdle away and die. It's just that OSS doesn't put (much) food on the table, and the community that benefited from his hard work was unwilling to contribute either time or money to see this one-of-a-kind plugin evolve with the times.

We are a brand new startup and don't have a lot of money to contribute, but we are certainly willing to contribute our time and effort! Before we can set about solving our own problems, though, we must first set out to accomplish all of the original goals set forth by Mr. Giacco and get a stable 1.0 MVP released to Eclipse Marketplace.

Coming Soon

The next post in this series will cover the Project Inception phase in detail as we go through the discovery process to map out the systems architecture and get a feel for the scope of work ahead of us.


---
Watheia Labs, LLC is a software development and IT consulting firm based in Eastern Washington. For more information, please visit https://www.watheia.com/ or send an email to support@watheia.com.

Comments