You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

The Agent SDK for Java allows you to leverage the Perspectium Replication Framework to write your own Java applications to consume and produce messages with the Perspectium Integration Mesh. This provides you a way to integrate custom applications with Perspectium-supported applications.


Procedures 

To set up the Agent SDK, follow these steps:


Installation

Once you have obtained your Perspectium Agent SDK Account from Perspectium Support, you will need to add the Perspectium Maven Repository URL and login credentials to your Maven settings.xml file and your SDK project pom.xml file.

Setting up settings.xml

Since the Perspectium Nexus server requires authentication, you will also need to place your credentials in the Maven settings.xml in a servers element. There are two locations where a settings.xml file may live:

Maven install: $M2_HOME/conf/settings.xml 

User’s install: ${user.home}/.m2/settings.xml 

Here's a sample servers element using the default username and password for the deployment user:

<servers>
    <server>
      <id>perspectiumRepo</id>
      <username>your_username</username>
      <password>your_password</password>
    </server>
</servers>

Setting up pom.xml

Next, create a pom.xml file for your Java project with a dependency to the Perspectium Agent SDK library. The pom.xml will look similar to this:

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>
 
    <groupId>com.yourcompany</groupId>
    <artifactId>test-perspectium-sdk</artifactId>
    <version>1.0-SNAPSHOT</version>
 
    <dependencies>
        <dependency>
            <groupId>com.perspectium</groupId>
            <artifactId>perspectium-replicator-agent</artifactId>
            <version>5.0.0</version>
        </dependency>
    </dependencies>
 
    <repositories>
		<repository>
			<id>perspectium</id>
			<name>Perspectium</name>
			<url>https://nexus.perspectium.net/repository/public/</url>
		</repository>    
    </repositories>    
</project>