Java
Applies to: Kyvos Enterprise Kyvos Cloud (SaaS on AWS) Kyvos AWS Marketplace
Kyvos Azure Marketplace  Kyvos GCP Marketplace Kyvos Single Node Installation (Kyvos SNI)
Java integration architectureÂ
The following figure illustrates Java integration architecture.Â
The architecture consists of the following components.Â
Host Application: The Java-enabled application into which Kyvos data is queried using Kyvos Java APIs.Â
Kyvos Client Components: Jar and configuration files to be included in the class path of the host application.Â
Kyvos Cluster: One or more computer on which Kyvos software is running. Generally, this cluster is deployed on Hadoop cluster computers. One of these computers deploys the Kyvos BI Server (called OLAP engine earlier), which acts as a communication point for the client APIs. You may need the IP address or name of that computer to configure the APIs.Â
APIs:Â The APIs provide Java Objects to prepare requests, and the Java method calls for querying data from semantic models and querying metadata from semantic models and other repository items. The Java methods are designed to use MDX when requesting semantic model data. Responses are given in the form of Java Objects.
Java APIsÂ
The Kyvos Java APIs provide the capability to query and extract data from Kyvos semantic models into an integrating host application. The APIs allow the applications to perform operations in Kyvos, such as: Â
Work with Dataset:Â You can register a data file present on HDFS and pass information necessary to parse and define columns. You can also create a register file from a particular table of database.Â
Work with dataset relationships:Â You can create a dataset relationship design (DRD) or draw relationship between defined datasets in DRD.Â
Work with semantic models:Â You can add a new semantic model object, process semantic model, modify the existing semantic models, and query from semantic model.Â
Prerequisite to run Java API
Java is required.
Connectivity from BI Server is required.
Java API connects to BI Server not the Web portal.
Add all JAR files present inside Jakarta Folder (/jakarta/webapps/kyvos/WEB-INF/lib) in the project classpath.
Add the servlet-api.jar file present inside Jakarta Lib (/jakarta/lib) in project classpath.
The Kyvos installation folder contains these files at <Kyvos_Web_App_path>\WEB-INF\lib location.Â
Steps for using Java APIsÂ
To use Java APIs for Kyvos:Â
Set up the Kyvos environment:
You can configure the Kyvos Java APIs in the kyvosclient.properties file available in the <Kyvos_Web_App>\client\config folder.Â
Place the configured kyvosclient.properties file at the classpath of the integrating host application.Â
The REPORT_ENGINE_IP property in the kyvosclient.properties file should point to the Kyvos engine server.Â
For this, set the values as :Set REPORT_ENGINE_IP = <Enter Kyvos Engine IP address>Â
Set REPORT_ENGINE_PORT = < Enter corresponding network Port>Â
Set ZOOKEEPER_HOSTS = < Enter corresponding Zookeeper Host>Â
Set CLUSTER_NAME = < Enter corresponding Cluster Name>
Initialize the Kyvos client:Â
Use Init to initialize the Kyvos client. The object of this class is initialized only once in the lifetime of application. It will read the properties for Engine server related attributes and initialize the properties contained in the configuration file.Â
void com.kyvos.client.init.ReportClient.init(String absoluteFileName, boolean isAutoStart) throws InterfaceInitException
Some objects are required for all use cases mentioned later in this document. Import UserInfo, an object required to authenticate the user in the Kyvos application:Â
import com.kyvos.client.common.UserInfo;
Create the object using the parameters requestorUserId and requestorUserPassword—the Kyvos System user identifier and password:Â
UserInfo userInfo = new UserInfo(requestorUserId, requestorUserPassword);Â
Use cases
Copyright Kyvos, Inc. All rights reserved.