Skip to content

coralogix/sdk-java-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Coralogix Java SDK sample project

This is a sample project which demonstrates the example of usage of Coralogix Java SDK.

Prerequisites

  • JDK 8+
  • JRE 8+
  • Maven 3.x

Build

The main application code is presented in com.coralogix.sdk.ExampleApp class.

To build the project you need to execute the following command:

mvn package

After compilation you will have target/ folder which will contain the .jar file with the test application.

Run

To run the package you need to execute the following command:

export CORALOGIX_PRIVATE_KEY="YOUR_CORALOGIX_PRIVATE_KEY"

java -jar target/coralogix-sdk-example-1.0-SNAPSHOT.jar

Extend

To use Coralogix Java SDK in your application you should add the appropriate dependency to your pom.xml file:

<dependency>
    <groupId>com.coralogix.sdk</groupId>
    <artifactId>coralogix-sdk</artifactId>
    <version>2.0.x</version>
</dependency>

where 2.0.x should be replaced with the latest version from the Maven repository.