Openembedded Bitbake Development
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Chong Lu <Chong.Lu@windriver.com>
Cc: bitbake-devel@lists.openembedded.org
Subject: Re: [PATCH 1/1] bitbake: prserv/serv: sync database after thead quit
Date: Wed, 21 Jan 2015 13:54:48 +0000	[thread overview]
Message-ID: <1421848488.1798.55.camel@linuxfoundation.org> (raw)
In-Reply-To: <dcc1cd29cdf4dbcf242fda70bbd03fe9a2e84263.1421657244.git.Chong.Lu@windriver.com>

On Mon, 2015-01-19 at 16:48 +0800, Chong Lu wrote:
> We need sync database after thread quit, else we may get a empty table
> after import a PR database.
> 
> [YOCTO #6752]
> 
> Signed-off-by: Chong Lu <Chong.Lu@windriver.com>
> ---
>  bitbake/lib/prserv/serv.py | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/bitbake/lib/prserv/serv.py b/bitbake/lib/prserv/serv.py
> index 25eb46a..c774c5e 100644
> --- a/bitbake/lib/prserv/serv.py
> +++ b/bitbake/lib/prserv/serv.py
> @@ -87,7 +87,7 @@ class PRServer(SimpleXMLRPCServer):
>                  self.finish_request(request, client_address)
>                  self.shutdown_request(request)
>                  iter_count = (iter_count + 1) % iterations_between_sync
> -                if iter_count == 0:
> +                if iter_count == 0 or self.quit:
>                      self.table.sync_if_dirty()
>              except:
>                  self.handle_error(request, client_address)

Thanks for the patch. I had a look at this problem and I think there are
bigger problems with the code. Can you take a look at the patch I've
just posted, it should solve this issue as well as several others.

Cheers,

Richard



  reply	other threads:[~2015-01-21 13:55 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-19  8:48 [PATCH 0/1] bitbake: prserv/serv: sync database after thead quit Chong Lu
2015-01-19  8:48 ` [PATCH 1/1] " Chong Lu
2015-01-21 13:54   ` Richard Purdie [this message]
2015-01-22  1:36     ` Chong Lu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1421848488.1798.55.camel@linuxfoundation.org \
    --to=richard.purdie@linuxfoundation.org \
    --cc=Chong.Lu@windriver.com \
    --cc=bitbake-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox