Configuring IDE from a clean Eclipse
We recommend using our OpenKM Portable Development IDE rather than configuring your own.
You can also use IntelliJ IDEA or other development Java tools like NetBeans.
Requirements
Software:
- Eclipse
- OpenJDK 1.8
Your eclipse must have support for:
- Maven
- Subversion (recommended)
Hardware:
Suggested minimum hardware configuration:
- 2 CPU's
- 4GB of ram
- 64 bits architecture (although you can get it running on 32 we do not suggest this architecture).
Download eclipse
We suggest downloading the latest stable version of Eclipse. Eclipse comes with several versions, you should download the "Eclipse IDE for Java EE Developers" for your computer architecture (32 or 64 bits).
More information at https://eclipse.org/downloads/.
Configure Java
You must have Java installed on your server, otherwise go to http://www.oracle.com/technetwork/java/index.html, click Java SE and download the latest OpenJDK 1.8 version accorder your OS and hardware architecture. Execute the Java installer and follow the installation wizard.
Go to Window / Preferences / Java / Installed JRE. You must have OpenJDK 1.8 defined here:
Configure tomcat server
Go to the "servers" tab. Click on right click mouse button and from contextual menu choose "Add / server". From the list choose "Tomcat 7 server":
Configure a new Run time server environment:
Choose the "Workbench default JRE" when your default JRE is "OpenJDK 1.8" or choose "OpenJDK 1.8" from JRE list of installed JREs.
Check the Use Tomcat installation box (takes control of tomcat installation).
Increment start and stop timeouts (for example to 180 and 120 seconds respectively).
Edit the launch configuration: Add memory parameters - we suggest 2GB - sigar library path and utf-8 file encoding in the VM arguments field:
-Xms128m -Xmx2048m -Djava.awt.headless=true -Dfile.encoding=utf-8 -Djava.library.path="/home/jllort/software/tomcat-7.0.27-openkm-6-community/lib/sigar"
Add your OpenKM project to the source tab:
Add CATALINA_PID and LD_LIBRARY_PATH to the environment variables:
CATALINA_PID=$CATALINA_HOME/catalina.pid
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$CATALINA_HOME/lib/sigar:/usr/local/apr/lib
or
CATALINA_PID=$CATALINA_HOME/catalina.pid
LD_LIBRARY_PATH=/home/jllort/software/tomcat-7.0.27-openkm-6-community/lib/sigar
Maven support for Eclipse
The latest Eclipse version comes with maven support plugins installed by default. For previous Eclipse versions follow these configuration steps:
- Go to Help > Eclipse Marketplace
- Install the plugin named M2Eclipse.
Older Eclipse versions come without the "Eclipse Marketplace" feature and the plugins must be installed manually with the Help > New software option. We encourage the use of a more recent version of the Eclipse software in this case.
Subversion support for Eclipse
- Go to Help > Eclipse Marketplace
- Install the plugin named Subversive.
To checkout a SVN project go to File > New > Others > Maven > Check out Maven Projects from SCM.
At the beginning the SCM URL list will be empty, you must click on the "m2e Marketplace" link on the bottom right and install the "m2e-subversive" connector.
Older Eclipse versions come without the "Eclipse Marketplace" feature and the plugins must be installed manually with the Help > New software option. We encourage the use of a more recent version of the Eclipse software in this case.