Aimstar

AIMSTAR Blog

Deploying Oracle Rest Data Services (ORDS) on WebLogic for APEX

Posted by Theodore Williams on Aug 25, 2017 8:00:00 PM

Deploying Oracle Rest Data Services (ORDS) on WebLogic

Deploying_ORDS_on_WebLogic_for_APEX.png

A web listener is needed in order to run Oracle APEX.  Oracle Rest Data Services (ORDS), formerly called the APEX listener, is a great option for the web listener.  This article details the configuration and deployment of ORDS on Oracle WebLogic Server.

 

This article assumes that WebLogic has been successfully installed.  See our previous posts for steps in configuring WebLogic.


Relevant Topics: Oracle DBA,  Oracle WebLogic, Managed Server, Oracle APEX, Oracle Rest Data Services, ORDS, Oracle Database Development

  1. Download and unzip Oracle ORDS. This will create a file named ords.war.

 

  1. Change to the directory where ORDS was unzipped and run the command:

 

java -jar ords.war

 

The following information will be entered.

 

  1. A location to store the ORDS configuration data
  2. The name of the database server
  3. The database listen port
  4. The database service name or SID
  5. The database password for ORDS_PUBLIC_USER. This user was created during the APEX installation on the database.  See our previous post on installing APEX.
  6. Enter “1” when the following displays: Since APEX will be used, “Enter 1 if you want to use PL/SQL Gateway or 2 to skip this step.”
  7. The password for APEX_PUBLIC_USER. This user was created during the APEX installation on the database.
  8. Enter “1” to specify the passwords for APEX_LISTENER and APEX_REST_PUBLIC_USER. These users were also created during APEX installation on the database.
  9. Enter “2” to exit.

 

[oracle@Forge ords]$ pwd

/u01/app/ords

[oracle@Forge ords]$ java -jar ords.war

This Oracle REST Data Services instance has not yet been configured.

Please complete the following prompts

 

Enter the location to store configuration data:/apps/ords_config

.

.

.

Enter 1 if you wish to start in standalone mode or 2 to exit [1]:2

[oracle@Forge ords]$


  1. Copy the images from the APEX installation to a location on the server hosting WebLogic.

For example,

 

/apps/apex_images/images

 

 

  1. Run the following command from the same directory as the previous command. This will create a file named i.war which will be deployed on WebLogic.  The i.war file will contain references to the location of the APEX images from above. 

 

java -jar ords.war static <location of the APEX images>

 

 

[oracle@Forge ords]$ java -jar ords.war static /apps/apex_images/images

WAR Generation complete

 WAR location     : /u01/app/ords/i.war

 Context path     : /i

 Static resources : /apps/apex_images/images

Ensure the static resources are available at path: /apps/apex_images/images

on the server where the WAR is deployed[oracle@Forge ords]$

 

  1. Log into the WebLogic Admin Console.

 WebLogic_Home.png

 

Enter a change session by selecting “Lock & Edit” from the left side.  Select Deployments from the left hand side.

 

  1. The Summary of Deployments screen displays.

 Summary_of_Deployments.png

 

Click Install.

 

  1. The Install Application Assistant screen displays.

 Install_Application_Assistant.png

 

Enter the location of the ords.war file. 

 

Click Next.

 

  1. The Install Application Assistant – Choose targeting style screen displays.

 Install_Application_Assistant2.png

 

Select “Install this deployment as an application”.

 

Click Next.

 

  1. The Install Application Assistant – Select deployment targets screen displays.

Select_Deployment_Targets.png

 

Select the managed server on which ORDS will be deployed (non-Admin Server).

Click Next.

 

  1. The Install Application Assistant – Optional settings screen displays.

Select the following:

Optional_Settings.png

 

Name: ords

Security:  Custom Roles: Use roles that are defined in the Administration Console; use policies that are defined in the deployment descriptor.

Source Accessibility: Use the defaults defined by the deployment's targets

Plan Source Accessibility: Use the same accessibility as the application

Click Next.

  

  1. The Install Application Assistant – Review your choices screen displays.

 Review_Choices.png

 

Additional Configurations: Yes, take me to the deployment's configuration screen.

 

