﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
21109	Performance regression due to wrap_database_errors	Anssi Kääriäinen	nobody	"Djangobench comparison between 1.5.x and 1.6.x revealed a problem with database error wrapping. Somewhat surprisingly the reason for the regression is functools.wraps. In addition it is possible to use @cached_property for connection.wrap_database_errors.

The regression was around 10% for query_iterator and around 50% for raw_sql djangobench benchmarks.

A patch is available from https://github.com/akaariai/django/commit/eafc373c16350abe51c565c8aefbe36cabf5219e. There is a minor comment fix to be done, otherwise ready for checkin.

Discussion about performance of 1.5.x vs 1.6.x: https://groups.google.com/forum/#!topic/django-developers/ytr3j8suVxE"	Cleanup/optimization	closed	Database layer (models, ORM)	1.6-beta-1	Normal	fixed			Ready for checkin	1	0	0	0	0	0
