dideher / minoas

Ολοκληρωμένο Πληροφοριακό Σύστημα Διαχείρησης Διεύθυνσης Δ/μιας Εκπ/σης Ηρακλείου
6 stars 4 forks source link

RankInfoCalculation.recalculateRankInfos() transaction locks database #181

Closed gandreadakis closed 11 years ago

gandreadakis commented 11 years ago

When RankInfoCalculation.recalculateRankInfos() transaction is run :

    @Asynchronous
    @Transactional(TransactionPropagationType.REQUIRED)
    public QuartzTriggerHandle schedule(@Expiration Date when, 
            @IntervalDuration Long interval,
            @FinalExpiration Date endDate) {

        rankInfoCalculation.recalculateRankInfos();

        getEntityManager().flush();
        info("Finished Recalculating ReankInfos!");
        return null;
    }

it locks the database until processing is done. Find a way to do it in batches.

gandreadakis commented 11 years ago

Done. Closing issue