Setting Up ADF Data Sources

These topics explain how to configure your ADF Business Components for use with Oracle Business Intelligence.

See System Requirements and Certification for information about supported versions.

This section contains the following topics:

Creating a WebLogic Domain for ADF Business Components Used with Oracle Business Intelligence

To configure your ADF Business Components for use with Oracle Business Intelligence, you need to create a WebLogic Domain for your ADF Business Components that supports WebLogic Server, Oracle Application Core (Webapp), and Oracle JRF.

To create a WebLogic domain that supports the required components:

  1. Start the WebLogic Configuration Wizard. For example, on Windows, run MW_HOME\wlserver\common\bin\config.cmd.
  2. Select Create a new WebLogic domain and click Next.
  3. On the Select Domain Source screen, ensure that Basic WebLogic Server Domain, Oracle JRF, and Oracle Application Core (Webapp) are selected.
  4. Follow the remaining steps in the wizard, providing values appropriate for your environment.
  5. Click Create on the Configuration Summary screen to create the domain.

You can start and stop the Oracle WebLogic Server for this domain using command-line scripts in the domain directory. For example, on Windows, use the following:

  • BI_DOMAIN\bin\startWebLogic.cmd

  • BI_DOMAIN\bin\stopWebLogic.cmd

Deploying OBIEEBroker as a Shared Library in Oracle WebLogic Server

To configure your ADF Business Components for use with Business Intelligence, you need to install OBIEEBroker, making its physical file or directory known to Oracle WebLogic Server, and start it.

This process deploys the OBIEEBroker library as a shared library in Oracle WebLogic Server.

After the library has been installed and started, other deployed modules can reference the library. The OBIEEBroker shared library is installed as part of your Oracle Business Intelligence installation.

To deploy OBIEEBroker as a shared library in Oracle WebLogic Server:

  1. Ensure that Oracle WebLogic Server is running. If it is not running, start it. For example, on Windows, run BI_DOMAIN\bin\startWebLogic.cmd.
  2. Open the WebLogic Server Administration Console. For example, if your Oracle WebLogic Server is running locally on port 7001, go to http://localhost:7001/console.
  3. Log in to the WebLogic Server Administration Console with the credentials you created when you set up your WebLogic domain.
  4. In the Change Center, click Lock & Edit.
  5. On the Home Page, in the left pane, click Deployments.
  6. In the right pane, click Install.
  7. Using the Install Application Assistant, locate the OBIEEBroker EAR file. You can find this file at:
    ORACLE_HOME\bi\bifoundation\javahost\lib\obisintegration\adf\
    oracle.bi.integration.adf.ear
    
  8. Click Next.
  9. Select Install this deployment as a library and click Next.
  10. Select the servers and/or clusters to which you want to deploy the OBIEEBroker library. Make sure to select all servers and clusters to which modules or applications that reference the library are deployed.
  11. Click Next.
  12. You can optionally update settings about the deployment. Typically, the default values are adequate. Click Help for more information.
  13. Click Next, then click Finish to complete the installation.
  14. In the Change Center, click Activate Changes.

Deploying the Application EAR File to Oracle WebLogic Server from JDeveloper

To configure your ADF Business Components for use with Oracle Business Intelligence, you need to deploy the application EAR file to Oracle WebLogic Server from JDeveloper.

Before beginning this procedure, ensure that the following conditions are true:

  • You have an ADF Model project that contains ApplicationModules and view objects that will be exposed to Oracle Business Intelligence.

  • You have deployed OBIEEBroker as a shared library in Oracle WebLogic Server. See Deploying OBIEEBroker as a Shared Library in for more information.

  • Oracle WebLogic Server is running.

To deploy the application EAR file to Oracle WebLogic Server from JDeveloper:

  1. Start JDeveloper. For example, on Windows, run MW_HOME\jdeveloper\jdev\bin\jdev.exe.

  2. Select File, then select Open to open the project that contains your ADF Business Components in JDeveloper. If prompted, allow JDeveloper to migrate the project to the latest version.

  3. Create a new Application Module configuration, as follows:

    1. In the Model project, double-click the application module, then click the Configurations tab for that application module.

    2. Create a new configuration with the following characteristics:

      • Select JDBC DataSource for Connection Type.

      • Keep the default DataSource Name, for example, java:comp/env/jdbc/ApplicationDBDS.

      When you set up the JDBC data source in Oracle WebLogic Server in a later step, you use part of this DataSource Name as the JNDI name required by Oracle WebLogic Server. The JNDI name is the DataSource Name without the java:comp/env context prefix, for example, jdbc/ApplicationDBDS.

  4. Create a Business Component Archive deployment profile, as follows:

    1. In the Projects window, right-click the Model project and choose New.

    2. Select Deployment Profiles under General in the left pane, then choose Business Components Archive in the right pane and click OK.

    3. Provide a name for the deployment profile, for example, MyApplication_Archive, and click OK.

    4. On the Deployment page, click OK.

  5. In the Projects window, right-click the Model project and select Deployyour_deployment_profile_name > Deploy, or use the deployment wizard by selecting Deploy to File.

    After the project has been deployed, two jar files are created in the deploy directory for the Model project, for example, MyApplication_Archive_Common.jar and MyApplication_Archive_MiddleTier.jar.

  6. Create a new Web Project for the application, as follows:

    1. Right-click the global application and select New Project.

    2. Select Projects from the left pane, then select Web Project from the right pane.

    3. Provide a project name, for example, OBIEEBroker).

    4. Click Next until you reach the Web Project Profile page.

    5. Modify the Java EE Context Root to a name that better represents your application, for example, MyApplication.

      This value determines the URL that you use to connect to the application from Oracle Business Intelligence, for example, http://localhost:7001/MyApplication/obieebroker.

  7. Edit the Profile Dependencies of the WAR deployment, as follows:

    1. Right-click the Web Project you just created, for example, OBIEEBroker, and select Project Properties.

    2. From the left pane, select Deployment. Then, open the WAR File deployment profile on the right pane.

    3. Select Profile Dependencies from the left pane. Then, on the right pane, select the Common and MiddleTier deployment profiles of your Model project.

      Following this step ensures that the Business Component Archives for the Model project are included in the WAR file.

  8. Expand the Web Project and open web.xml. Then, go to the source view of the file.

  9. In the web.xml source, replace the content within the <web-app> element with the following:

    <context-param>
      <description>This holds the Principals (CSV) that a valid end user should 
    have (at least one) in order to query the ADF layer from BI.</description>
      <param-name>oracle.bi.integration.approle.whitelist</param-name>
      <param-value>Application_Roles_List</param-value>
    </context-param>
    
    <filter>
      <filter-name>ServletADFFilter</filter-name>
      <filter-class>oracle.adf.share.http.ServletADFFilter</filter-class>
    </filter>
    
    <filter-mapping>
      <filter-name>ServletADFFilter</filter-name>
      <servlet-name>OBIEEBroker</servlet-name>
      <dispatcher>FORWARD</dispatcher>
      <dispatcher>REQUEST</dispatcher>
    </filter-mapping>
     
    <servlet>
      <servlet-name>OBIEEBroker</servlet-name>
      <servlet-class>oracle.bi.integration.adf.v11g.obieebroker.OBIEEBroker
      </servlet-class>
    </servlet>
     
    <servlet-mapping>
      <servlet-name>OBIEEBroker</servlet-name>
      <url-pattern>/obieebroker</url-pattern>
    </servlet-mapping>
    

    Following this step ensures that the OBIEEBroker servlet will be used to access your application from Oracle Business Intelligence

    For application_roles_list, provide a list of application roles in CSV form. For example:

    <param-value>FBI_TRANSACTION_ANALYSIS_GENERIC_DUTY, OBIA_ANALYSIS_GENERIC_DUTY, 
    OBIA_EXTRACT_TRANSFORM_LOAD_DUTY, FUSION_APPS_BI_APPID</param-value>
    

    If you provide a list of application roles, a user's application role is checked before access is allowed to the application. Note that this run-time check requires the following grant to be present in the domain_name/config/fmwconfig/system-jazn-data.xml file for the WebLogic domain:

    <grant>
      <grantee>
        <codesource>
          <url>file:${domain.home}/servers/${weblogic.Name}/tmp/
          _WL_user/oracle.bi.integration.adf/-</url>
        </codesource>
      </grantee>
      <permissions>
        <permission>
          <class>oracle.security.jps.JpsPermission</class>
          <name>IdentityAssertion</name>
          <actions>execute</actions>
        </permission>
        <permission>
          <class>oracle.security.jps.JpsPermission</class>
          <name>AppSecurityContext.setApplicationID.obi</name>
        </permission>
      </permissions>
    </grant>
    

    If you do not want application roles to be checked by the OBIEEBroker servlet, use DISABLE_WHITELIST_ROLE_CHECK as the value for the <context-param> in web.xml. For example:

    <param-value>DISABLE_BI_WHITELIST_ROLE_CHECK</param-value>
    
  10. Create an EAR deployment profile for the application, as follows:

    1. Right-click the global application and select Application Properties.

    2. From the left pane, select Deployment, then click New on the right pane to create a new deployment profile.

    3. For Archive Type, select EAR File. Then, provide a name for the deployment profile (for example, MyApplication).

      The deployment profile name is used as the name displayed in the list of deployments in Oracle WebLogic Server.

    4. From the left pane, select Application Assembly. Then, on the right pane, select the webapp deployment profile of your Web Project.

      Following this step ensures that the WAR file from your Web Project is included in the EAR file.

  11. Under Application Resources, select Descriptors > META-INF > weblogic-application.xml.

  12. On the left, select the Libraries tab.

  13. Create two new Shared Library References, as follows:

    • Create the first Shared Library Reference with the following characteristics:

      • Library Name: oracle.bi.integration.adf

      • Implementation Version: 11.1.1.2.0

    • Create the second Shared Library Reference with the following characteristics:

      • Library Name: oracle.applcore.model

      • Implementation Version: 11.1.1.0.0

    These two Shared Library References create the following entries in the weblogic-application.xml file for the application:

    <library-ref>
      <library-name>oracle.bi.integration.adf</library-name>
      <implementation-version>11.1.1.2.0</implementation-version>
    </library-ref>
    <library-ref>
      <library-name>oracle.applcore.model</library-name>
      <implementation-version>11.1.1.0.0</implementation-version>
    </library-ref>
    
  14. Deploy the EAR file to Oracle WebLogic Server by right-clicking the global application, then selecting Deploy > EAR_deployment_profile_name. From the dialog that appears, select Deploy to Application Server and then follow the instructions in the wizard.

  15. To verify that the application has been deployed, log in to the WebLogic Server Administration Console and click Deployments under Your Deployed Resources. Verify that your application appears in the list, for example, obieebroker_app_name.

