alphagov / trade-tariff-backend

Enabling the population and distribution via API of UK Customs tariffs and duties
MIT License
7 stars 6 forks source link

Remove transactions from the importer #185

Closed matthewford closed 10 years ago

matthewford commented 10 years ago

We're seeing mysql locks with the current method of wrapping a day's update in a transaction. We can safely remove the transaction block as if an error occurs we need to rollback (which deletes all the added records) anyway.

This PR also speeds up a couple of specs which were taking a very long time.