Overview of Schema Level Configuration Override

This section describes schema level configuration override feature.

The schema level configuration override feature provides a mechanism to override configuration properties for a REST enabled schema. This allows authorized database users to customize Oracle REST Data Services (ORDS) on the fly. For example, a database user can use this mechanism to enable or disable an optional feature. Only a predefined subset of database schema level configurations can be overridden, global configurations cannot be overridden.

Features of Schema Level Configuration Override

This section lists the features of schema level configuration override.

The features of schema level configuration override are as follows:

See Also:

Overridable Configuration Properties

This section lists the overidable configuration properties.

Table 1 Overridable Configuration

Key Description Scope Setting Override Value
restEnabledSql.active Specifies whether the REST-Enabled SQL service is active. REST- Enabled SQL is a prerequisite for SDW or Database Actions. SDW is disabled if the value is set to false. Schema
begin ords.set_property( p_key => 'restEnabledSql.active', p_value => 'false'); commit; end; /
feature.sdw Specifies whether the Database Actions feature is active. Schema
begin ords_admin.set_property(p_key => 'feature.sdw', p_value => 'false'); commit; end; /
debug.printDebugToScreen Specifies whether the error responses include stack trace. Schema
begin ords_admin.set_property(p_key => 'debug.printDebugToScreen', p_value => 'true'); commit; end; /
debug.printOWADebug

Specifies whether the error responses for PL/SQL gateway requests include stack trace.

Overrides debug.printDebugToScreen for PL/SQL gateway requests.

Database
begin ords_admin.set_property( p_key => 'debug.printOWADebug', p_value => 'true'); commit; end; /

Use Cases

This section shows some use cases for using the schema level configuration override feature.

Table 2 Use Cases of Schema Level Configuration Override feature

Scenario Solution
An Autonomous Database user wants to debug their ORDS REST Services. The database user sets the property to true for their schema as shown in the following code snippet:
 ords.set_property( p_key => 'debug.printDebugToScreen', p_value => 'true' );
Administrator wants a REST-Enabled schema but not have a REST-Enabled SQL. The administrator sets the property to true for the relevant schema as shown in the following code snippet:
ords_admin.set_property( p_schema => 'REST_PRODUCTION', p_key => 'restEnabledSql.active', p_value => 'true' );
Administrator wants to completely disable SDW for a database. The administrator sets the property for every schema as shown in the following code snippet:
ords_admin.set_property(p_schema => 's1', p_key =>  'feature.sdw', p_value => 'false');  ords_admin.set_property(p_schema => 's2', p_key =>  'feature.sdw', p_value => 'false');
REST-Enabled schema wants to clear a property value that was previously set. The database user runs the following command:
ords.unset_property(p_key => 'debug.printDebugToScreen');

Scope and Visibility Matrix

This section describes how to configure the visibility and the scope for the database and schema users.

Table 3 Scope and Visibility Matrix

User Type Database Schema
Public
  • Only administrator can set a value that applies to all the schemas
  • USER_ORDS_PROPERTIES view shows the value, if it is set
  • Unprotected REST endpoint shows the value if it is set
  • Currently used for login message and SDW header and footer
  • Administrator and non-administrator user can set a value per schema
  • There is no default value that automatically applies to a schema
  • USER_ORDS_PROPERTIES view shows the value if it is set
  • Unprotected REST endpoint shows the value if it is set
PROTECTED
  • Only the administrator can set a value that applies for all the schemas
  • USER_ORDS_PROPERTIES view shows the value if it is set
  • Unprotected REST endpoint does not show value if it is set
  • Administrator and non-administrator user can set a value per schema
  • There is no default value that automatically applies to a schema
  • USER_ORDS_PROPERTIES view shows the value if it is set
  • Unprotected REST endpoint does not show the value if it is set
PRIVATE
  • Only administrator can set the value that applies for all the schemas
  • USER_ORDS_PROPERTIES view does not show a value if it is set
  • Unprotected REST endpoint does not show a value if it is set
  • Only the administrator can set a value per schema
  • There is no default value that automatically applies to a schema
  • USER_ORDS_PROPERTIES view does not show the value if it is set
  • Unprotected REST endpoint does not show the value if it is set