Class ExportPartition
- java.lang.Object
-
- com.identityworksllc.iiq.common.threads.SailPointWorker
-
- com.identityworksllc.iiq.common.task.export.ExportPartition
-
- All Implemented Interfaces:
Serializable
,Runnable
- Direct Known Subclasses:
CleanupLinksPartition
,ExportIdentitiesPartition
,ExportLinksPartition
public abstract class ExportPartition extends SailPointWorker implements Serializable
An abstract superclass for all export partitions.It will open a connection to the target database and then invoke export() on the subclass.
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.identityworksllc.iiq.common.threads.SailPointWorker
SailPointWorker.ExceptionHandler
-
-
Field Summary
Fields Modifier and Type Field Description protected sailpoint.object.Configuration
configuration
The configuration loaded inexecute(SailPointContext, Log)
protected long
cutoffDate
The cutoff date, milliseconds.protected long
exportTimestamp
The export timestamp in epoch milliseconds.protected String
filterString
The filter stringprotected String
filterString2
The second filter string if any-
Fields inherited from class com.identityworksllc.iiq.common.threads.SailPointWorker
monitor, MULTI_SERIALIZED_WORKERS_ATTR, outcome
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
ExportPartition()
Constructs a new ExportPartition
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected static void
addCommonDateFields(NamedParameterStatement statement, Date exportDate, Date created, Date modified, Date lastRefresh)
Adds the common date fields (which must have the given names) to the given prepared statement.Object
execute(sailpoint.api.SailPointContext context, org.apache.commons.logging.Log _logger)
The worker entrypointprotected abstract void
export(sailpoint.api.SailPointContext context, Connection connection, org.apache.commons.logging.Log logger)
Exports the data required to the listed databasestatic Connection
openConnection(sailpoint.api.SailPointContext context, ExportConnectionInfo connectionInfo)
Opens the connection to the target database using the provided connection infovoid
setConnectionInfo(ExportConnectionInfo connectionInfo)
String
toString()
-
Methods inherited from class com.identityworksllc.iiq.common.threads.SailPointWorker
addChild, addDependency, addTaskCallback, checkCancel, getDependencyOutput, getDependentPhase, getExceptionHandler, getMonitor, getParent, getPhase, getWorkerName, isTerminated, isTimedOut, run, runnable, setCompletedCounter, setDependentPhase, setExceptionHandler, setFailedCounter, setMonitor, setParent, setPhase, setTimeout, submitWithListeners, terminate, toCallable, toForkJoinTask, toFutureTask, toRequest, toRequest
-
-
-
-
Field Detail
-
configuration
protected transient sailpoint.object.Configuration configuration
The configuration loaded inexecute(SailPointContext, Log)
-
cutoffDate
protected long cutoffDate
The cutoff date, milliseconds.We should not export records older than this date.
-
exportTimestamp
protected long exportTimestamp
The export timestamp in epoch milliseconds.We should not export records newer than this date.
-
filterString
protected String filterString
The filter string
-
filterString2
protected String filterString2
The second filter string if any
-
-
Constructor Detail
-
ExportPartition
protected ExportPartition()
Constructs a new ExportPartition
-
-
Method Detail
-
addCommonDateFields
protected static void addCommonDateFields(NamedParameterStatement statement, Date exportDate, Date created, Date modified, Date lastRefresh) throws SQLException
Adds the common date fields (which must have the given names) to the given prepared statement.The modified and last refresh dates can be null.
- Parameters:
statement
- The named parameter statementexportDate
- The export datecreated
- The creation datemodified
- The modified date (which can be null)lastRefresh
- The last refresh date (which can be null)- Throws:
SQLException
- if any failures occur (unlikely)
-
openConnection
public static Connection openConnection(sailpoint.api.SailPointContext context, ExportConnectionInfo connectionInfo) throws sailpoint.tools.GeneralException
Opens the connection to the target database using the provided connection info- Parameters:
context
- The sailpoint context, used to decrypt the passwordconnectionInfo
- The provided connection info, extracted from the export task def- Returns:
- The open connection
- Throws:
sailpoint.tools.GeneralException
- if any failures occur
-
execute
public final Object execute(sailpoint.api.SailPointContext context, org.apache.commons.logging.Log _logger) throws Exception
The worker entrypoint- Specified by:
execute
in classSailPointWorker
- Parameters:
context
- The private context to use for this thread worker_logger
- The log attached to this Worker- Returns:
- Always null, nothing required here
- Throws:
Exception
- if anything goes wrong
-
export
protected abstract void export(sailpoint.api.SailPointContext context, Connection connection, org.apache.commons.logging.Log logger) throws sailpoint.tools.GeneralException
Exports the data required to the listed database- Parameters:
context
- The contextconnection
- The connection to the target databaselogger
- The logger- Throws:
sailpoint.tools.GeneralException
- if any failures occur
-
setConnectionInfo
public void setConnectionInfo(ExportConnectionInfo connectionInfo)
-
toString
public String toString()
- Overrides:
toString
in classSailPointWorker
- See Also:
Object.toString()
-
-