You only need to set up an Integrated Development Environment (IDE) if you are going to write custom code. If you intend to use LuciadFusion Studio as an end user, you don’t have to install and set up an IDE.

See the Core concepts section in the documentation for more information about the available products and their capabilities.

Before you can:

  • Run the LuciadFusion Platform with your modifications

  • Compile and run modified samples from your IDE

you need to set up the IDE development project in a specific way.

To edit and compile code, it is recommended to use an IDE such as IntelliJ IDEA. See How to configure IntelliJ IDEA to start developing with LuciadFusion for detailed instructions.

Setting up your IDE project

To test any of your LuciadFusion Platform modifications, you can run the LuciadFusion Platform main class, TLfnFusionPlatformApplication, yourself.

You can also edit the source code of the samples located in the samples/src directory. Next, you must compile and run the samples.

To set up your IDE for such activity, create a project for your IDE in the LuciadFusion installation directory. Make sure to complete these project setup steps:

Complete the classpath.

Add the following JARs and directories to the classpath:

  • All JAR files in the lib directory

  • All JAR files in the lib/platform directory

  • All JAR files in the samples/lib/thirdparty directory. This directory contains all the third-party libraries used in the samples. See the prerequisites page for a full list.

  • The development.jar file that you have installed in the licenses directory

  • The config directory, if available

  • The samples/resources directory, if available

Exclude JARs from the classpath.

Do not include any other JAR files in the classpath. More specifically, never include the following files:

  • Any JAR file in the samples/lib directory (with the exception of samples/lib/thirdparty)

  • Any JAR file in the build directory or any of its subdirectories

  • Any JAR file in the distrib directory or any of its subdirectories

Activate annotation processing.

The samples use annotations to look up data format services. Hence, the sample code must be compiled with annotation processing enabled. All major IDE implementations support annotation processing, but you may need to activate it in your compilation settings. If your IDE requires you to explicitly declare annotation processors, point it to lcd_annotations.jar. For more information about activating and troubleshooting annotation processing in an IDE, see the Fixing service registry errors article.

Running the LuciadFusion server

To run the LuciadFusion Platform application with custom code, define a run configuration:

Set the main class.

To run the LuciadFusion server, you must run the class com.luciad.fusion.platform.TLfnFusionPlatformApplication from lcd_fusionplatform.jar in the lib/platform directory.

Set the VM options.

Set at least the spring.profiles option from this list:

VM option Comments

-Dspring.profiles.active=fusion.single,fusion.development

Defines the Spring profile configuration files required for development. See Configuring LuciadFusion Platform and Studio for more information about these configuration files.

-Xmx4g

Defines the maximum amount of memory. This value targets 64-bit VMs. You can adapt the setting to your needs. See the Oracle documentation for more information on Java memory settings.

-Xss8m

Expands thread stack size to accommodate large stack calls in Spring security.

-XX:SoftRefLRUPolicyMSPerMB=0

Speeds up the rate of clearing of soft references from memory.

-Djava.awt.headless=true

Runs the JVM in headless mode.

-Djava.library.path=

Defines the location of native libraries. It must be set to an empty string to prevent that a platform-dependent default value is used. That default value may refer to incompatible versions of native libraries on your system, and cause conflicts during library loading.

-Dsun.java2d.d3d=false

Disables the use of Direct3D.

-Dsun.java2d.opengl=false

Disables the OpenGL-accelerated painting pipeline that comes with the JDK.

--add-opens java.base/java.lang=ALL-UNNAMED

Needed for the Ehcache third party library to function properly. If not set, Ehcache cannot accurately calculate the size of some objects, which can cause inefficient cache usage. Ehcache is used in the WCS, WMS and WMTS server components. (Java 11 or higher only)

Running the samples with an IDE

To run the samples in the samples/src directory from the IDE, define a sample run configuration:

Set the main class.

You can run all sample classes that have valid main methods. Most of these classes are called MainPanel.

Set the VM options.

Make sure to set the right VM options. See Running the samples with an IDE for more information.

Running your custom code

To learn how to run your custom LuciadFusion code in an IDE project, see Add customizations to your IDE project.