platform/eel/docs/Opening_Projects_with_EelApi.md
This document explains how to open projects in different environments (WSL and Docker) using the Eel API.
The Eel API provides a unified way to interact with different execution environments, such as the local machine, Docker containers, and WSL distributions. One of the key features of EelApi is the ability to open projects located in these environments directly in IntelliJ IDEA, providing a seamless development experience.
Opening projects in Windows Subsystem for Linux (WSL) with EelApi is straightforward. You can simply open a WSL project as if it were a local project.
\\wsl$\<distribution_name>\path\to\project or \\wsl.localhost\<distribution_name>\path\to\projectWhile WSL project opening was available before EelApi, the new implementation provides several advantages:
Traditionally, the only way to open a project in a Docker container was to use Remote Development, which is resource-intensive and doesn't provide a local-like experience. With EelApi, you can now open Docker projects as if they were local projects.
To open Docker projects using EelApi, you need to enable certain VM options and registry keys:
-Djbr.java.io.use.nio=true to your IDE configurationopen.docker.projects.using.eel=trueuse.eel.file.watcher=trueAdditional registry keys that improve the experience:
git.use.eel.for.non.local.project=trueYou can open a dev container project using the "Open Project" action:
or you can open any folder in a Docker container as a project:
When the open.docker.projects.using.eel=true flag is enabled, IntelliJ IDEA stops using the client-backend approach for Docker projects. Instead, it opens the project as if it were local, using EelApi to handle all interactions with the Docker container.
This approach provides several benefits:
| Feature | Traditional Approach | EelApi Approach |
|---|---|---|
| Opening Method | Open as local project | Open as local project |
| Performance | Slower file system access | Up to 30% faster file system access |
| Stability | Occasional freezes | No freezes |
| Feature Support | Full IDE features | Full IDE features |
| Feature | Remote Development | EelApi Approach |
|---|---|---|
| Resource Usage | High (client-backend) | Low (direct access) |
| Setup Complexity | Complex | Simple |
| Performance | Slower due to client-backend communication | Faster direct access |
| Local Experience | Limited | Full local-like experience |
| Feature Support | Limited by client-backend | Full IDE features |
EelApi provides a seamless way to open and work with projects in different environments, particularly WSL and Docker. By enabling the appropriate options, you can enjoy a local-like development experience with projects located in these environments, with better performance and resource efficiency.