Setting Up a JDBC Data Source in the WebLogic Server

You must configure the ADF Business Components that you plan to use with Oracle Business Intelligence.

To configure your ADF Business Components for use with Oracle Business Intelligence, you must set up a JDBC data source in Oracle WebLogic Server for your application.

To set up a JDBC data source in Oracle WebLogic Server:

  1. Ensure that Oracle WebLogic Server is running. If it is not running, start it. For example, on Windows, run BI_DOMAIN\bin\startWebLogic.cmd.
  2. Open the WebLogic Server Administration Console. For example, if your Oracle WebLogic Server is running locally on port 7001, go to http://localhost:7001/console.
  3. Log in to the WebLogic Server Administration Console with the credentials you created when you set up your WebLogic domain.
  4. On the Home Page, select JDBC, then select Data Sources.
  5. Click New.
  6. Provide information for your data source. For Name and JNDI Name, provide the DataSource Name you specified in the Application Module configuration for the application, without the java:comp/env context prefi, for example, jdbc/ApplicationDBDS. In addition, make sure to select the target on which you want to deploy the data source before exiting the wizard.
  7. Click Finish when you are done providing JDBC data source settings.

Setting the Logging Level for the Deployed Application in Oracle WebLogic Server

The server_name-diagnostic.log file for the server where your application is deployed contains information about your deployed application.

You can find this file in the server-specific directory within your domain. For example, on Windows, the log file for the AdminServer is located in:

BI_DOMAIN\servers\AdminServer\logs

To set the logging level for your deployed application:

  1. Open the Oracle WebLogic Server file logging.xml for editing. You can find this file in:

    BI_DOMAIN\servers\server_name

  2. Within the <loggers> element, add the following child elements:
    <logger name="oracle.bi.integration.adf" level="LOG_LEVEL"/>
    <logger name="oracle.bi.integration.adf.v11g.obieebroker" level="LOG_LEVEL"/>
    

    Log levels include SEVERE, WARNING, INFO, CONFIG, FINE, FINER, and FINEST. Refer to the Oracle WebLogic Server documentation for information about logger levels.

  3. Save and close the file.
  4. Restart Oracle WebLogic Server.