Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id B1204E00ABE; Thu, 30 Jul 2015 06:18:48 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low * trust * [209.85.212.171 listed in list.dnswl.org] * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] Received: from mail-wi0-f171.google.com (mail-wi0-f171.google.com [209.85.212.171]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id 1B64CE00A7E for ; Thu, 30 Jul 2015 06:18:45 -0700 (PDT) Received: by wibxm9 with SMTP id xm9so244515585wib.0 for ; Thu, 30 Jul 2015 06:18:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=PjHJ9okWBRpdzHmvi4tLi3C9FKoXi3u/qCuTRnRAtPg=; b=IL2I+WO17KwpyKW3G1b3vT3MLk12UTCYTTPXZEmr2OE/1zxJ01eW5NoixnVUeON/un Tb8BaoyvXXyixqFQvyFGnXE681wtCmpeSxs2H5uvSAZuota8c5k0PGOxyxHWL4NO44P1 gNTvLiIsZVBOfigdWj+MSZhFmfM3otgC5FwyjgmgfDFRqYKO2LaDSU1O7LuH3Y1FeIXJ 161hI1bGNlz4q/h7Z0cieWYxSwZc1kJ9dHMUWgQYncdWmRtCo6HlNvqgxVOqCW22Cuei I2cpxqyseHCvFhAE3GYJV08PfE6NjHk33+ypWphW3NJJKyG8Hv0JbMSGQbOI9DThxP8y rz6Q== X-Gm-Message-State: ALoCoQl4i+r/ydURZ4SUqTAeITLQEHCgXXuIz6CQ6oGSKU4LQq5nuvv0w+XEIAgsiUDsDNsbxAdi X-Received: by 10.180.198.199 with SMTP id je7mr6449548wic.34.1438262324689; Thu, 30 Jul 2015 06:18:44 -0700 (PDT) Received: from draco.icx.intel.com ([83.217.123.106]) by smtp.gmail.com with ESMTPSA id c11sm29877262wib.1.2015.07.30.06.18.43 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 30 Jul 2015 06:18:43 -0700 (PDT) From: Michael Wood To: toaster@yoctoproject.org Date: Thu, 30 Jul 2015 14:18:40 +0100 Message-Id: <1438262320-20997-1-git-send-email-michael.g.wood@intel.com> X-Mailer: git-send-email 2.1.4 Subject: [review-request][PATCH] bitbake: toastermain: Add a longer default database timeout X-BeenThere: toaster@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Web based interface for BitBake List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Jul 2015 13:18:48 -0000 When using sqlite we sometimes see Database Locked exceptions when we fire off database calls asynchronously from the UI. We need sqlite to wait a bit longer for the lock to be released. n.b In production setup we hopefully wouldn't be using sqlite. docs.djangoproject.com/en/1.6/ref/databases/#database-is-locked-errors Signed-off-by: Michael Wood --- bitbake/lib/toaster/toastermain/settings.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/bitbake/lib/toaster/toastermain/settings.py b/bitbake/lib/toaster/toastermain/settings.py index c72a904..ca32665 100644 --- a/bitbake/lib/toaster/toastermain/settings.py +++ b/bitbake/lib/toaster/toastermain/settings.py @@ -46,6 +46,13 @@ DATABASES = { 'PASSWORD': '', 'HOST': '127.0.0.1', # Empty for localhost through domain sockets or '127.0.0.1' for localhost through TCP. 'PORT': '3306', # Set to empty string for default. + + # Needed when Using sqlite especially to add a longer timeout for waiting + # for the database lock to be released + # https://docs.djangoproject.com/en/1.6/ref/databases/#database-is-locked-errors + 'OPTIONS': { + 'timeout': 20, + }, } } -- 2.1.4