“100% Pure Java” solution
Embedded versus three-tier (APS) Java API deployment
Pure Java implementation is more efficient than JNI wrapper implementations around CAPI
Java API can be embedded in the client Java application of a two-tier solution
Java API can be embedded in the mid-tier server of a three-tier Java application
Embedded Java API is a set of JAR and property files
Through Embedded Java API, client applications communicate directly to Analytic Server
Easy to deploy and use
Easy to switch between embedded and three-tier modes
JAPI can be embedded in a front-end Java application of a two-tier architecture or in the middle tier of a multi-tier architecture. JAPI communicates directly and through TCP/IP to Analytic Servers. No mid-tier Provider Services server is necessary.
A sample batch file runsamplesEmbedded.cmd in EPM_ORACLE_HOME/common/EssbaseJavaAPI/11.1.2.0/samples/japi illustrates the use of a JAPI sample in Embedded mode.
Set ESS_ES_HOME to the root of Embedded JAPI installation and pass it to the JVM. For example:
java -DESS_ES_HOME=<root of Embedded JAPI installation>
Include the following JAR files, which are necessary for Embedded JAPI to work, in your CLASSPATH:
%MIDDLEWARE_HOME%\EPMSystem11R1\common\EssbaseJavaAPI\11.1.2.0\lib\ess_japi.jar
%MIDDLEWARE_HOME%\EPMSystem11R1\common\EssbaseJavaAPI\11.1.2.0\lib\ess_es_server.jar
%MIDDLEWARE_HOME%\EPMSystem11R1\common\essbase-studio-sdk\11.1.2.0\lib\cpld.jar
%MIDDLEWARE_HOME%oracle_common\modules\oracle.odl_11.1.1\ojdl.jar
To switch between Embedded JAPI and three-tier APS JAPI, the value of the String providerUrl in the signOn API must change. For Embedded JAPI, this is the String embedded. For three-tier Provider Services mode, it is the URL to the Provider Services instance.
A sample batch file runsamplesAPS.cmd in EPM_ORACLE_INSTANCE/common/EssbaseJavaAPI/11.1.2.0/samples/japi illustrates the use of a JAPI sample in three-tier Provider Services mode.
The API is the same for both Embedded JAPI as well as three-tier JAPI through Provider Services. The difference between the two is the parameter providerUrl.
signOn APIs in Iessbase interface — Embedded JAPI
public IEssDomain signOn(java.lang.String userName, java.lang.String password, boolean passwordIsToken, java.lang.String userNameAs, java.lang.String providerUrl throws EssException
Parameters:
userName—The user name. Can be null if password is cssToken and the passwordIsToken flag is true.
password—The user password. Cannot be null. If the passwordIsToken flag is true, this represents the cssToken string.
passwordIsToken—A boolean indicating whether the password is cssToken string.
userNameAs—The user name you want to impersonate. If null, no impersonation occurs.
providerUrl—The URL of the Provider Services servlet (For embedded mode pass “embedded”). In the embedded mode, the JAPI client and provider are in the same process space, and JAPI talks directly to the OLAP server. (No separate provider application needs to be running.)
Returns:
The signed on domain.
signOn APIs in Iessbase interface — Three tiered JAPI
public IEssOlapServer signOn(java.lang.String userName, java.lang.String password, boolean passwordIsToken, java.lang.String userNameAs, java.lang.String providerUrl, java.lang.String olapServerName) throws EssException
Parameters:
userName—The user name. Can be null if password is cssToken and the passwordIsToken flag is true.
password—The user password. Cannot be null. If the passwordIsToken flag is true, this represents the cssToken string.
passwordIsToken—A boolean indicating whether the password is cssToken string.
userNameAs—The user name you want to impersonate. If null, no impersonation occurs.
providerUrl—The URL of the Provider Services servlet (For embedded mode pass “embedded”). In the embedded mode, the JAPI client and provider are in the same process space, and JAPI talks to Analytic Server directly. (No separate provider application needs to be running.)
olapServerName—The host name where Essbase Server is running.
Returns:
The connected Essbase Server instance.