Thanks for pointing that out.  I think having connection and cursor member
variables makes was something we were on the fence about anyways, so it's
probably a good idea to remove them if it's best practice.


On Wed, Apr 16, 2014 at 1:01 PM, Joshua Shorenstein <
notifications@github.com> wrote:

> In qiita_db/sql_connection.py:
>
> > @@ -21,8 +22,10 @@ def __init__(self):
> >                                     database=qiita_db_config.database,
> >                                     host=qiita_db_config.host,
> >                                     port=qiita_db_config.port)
> > -        self._dflt_cursor = self.connection.cursor()
>
> Looking at http://initd.org/psycopg/docs/faq.html under Best practices,
> it's probably better to not have a single reused cursor and just make a new
> one with each call. It can cause some memory use issues down the line.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/biocore/qiita/pull/29/files#r11700966>
> .
>