Go to main content
1/24
Contents
Title and Copyright Information
Preface
Audience
Documentation Accessibility
Related Documents
Conventions
Changes in This Release for Oracle Database XStream Guide
Changes in Oracle Database 12
c
Release 1 (12.1)
New Features
Part I XStream General Concepts and Use Cases
1
Introduction to XStream
1.1
About XStream
1.2
Purpose of XStream
1.3
XStream Use Cases
1.3.1
Replicating Data Changes with Non-Oracle Databases
1.3.2
Using Files to Store Data Changes
1.3.2.1
XStream Demo That Replicates Database Changes Using Files
1.3.3
Sharing Data Changes with a Client-Side Memory Cache
1.4
Prerequisites for XStream
1.5
XStream Security Models
1.6
Tasks and Tools for XStream
1.6.1
XStream Tasks
1.6.2
XStream Tools
2
General XStream Concepts
2.1
Logical Change Records (LCRs)
2.1.1
Row LCRs
2.1.1.1
Row LCR Subtypes
2.1.2
DDL LCRs
2.1.3
Extra Information in Row LCRs and DDL LCRs
2.1.4
Sequence LCRs
2.1.5
Position Order in an LCR Stream
2.2
Rules and Rule Sets
2.2.1
Rules and Rule Sets Defined
2.2.2
Rule Sets and XStream Components
2.2.3
System-Created Rules and XStream
2.2.3.1
XStream System-Created Rule Procedures
2.2.3.2
Global Rules
2.2.3.3
Schema Rules
2.2.3.4
Table Rules
2.2.3.5
Subset Rules
2.2.3.6
System-Created Rules and a Multitenant Environment
2.2.3.6.1
System-Created Rules in a CDB and XStream Out
2.2.3.6.2
System-Created Rules in a CDB and XStream In
2.3
Rule-Based Transformations
2.3.1
Declarative Rule-Based Transformations
2.3.2
Declarative Rule-Based Transformation Ordering
2.3.3
Evaluating Transformation Ordering
2.3.3.1
Row Migration Transformation Ordering
2.3.3.2
User-Specified Declarative Transformation Ordering
2.3.3.3
Considerations for Rule-Based Transformations
2.4
XStream and the Oracle Streams Performance Advisor
2.4.1
XStream Components
2.4.1.1
XStream Out Apply Subcomponents
2.4.1.2
XStream In Apply Subcomponents
2.4.2
Topology and Stream Paths
2.4.3
XStream and Component-Level Statistics
2.4.4
The UTL_SPADV Package
2.4.4.1
Collecting XStream Statistics Using the UTL_SPADV Package
2.4.4.2
Showing XStream Statistics on the Command Line
2.4.4.3
Interpreting SHOW_STATS Output
2.4.4.3.1
Sample Output When an Outbound Server Is the Last Component in a Path
2.4.4.3.2
Sample Output When an Inbound Server Is the Last Component in a Path
2.4.4.4
Showing XStream Statistics in an HTML Report
2.4.4.5
Interpreting the HTML Report From SHOW_STATS_HTML
2.5
XStream and SQL Generation
2.5.1
Interfaces for Performing SQL Generation
2.5.2
SQL Generation Formats
2.5.3
SQL Generation and Data Types
2.5.3.1
SQL Generation and Automatic Data Type Conversion
2.5.3.2
SQL Generation and LOB, LONG, LONG RAW, and XMLType Data Types
2.5.4
SQL Generation and Character Sets
2.5.5
Sample Generated SQL Statements
2.5.5.1
Sample Generated SQL Statements for the hr.employees Table
2.5.5.2
Sample Generated SQL Statements for a Table With LOB Columns
2.5.6
SQL Generation Demo
Part II XStream Out
3
XStream Out Concepts
3.1
Introduction to XStream Out
3.2
Capture Processes
3.2.1
Capture Process Overview
3.2.2
Data Types Captured by a Capture Process
3.2.2.1
ID Key LCRs
3.2.2.2
ID Key LCRs Demo
3.2.3
Types of DML Changes Captured by Capture Processes
3.2.4
Local Capture and Downstream Capture
3.2.4.1
Local Capture
3.2.4.1.1
The Source Database Performs All Change Capture Actions
3.2.4.1.2
Advantages of Local Capture
3.2.4.2
Downstream Capture
3.2.4.2.1
Real-Time Downstream Capture
3.2.4.2.2
Archived-Log Downstream Capture
3.2.4.2.3
The Downstream Database Performs Most Change Capture Actions
3.2.4.2.4
Advantages of Downstream Capture
3.2.4.2.5
Optional Database Link From the Downstream Database to the Source Database
3.2.4.2.6
Operational Requirements for Downstream Capture with XStream Out
3.2.5
Capture Processes and RESTRICTED SESSION
3.2.6
Capture Process Subcomponents
3.2.7
Capture Process States
3.2.8
Capture Process Parameters
3.2.9
Capture Process Checkpoints and XStream Out
3.2.9.1
Required Checkpoint SCN
3.2.9.2
Maximum Checkpoint SCN
3.2.9.3
Checkpoint Retention Time
3.2.10
SCN Values Related to a Capture Process
3.2.10.1
Captured SCN and Applied SCN
3.2.10.2
First SCN and Start SCN
3.2.10.2.1
First SCN
3.2.10.2.2
Start SCN
3.2.10.2.3
Start SCN Must Be Greater Than or Equal to First SCN
3.3
Outbound Servers
3.3.1
Overview of Outbound Servers
3.3.2
Data Types Supported by Outbound Servers
3.3.3
Apply User for an Outbound Server
3.3.4
Outbound Servers and RESTRICTED SESSION
3.3.5
Outbound Server Subcomponents
3.3.6
Considerations for Outbound Servers
3.3.7
Outbound Servers and Apply Parameters
3.4
Position of LCRs and XStream Out
3.4.1
Additional LCR Attributes Related to Position in XStream Out
3.4.2
The Processed Low Position and Restartability for XStream Out
3.4.3
Streaming Network Transmission
3.5
XStream Out and Distributed Transactions
3.6
XStream Out and Security
3.6.1
The XStream Out Client Application and Security
3.6.2
XStream Out Component-Level Security
3.6.3
Privileges Required by the Capture User for a Capture Process
3.6.4
Privileges Required by the Connect User for an Outbound Server
3.7
XStream Out and Other Oracle Database Components
3.7.1
XStream Out and Oracle Real Application Clusters
3.7.1.1
Capture Processes and Oracle Real Application Clusters
3.7.1.2
Queues and Oracle Real Application Clusters
3.7.1.3
Propagations and Oracle Real Application Clusters
3.7.1.4
Outbound Servers and Oracle Real Application Clusters
3.7.2
XStream Out and Transparent Data Encryption
3.7.2.1
Capture Processes and Transparent Data Encryption
3.7.2.2
Propagations and Transparent Data Encryption
3.7.2.3
Outbound Servers and Transparent Data Encryption
3.7.3
XStream Out and Flashback Data Archive
3.7.4
XStream Out and Recovery Manager
3.7.4.1
RMAN and Local Capture Processes
3.7.4.2
RMAN and Downstream Capture Processes
3.7.5
XStream and Distributed Transactions
3.7.6
XStream Out and a Multitenant Environment
4
Configuring XStream Out
4.1
Preparing for XStream Out
4.1.1
Decide How to Configure XStream Out
4.1.2
Prerequisites for Configuring XStream Out
4.1.2.1
Configure an XStream Administrator on All Databases
4.1.2.2
Granting Additional Privileges to the XStream Administrator
4.1.2.3
If Required, Configure Network Connectivity and Database Links
4.1.2.4
Ensure That Each Source Database Is in ARCHIVELOG Mode
4.1.2.5
Set the Relevant Initialization Parameters
4.1.2.6
Configure the Streams pool
4.1.2.7
If Required, Configure Supplemental Logging
4.1.2.7.1
Required Supplemental Logging in an XStream Environment
4.1.2.7.2
Specifying Table Supplemental Logging Using Unconditional Log Groups
4.1.2.7.3
Specifying Table Supplemental Logging Using Conditional Log Groups
4.1.2.7.4
Dropping a Supplemental Log Group
4.1.2.7.5
Specifying Database Supplemental Logging of Key Columns
4.1.2.7.6
Dropping Database Supplemental Logging of Key Columns
4.1.2.7.7
Procedures That Automatically Specify Supplemental Logging
4.1.2.8
If Required, Configure Log File Transfer to a Downstream Database
4.1.2.9
If Required, Add Standby Redo Logs for Real-Time Downstream Capture
4.2
Configuring XStream Out
4.2.1
Configuring an Outbound Server Using CREATE_OUTBOUND
4.2.2
Adding an Additional Outbound Server to a Capture Process Stream
4.2.3
Configuring an Outbound Server Using ADD_OUTBOUND
4.2.4
Configuring XStream Out in a CDB
4.2.4.1
Configuring XStream Out with Local Capture in a CDB
4.2.4.2
Configuring XStream Out with Downstream Capture in CDBs
5
Managing XStream Out
5.1
About Managing XStream Out
5.2
Managing an Outbound Server
5.2.1
Starting an Outbound Server
5.2.2
Stopping an Outbound Server
5.2.3
Setting an Apply Parameter for an Outbound Server
5.2.4
Changing the Connect User for an Outbound Server
5.3
Managing the Capture Process for an Outbound Server
5.3.1
Checking Whether the DBMS_XSTREAM_ADM Package Can Manage a Capture Process
5.3.2
Starting a Capture Process
5.3.3
Stopping a Capture Process
5.3.4
Setting a Capture Process Parameter
5.3.5
Changing the Capture User of an Outbound Server's Capture Process
5.3.6
Changing the Start SCN or Start Time of an Outbound Server's Capture Process
5.3.6.1
Changing the Start SCN of an Outbound Server's Capture Process
5.3.6.2
Changing the Start Time of an Outbound Server's Capture Process
5.3.7
Setting the First SCN for a Capture Process
5.4
Managing Rules for an XStream Out Configuration
5.4.1
Adding Rules to an XStream Out Configuration
5.4.1.1
Adding Schema Rules and Table Rules to an XStream Out Configuration
5.4.1.2
Adding Subset Rules to an Outbound Server's Positive Rule Set
5.4.1.3
Adding Rules With Custom Conditions to XStream Out Components
5.4.2
Removing Rules from an XStream Out Configuration
5.4.2.1
Removing Schema Rules and Table Rules From an XStream Out Configuration
5.4.2.2
Removing Subset Rules from an Outbound Server's Positive Rule Set
5.4.2.3
Removing Rules Using the REMOVE_RULE Procedure
5.5
Managing Declarative Rule-Based Transformations
5.5.1
Adding Declarative Rule-Based Transformations
5.5.1.1
Adding a Declarative Rule-Based Transformation That Renames a Table
5.5.1.2
Adding a Declarative Rule-Based Transformation That Adds a Column
5.5.2
Overwriting Existing Declarative Rule-Based Transformations
5.5.3
Removing Declarative Rule-Based Transformations
5.6
Dropping Components in an XStream Out Configuration
5.7
Removing an XStream Out Configuration
6
Monitoring XStream Out
6.1
About Monitoring XStream Out
6.2
Monitoring Session Information About XStream Out Components
6.3
Monitoring an Outbound Server
6.3.1
Displaying General Information About an Outbound Server
6.3.2
Displaying Status and Error Information for an Outbound Server
6.3.3
Displaying Information About an Outbound Server's Current Transaction
6.3.4
Displaying Statistics for an Outbound Server
6.3.5
Displaying the Processed Low Position for an Outbound Server
6.3.6
Determining the Process Information for an Outbound Server
6.3.7
Displaying the Apply Parameter Settings for an Outbound Server
6.4
Monitoring the Capture Process for an Outbound Server
6.4.1
Displaying Change Capture Information About Each Capture Process
6.4.2
Displaying the Registered Redo Log Files for Each Capture Process
6.4.3
Displaying Redo Log Files That Are Required by Each Capture Process
6.4.4
Displaying SCN Values for Each Redo Log File Used by Each Capture Process
6.4.5
Listing the Parameter Settings for Each Capture Process
6.4.6
Determining the Applied SCN for Each Capture Process
6.4.7
Displaying the Redo Log Scanning Latency for Each Capture Process
6.4.8
Displaying the Extra Attributes Captured by a Capture Process
6.5
Monitoring XStream Rules
6.6
Monitoring Declarative Rule-Based Transformations
6.6.1
Displaying Information About ADD COLUMN Transformations
6.6.2
Displaying Information About RENAME TABLE Transformations
7
Troubleshooting XStream Out
7.1
Diagnosing Problems with XStream Out
7.1.1
Viewing Alerts
7.1.2
Using the Streams Configuration Report and Health Check Script
7.1.3
Checking the Trace File and Alert Log for Problems
7.1.3.1
Capture Process Trace Files
7.1.3.2
Logminer Trace Files
7.1.3.3
Outbound Server Trace File
7.1.3.4
Client Application Trace Files
7.2
Problems and Solutions for XStream Out
7.2.1
An OCI Client Application Cannot Attach to the Outbound Server
7.2.2
Changes Are Failing to Reach the Client Application in XStream Out
7.2.3
The Capture Process Is Missing Required Redo Log Files
7.2.4
LCRs Streaming from an Outbound Server Are Missing Extra Attributes
7.2.5
The XStream Out Client Application Is Unresponsive
7.3
How to Get More Help with XStream Out
Part III XStream In
8
XStream In Concepts
8.1
Introduction to XStream In
8.2
The Inbound Server
8.2.1
Overview of Inbound Servers
8.2.2
Data Types Applied by Inbound Servers
8.2.3
LCR Processing Options for Inbound Servers
8.2.3.1
DML Handlers
8.2.3.1.1
Statement DML Handlers
8.2.3.1.2
Procedure DML Handlers
8.2.3.2
Error Handlers
8.2.3.3
DDL Handlers
8.2.3.4
Precommit Handlers
8.2.4
Inbound Servers and RESTRICTED SESSION
8.2.5
Inbound Server Components
8.2.6
Considerations for Inbound Servers
8.2.7
The Error Queue for an Inbound Server
8.3
Position of LCRs and XStream In
8.4
XStream In and Performance Considerations
8.4.1
Optimizing XStream In Performance for Large Transactions
8.4.2
Avoiding Potential Bottlenecks in Transaction Tracking
8.4.3
Optimizing Transaction Apply Scheduling
8.5
XStream In and Security
8.5.1
The XStream In Client Application and Security
8.5.2
XStream In Component-Level Security
8.5.3
Privileges Required by the Apply User for an Inbound Server
8.6
XStream In and Other Oracle Database Components
8.6.1
XStream In and Oracle Real Application Clusters
8.6.2
XStream In and Flashback Data Archive
8.6.3
XStream In and Transportable Tablespaces
8.6.4
XStream In and a Multitenant Environment
9
Configuring XStream In
9.1
Preparing for XStream In
9.1.1
Configure an XStream Administrator
9.1.1.1
Granting Additional Privileges to the XStream Administrator
9.1.2
Set the Relevant Initialization Parameters
9.1.3
Configure the Streams pool
9.1.4
If Required, Specify Supplemental Logging at the Source Database
9.2
Configuring XStream In
10
Managing XStream In
10.1
About Managing XStream In
10.2
Starting an Inbound Server
10.3
Stopping an Inbound Server
10.4
Setting an Apply Parameter for an Inbound Server
10.5
Changing the Apply User for an Inbound Server
10.6
Managing Apply Errors
10.6.1
Retrying Apply Error Transactions
10.6.1.1
Retrying a Specific Apply Error Transaction
10.6.1.1.1
Retrying a Specific Apply Error Transaction Without a User Procedure
10.6.1.1.2
Retrying a Specific Apply Error Transaction With a User Procedure
10.6.1.2
Retrying All Error Transactions for an Inbound Server
10.6.2
Deleting Apply Error Transactions
10.6.2.1
Deleting a Specific Apply Error Transaction
10.6.2.2
Deleting All Error Transactions for an Inbound Server
10.6.3
Managing Eager Errors Encountered by an Inbound Server
10.7
Dropping Components in an XStream In Configuration
11
Monitoring XStream In
11.1
Displaying Session Information for Inbound Servers
11.2
Displaying General Information About an Inbound Server
11.3
Displaying the Status and Error Information for an Inbound Server
11.4
Displaying Apply Parameter Settings for an Inbound Server
11.5
Displaying the Position Information for an Inbound Server
11.6
Checking for Apply Errors
11.7
Displaying Detailed Information About Apply Errors
11.7.1
Step 1: Grant Explicit SELECT Privilege on the ALL_APPLY_ERROR View
11.7.2
Step 2: Create a Procedure that Prints the Value in an ANYDATA Object
11.7.3
Step 3: Create a Procedure that Prints a Specified LCR
11.7.4
Step 4: Create a Procedure that Prints All the LCRs in the Error Queue
11.7.5
Step 5: Create a Procedure that Prints All the Error LCRs for a Transaction
12
Troubleshooting XStream In
12.1
Diagnosing Problems with XStream In
12.1.1
Viewing Alerts
12.1.2
Checking the Trace File and Alert Log for Problems
12.2
Problems and Solutions for XStream In
12.2.1
XStream In Cannot Identify an Inbound Server
12.2.2
Inbound Server Encounters an ORA-03135 Error
12.3
How to Get More Help with XStream In
Appendixes
A
Sample XStream Client Application
A.1
About the Sample XStream Client Application
A.2
Sample XStream Client Application for the Oracle Call Interface API
A.3
Sample XStream Client Application for the Java API
B
XStream Out Restrictions
B.1
Capture Process Restrictions
B.1.1
Unsupported Data Types for Capture Processes
B.1.2
Unsupported Changes for Capture Processes
B.1.2.1
Unsupported Schemas for Capture Processes
B.1.2.2
Unsupported Table Types for Capture Processes
B.1.2.3
Unsupported DDL Changes for Capture Processes
B.1.2.4
Changes Ignored by a Capture Process
B.1.2.5
NOLOGGING and UNRECOVERABLE Keywords for SQL Operations
B.1.2.6
UNRECOVERABLE Clause for Direct Path Loads
B.1.3
Supplemental Logging Data Type Restrictions
B.1.4
Operational Requirements for Downstream Capture with XStream Out
B.1.5
Capture Processes Do Not Support Oracle Label Security
B.2
Propagation Restrictions
B.2.1
Connection Qualifiers and Propagations
B.3
Outbound Server Restrictions
B.3.1
Unsupported Data Types for Outbound Servers
B.3.2
Types of DDL Changes Ignored by an Outbound Server
B.3.3
Apply Process Features That Are Not Applicable to Outbound Servers
B.4
XStream Out Rule Restrictions
B.4.1
Restrictions for Subset Rules
B.5
XStream Out Rule-Based Transformation Restrictions
B.5.1
Unsupported Data Types for Declarative Rule-Based Transformations
B.6
XStream Out Limitations for Extended Data Types
C
XStream In Restrictions
C.1
Inbound Server Restrictions
C.1.1
Unsupported Data Types for Inbound Servers
C.1.2
Unsupported Data Types for Apply Handlers
C.1.3
Types of DDL Changes Ignored by an Inbound Server
C.1.4
Current Schema User Must Exist at Destination Database
C.1.5
Inbound Servers Do Not Support Oracle Label Security
C.2
XStream In Rule Restrictions
C.2.1
Restrictions for Subset Rules
C.3
XStream In Rule-Based Transformation Restrictions
C.3.1
Unsupported Data Types for Declarative Rule-Based Transformations
C.4
XStream In Limitations for Extended Data Types
Index
Scripting on this page enhances content navigation, but does not change the content in any way.