Configure the Challenge Pads Used for Challenge Types

22 Developing a Custom Loader for OAAM Offline 22-1 22 Developing a Custom Loader for OAAM Offline This chapter describes the overall data loader framework for OAAM Offline: ■ Basic framework and the default implementation ■ How to override the default functionality This document assumes that you are familiar with the concepts of OAAM Offline.

22.1 Base Framework

A custom loader is required only if the data from sources other than a database, data other than login, or complex data is needed for the OAAM Offline task.

22.1.1 Overview

The OAAM Offline custom loader consists of the following key parts: ■ loadable object ■ data source ■ loader ■ run modes 22-2 Oracle Fusion Middleware Developers Guide for Oracle Adaptive Access Manager Figure 22–1 Basic Framework of a Custom Loader The loadable object represents an individual data record. The data source represents the entire store of data records and the loader processes the records. There are two types of run mode: load and playback. The run modes encapsulate the differences between loading a Session Set and running a Session Set.

22.1.2 Important Classes

Table 22–1 provides a summary of the different data loader classes. Developing a Custom Loader for OAAM Offline 22-3

22.1.3 General Framework Execution

The following pseudocode shows the general framework execution. AbstractRiskAnalyzerLoader loader = runMode.buildObjectLoader; RiskAnalyzerDataSource dataSource = runMode.acquireDataSource; try{ while dataSource.hasMoreRecords { AbstractTransactionRecord eachRecord = dataSource.nextRecord; loader.processeachRecord; } } finally { dataSource.close; }

22.2 Default Implementation

The default implementation for the Risk Analyzer data loader framework works as follows: Load mode : When in load mode, it uses any database as a data source, it expects login data, and it performs device fingerprinting. Playback mode : When in playback mode, it uses the VCRYPT_TRACKER_USERNODE_ LOGS and V_FPRINTS tables as its data source, and it runs each record through all active models. Table 22–1 Data Loader Classes Class Description RunMode There are two basic types of RunMode: load and playback. Load run modes are responsible for importing session set data into the OAAM Offline system, and the playback run mode is responsible for processing preloaded session set data. Each run mode is responsible for constructing data source and loader. An additional responsibility is determining how to start where a previous job ended, in the cases of recurring schedules of autoincrementing session sets or paused and resumed run sessions. AbstractLoadRunMode and AbstractPlaybackRunMode each have a factory method named getInstance. These methods check to see if the default run modes have been overridden. RiskAnalyzerDataSource The RiskAnalyzerDataSource is responsible for acquiring the data and iterating through it. RiskAnalyzerDataSource has two abstract implementors: AbstractJDBCRiskAnalyzerDataSource and AbstractTextFile-RiskAnalyzerDataSource. The AbstractJDBCRiskAnalyzerDataSource implements the base functionality for iterating through a JDBC result set, and the AbstractTextFileRiskAnalyzerDataSource implements the base functionality for iterating through a text file. AbstractTransactionRecord The AbstractTransactionRecord class only contains the state and behavior required to manage the overall risk analysis process. Subclasses will add additional state and behavior to satisfy client requirements. AbstractRiskAnalyzerLoader The AbstractRiskAnalyzerLoader is the base implementation of ObjectLoader for the Risk Analyzer process. It provides basic exception handling, but otherwise leaves the implementation up to its subclasses.