-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Develop in IDEA
DBeaver is built on the Eclipse Platform, making the Eclipse IDE a logical choice for its development. However, many developers prefer the IntelliJ IDEA.
In this guide, we aim to demonstrate how to open the DBeaver project in IDEA, write and compile code, and, most importantly, run and debug the application, leveraging the excellent Java debugger available in IDEA.
Opening the project and understanding its module structure in IDEA is relatively straightforward. The complexity arises when attempting to run or debug the project, as this process requires an Eclipse runtime workspace, a feature exclusive to the Eclipse IDE that IntelliJ IDEA does not support.
- Create a folder where you will clone DBeaver repositories.
Note: all repositories must be located in the same folder. For example, name it
dbeaver-ce
. - Navigate to the created folder using the command:
cd dbeaver-ce
. - Clone the DBeaver repository with:
git clone https://github.com/dbeaver/dbeaver.git
. - Clone the IDEA generator with:
git clone https://github.com/dbeaver/idea-rcp-launch-config-generator.git
. - Clone the common components with:
git clone https://github.com/dbeaver/dbeaver-common.git
.Tip: Optionally, for documentation purposes, clone the WIKI repository with:
git clone https://github.com/dbeaver/dbeaver.wiki.git
(skip this step if you do not need the WIKI). - Clone the LibSQL JDBC driver with:
git clone https://github.com/dbeaver/dbeaver-jdbc-libsql.git
. - Clone the DBeaver osgi common repository with:
git clone https://github.com/dbeaver/dbeaver-osgi-common
. - (Optional) Clone the Cloudbeaver repository with
git clone https://github.com/dbeaver/cloudbeaver.git
- Open the
dbeaver/product/aggregate
folder in the console and runmvn clean package
. Besides product build this will trigger Maven tools which generate dynamic source code. - Execute the
generate_workspace
script in either the DBeaver or CloudBeaver repository, depending on the workspace you need. Once dependencies are downloaded and IDEA configurations are created, thedbeaver-workspace
folder will appear. The IDEA configuration, by default, will be generated indbeaver-workspace/dbeaver-ce
ordbeaver-workspace/cloudbeaver-ce
, which can be opened in IntelliJ IDEA. - Launch IntelliJ IDEA and open the project in the folder. It should contain all launch configurations.
- If you see a popup about importing Maven projects, press Skip. Otherwise, IDEA might add all existing modules as Maven projects, breaking the project build.
- For DBeaver, everything is set up and ready. Press CTRL+F9 (or
Rebuild project
) and wait. CloudBeaver requires the following additional steps to launch properly
- To launch CloudBeaver, we first need to execute the
build.sh
orbuild.bat
script incloudbeaver/deploy
. - After the script execution
cloudbeaver
folder will appear. Create theopt
folder in the root directory and copy it there.
The final project structure for the DBeaver workspace should look like this:
- Install the CheckStyle plugin.
- Use the configuration file
dbeaver-common/.github/dbeaver-checkstyle-config.xml
to set up the CheckStyle plugin. - Import the CheckStyle plugin configuration file into the Code style scheme.
If you encounter problems, do not hesitate to double-check your configuration and try again. If you're still experiencing issues, feel free to ask for help at tickets.
-
Views
-
Search
-
Data management
-
Usability enhancements
-
Security
-
Projects
- Sample Database
-
Database Connections
- Edit Connection
- Invalidate/Reconnect to Database
- Disconnect from Database
- Change current user password
- Network configurations
-
Manage truststore certificates
- Separate Connections
- Cloud configuration settings
- Local Client Configuration
- Connection Types
- Configure Connection Initialization Settings
-
Tableau integration
- Transactions
- Drivers
- Tasks
-
Cloud Explorer
-
Cloud Storage
- Classic
- Cloud
- Embedded
- File drivers
- Changing interface language
- DBeaver extensions - Office, Debugger, SVG
- Installing extensions - Themes, version control, etc
- User Interface Themes
- Command Line
- Reset UI settings
- Reset workspace
- Troubleshooting system issues
- Posting issues
- Log files
- JDBC trace
- Thread dump
- Managing connections
- Managing variables
- Managing drivers
- Managing preferences
- Managing restrictions
- Windows Silent Install
- Snap installation