Click Finish.

 

  1. The Settings for ORDS screen displays.

 Settings_for_ORDS.png

 

Click Save.

 

  1. The screen indicates that the settings have been saved.

 Settings_for_ORDS_saved.png

  1. Deploy i.war using the same steps used to deploy ords.war.

 

  1. First go back to the Summary of Deployments screen by clicking Deployments.

 Summary_of_Deployments2.png

 

 

Click Install.

 

  1. The Install Application Assistant screen displays.

 Install_Application_Assistant_i.png

 

Enter the location of the i.war file – or select i.war. 

 

Click Next.

 

  1. The Install Application Assistant – Choose targeting style screen displays.

 Install_Application_Assistant_Choose_Targeting_i.png

 

Select “Install this deployment as an application”.

 

Click Next.

 

  1. The Install Application Assistant – Select deployment targets screen displays.

Select_Deployment_Targets_i.png

Select the managed server on which ORDS including i.war will be deployed (non-Admin Server).

Click Next.

 

  1. The Install Application Assistant – Optional settings screen displays.

Optional_Settings_i.png

Select the following:

Name: i

Security:  Custom Roles: Use roles that are defined in the Administration Console; use policies that are defined in the deployment descriptor.

Source Accessibility: Use the defaults defined by the deployment's targets

Plan Source Accessibility: Use the same accessibility as the application

Click Next.

 

  1. The Install Application Assistant – Review your choices screen displays.

 Review_Choices_i.png

 

Additional Configurations: Yes, take me to the deployment's configuration screen.

 

Click Finish.

 

  1. The Settings for i screen displays.

 Settings_for_I.png

 

Click Save

 

  1. The screen indicates that the settings have been saved.

 Settings_for_I_saved.png

 

Click Activate Changes. 

 

  1. The screen indicates that the changes have been activated.

 Changes_Activated.png

 

  1. In order for the installation to operate properly, the WebLogic default behavior of intercepting all HTTP Basic Authentication challenges must be changed. Go to the server and edit the config.xml file.  This file can usually be found in:

 

$MW_HOME/user_projects/domains/<domain_name>/config/config.xml

 

Find the <security-configuration> element and add the following to it:

 

<enforce-valid-basic-auth-credentials>false</enforce-valid-basic-auth-credentials>

 

For example:

 

<security-configuration>

.

.

.

 

<enforce-valid-basic-auth-credentials>false</enforce-valid-basic-auth-credentials>

</security-configuration>

.

.

.

  1. Now, start the ORDS and I applications that were deployed.

Select Deployments and then select the Control tab.

 start_servicing_requests.png

 

Select the check box next to i and ords.  Select Start and Servicing all requests.

 

 

  1. The Start Application Assistant – Start Deployments screen displays.

 Start_Deployments.png

 

Click Yes.

 

  1. Both ords.war and i.war are now deployed with a State of “Active”.

 Applications_Deployed.png

 

 

  1. ORDS is now configured to work with APEX. Access APEX with the port to the managed server on which ords.war and i.war were installed and use ords as the context path.

 

For example:

 

https://anewserver.com:7006/ords/

  APEX_is_ready_to_use.png

 

 

WebLogic-APEX-Oracle-Checklist

 

Topics: Oracle DBA, Oracle APEX, Oracle database development, Oracle Database Administration, Oracle Rest Data Services, WebLogic, WebLogic Managed Server, ORDS

Oracle APEX Configuration White Paper

Get detailed information on integrating WebLogic, APEX, and Oracle Rest Data Services

Oracle APEX allows rapid development of database applications utilizing the Oracle database.  Oracle WebLogic may be used as the web server for Oracle APEX applications by utilizing Oracle REST Data Services (ORDS), formerly named the APEX Listener.  This white paper details the steps needed to set up an Oracle APEX environment using Oracle Rest Data Services (ORDS) on Oracle WebLogic.

Please click the button below to get detailed information on:

  • Installing APEX
  • Configuring WebLogic
  • Securing WebLogic
  • Installing ORDS
  • Configuring APEX for LDAP Authentication

 ORDS-APEX-WebLogic-WhitePaper

 

Subscribe to Email Updates

Recent Posts