Class FixCountersFragment

java.lang.Object
ch.tocco.nice2.dbrefactoring.spi.liquibase.JdbcHelper
ch.tocco.nice2.dbrefactoring.impl.install.fragments.FixCountersFragment
All Implemented Interfaces:
InstallFragment

@Component public class FixCountersFragment extends JdbcHelper implements InstallFragment
this fragment fixes all counters of all entity models counters need to be of type "counter" to be considered fixing consists of the following actions: - sets new counters on entities (can only happen with faulty databases, counters are not-null and unique) - deletes counters which have a businessunit but should not have one, and the other way around - deletes duplicate counters, meaning the same field, entity and businessunit (if entity model is linked to businessunit) - creates counters that should exist, but do not - set counters to correct count