How to Compile Custom Operators with an Assembly JAR

How to Compile Custom Operators with an Assembly JAR

book

Article ID: KB0082620

calendar_today

Updated On:

Products Versions
Spotfire Data Science 6.x

Description

How to Compile Custom Operators with an Assembly JAR

Resolution

How to Compile Custom Operators with an Assembly JAR

If you are unable to access Maven Central at your company, Spotfire Data Science can provide a JAR that contains the necessary dependencies for you. Please follow the prerequisites in How To Compile and Run the Sample Operators and before running mvn package, make these changes to your pom.xml file. 

1. Open the pom.xml file of the project you want to compile. In this example, you should open PluginExampleProject/pom.xml.

2. Remove the <repositories> section. 

3. Remove every block that starts with <dependency> and ends with </dependency>

4. In the <dependencies> block, include this code:

<dependency>
<groupId>com.alpinenow</groupId>
<artifactId>alpinenow</artifactId>
<version>1.0</version>
<scope>system</scope>
<systemPath>path to the assembly JAR</systemPath>
</dependency>

Be sure that you include the path to the assembly JAR in the <systemPath> section.

5. Save your pom.xml file and quit.

6. Run mvn package from your project's root directory. In this case, it would be the PluginExampleProject folder.

Issue/Introduction

How to Compile Custom Operators with an Assembly JAR