Class BTRepopulateBundleRequirement
java.lang.Object
overit.geocall.bl.BusinessTask<Void>
overit.geocallapp.wfm.bundler.bl.bundleRequirement.migration.task.BTRepopulateBundleRequirement
- All Implemented Interfaces:
Serializable,Interruptable,Tool
Task to repopulate the table RBUNREQUIREMENT from the values contained in
ABUNDLE denormalized fields (ABUNMANDATORYRESOURCES, ABUNPREFERREDRESOURCES).
This task is used for migration from the old denormalized structure to the new normalized RBUNREQUIREMENT table.
- Since:
- 22.0
- See Also:
- GCApi:
- task
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected intprotected intprotected booleanprotected static final LogChannelprotected TimeSlot -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidImplements this method to write the specific task logic to handle the input parameter.voidprotected voidpopulateTable(DBView dbvBundles, PoolKit pk) Populates the RBUNREQUIREMENT table from the extracted bundles.Methods inherited from class overit.geocall.bl.BusinessTask
start, start, startAlone, startInBackground
-
Field Details
-
LOG
-
interrupt
protected boolean interrupt -
timeSlot
-
deletedRows
protected int deletedRows -
insertedRows
protected int insertedRows
-
-
Constructor Details
-
BTRepopulateBundleRequirement
public BTRepopulateBundleRequirement()
-
-
Method Details
-
body
Description copied from class:BusinessTaskImplements this method to write the specific task logic to handle the input parameter.- Specified by:
bodyin classBusinessTask<Void>- Parameters:
i- the object upon which the task will works onpk- the poolkit containing the reference to the database connection that can be used- Throws:
DAException- in case of database errorDAValidateException- in case of database validation error
-
populateTable
protected void populateTable(DBView dbvBundles, PoolKit pk) throws DAValidateException, DAException, SQLException Populates the RBUNREQUIREMENT table from the extracted bundles.For each bundle with denormalized requirement data, deletes existing records and inserts new ones based on the denormalized field values.
- Parameters:
dbvBundles- the DBView containing bundles with denormalized requirement datapk- the PoolKit for database operations- Throws:
DAValidateException- if validation failsDAException- if a database error occursSQLException- if a SQL error occurs
-
pleaseInterrupt
public void pleaseInterrupt()- Specified by:
pleaseInterruptin interfaceInterruptable
-