Skip to content
Snippets Groups Projects
Commit 1959ecc2 authored by cramakri's avatar cramakri
Browse files

BIS-131 SP-214 : Use the screening transaction in the screening db-modifying aggregation service

SVN: 26201
parent 3c087042
No related branches found
No related tags found
No related merge requests found
......@@ -223,14 +223,8 @@ public abstract class AbstractDbModifyingAggregationService<T extends DataSetInf
NoOpDelegate delegate = new NoOpDelegate(preStagingUsage);
@SuppressWarnings("unchecked")
IDataSetRegistrationDetailsFactory<T> registrationDetailsFactory =
(IDataSetRegistrationDetailsFactory<T>) new DefaultDataSetRegistrationDetailsFactory(
getRegistratorState(), null);
DataSetRegistrationService<T> service =
new DataSetRegistrationService<T>(this, incoming, registrationDetailsFactory,
cleanUpAction, delegate);
createRegistrationService(incoming, cleanUpAction, delegate);
return service;
} catch (IOException e)
......@@ -239,6 +233,23 @@ public abstract class AbstractDbModifyingAggregationService<T extends DataSetInf
}
}
/**
* Create a registration service using the given parameters. Subclasses may override.
*/
protected DataSetRegistrationService<T> createRegistrationService(DataSetFile incoming,
IDelegatedActionWithResult<Boolean> cleanUpAction, NoOpDelegate delegate)
{
@SuppressWarnings("unchecked")
IDataSetRegistrationDetailsFactory<T> registrationDetailsFactory =
(IDataSetRegistrationDetailsFactory<T>) new DefaultDataSetRegistrationDetailsFactory(
getRegistratorState(), null);
DataSetRegistrationService<T> service =
new DataSetRegistrationService<T>(this, incoming, registrationDetailsFactory,
cleanUpAction, delegate);
return service;
}
/**
* The file the registration infrastructure should treat as the incoming file in the dropbox.
*/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment