The official Peasys Java client library.
- Java 11.0.16 or later
Add this dependency to your project's build file:
implementation "com.dips:peasys-java:1.0.0"
Add this dependency to your project's POM:
<dependency>
<groupId>com.dips</groupId>
<artifactId>peasys-java</artifactId>
<version>1.0.0</version>
</dependency>
You'll need to manually install the following JARs:
- The Peasys JAR
- [Jackson.core] from <>.
- [Jackson.databind] from <>.
Please see the Java API docs for the most up-to-date documentation.
Peasys is a tool used along a license that should be found on the dips400 website. This license key is required for the use of the service Peasys.
Peasys authenticates API requests using your license key, which you can find in the dashboard.
PeaClient conn = new PeaClient("PARITION_NAME", "PARTITION_NAME", PORT, "USERNAME", "PASSWORD", "FUTUR_LICENSE_KEY", true);
System.out.println(conn.connectionStatus);
System.out.println(conn.connexionMessage);
For example, use the executeCreate
method of the PeaClient
class in order to create a new table in the database.
PeaCreateResponse createResponse = conn.executeCreate("CREATE TABLE schema_table/table_name (nom CHAR(10), age INT)");
System.out.println("Requete correctement exécutée : " + createResponse.hasSucceeded);
System.out.println("Message SQL de la requete : " + createResponse.returnedSQLMessage);
System.out.println("Status SQL de la requete : " + createResponse.returnedSQLState + "\n");
It is important to always disconnect from the server after you used the connexion.
conn.disconnect();
New features and bug fixes are released on the latest major version of the Peasys Java client library. If you are on an older major version, we recommend that you upgrade to the latest in order to use the new features and bug fixes including those for security vulnerabilities. Older major versions of the package will continue to be available for use, but will not be receiving any updates.
JDK 11 is required to build the Peasys Java library.
To run all checks (tests and code formatting):
./gradlew check
To run the tests:
./gradlew test