News

Mainsoft Overhauls .NET-to-Java Porting Tool

Mainsoft Corp.'s tool for porting .NET Web apps to Java gets major new upgrade.

Mainsoft Corp. recently released an upgrade of its tool for porting .NET Web and server apps to Java-compatible platforms.

The newly renamed Mainsoft for Java EE 2.0 now supports more current versions of Microsoft development tools and platforms, including Visual Studio 2005, .NET 2.0 and ASP.NET 2.0. The previous version, called Visual MainWin for J2EE, was only available for Visual Studio 2003 and .NET 1.1.

"It was a big leap, a really big leap," Mainsoft President Yaacov Cohen says of the latest upgrade of the company's $12 million project. "ASP.NET 2.0 was a much bigger move than the move to 1.1."

Comfort Zones
The tool allows developers experienced in building on Microsoft's platform to stay in their Visual Studio and .NET comfort zones while producing Web and server apps that run on Linux and other Java-based platforms. Mainsoft's technology in effect transforms C# and Visual Basic into programming languages for the Java Virtual Machine through cross-compilation software, the company says.

A developer can even debug an app running on a Java Virtual Machine from Visual Studio, says Cohen, who likens the enabling operation to open heart surgery. "We get the code from the Java VM [virtual machine] in Java code, but we dynamically evaluate the expression back into C# or VB.NET because that's what the developers want to see. The point is you end up with a single source code that can be compiled once on .NET and once on Java."

That's no small thing for enterprises looking to consolidate platforms or deploy in-house .NET apps to Linux machines, says Clay Ryder, president of the California technology research and consulting firm The Sageza Group Inc.

"If you move everything to Linux and say to the developers, 'Now guys, you have to learn this,' their productivity is going to be a lot lower for a while. They're going to have to be re-trained, and they're not going to be as effective," Ryder says. "You can avoid that productivity hit or space it out over time with a translation tool like this."

Cooperative Effort
The Mainsoft runtime was built in collaboration with Project Mono, an open source software effort launched in 2001 to port .NET to Linux, Unix and other non-Microsoft platforms. Mainsoft assigned 30 of its software engineers to contribute to the project, Cohen says.

The Sageza Group's Ryder says well-written, high-level code often can execute correctly on the new platform straight from the Mainsoft translation tool, but older code, which typically is more tied to hardware, may require some manual tweaking. The .NET to Java port is typically straightforward, though, because both platforms are well insulated from hardware, he says.

"The .NET environment is different than NetBeans or other Java environments. However, that being said, since it's just software you can get the necessary class libraries to take a .NET app and run it through this tool and get the code you need to run it in a Java EE environment," Ryder says.

Ryder says Mainsoft has long been the dominant cross-platform portability tools vendor. "There are niche players at this," he adds, "but Mainsoft is certain one of the longer-established players in this space.
comments powered by Disqus

Featured

  • AI for GitHub Collaboration? Maybe Not So Much

    No doubt GitHub Copilot has been a boon for developers, but AI might not be the best tool for collaboration, according to developers weighing in on a recent social media post from the GitHub team.

  • Visual Studio 2022 Getting VS Code 'Command Palette' Equivalent

    As any Visual Studio Code user knows, the editor's command palette is a powerful tool for getting things done quickly, without having to navigate through menus and dialogs. Now, we learn how an equivalent is coming for Microsoft's flagship Visual Studio IDE, invoked by the same familiar Ctrl+Shift+P keyboard shortcut.

  • .NET 9 Preview 3: 'I've Been Waiting 9 Years for This API!'

    Microsoft's third preview of .NET 9 sees a lot of minor tweaks and fixes with no earth-shaking new functionality, but little things can be important to individual developers.

  • Data Anomaly Detection Using a Neural Autoencoder with C#

    Dr. James McCaffrey of Microsoft Research tackles the process of examining a set of source data to find data items that are different in some way from the majority of the source items.

  • What's New for Python, Java in Visual Studio Code

    Microsoft announced March 2024 updates to its Python and Java extensions for Visual Studio Code, the open source-based, cross-platform code editor that has repeatedly been named the No. 1 tool in major development surveys.

Subscribe on YouTube