bitbake: prserv/serv: sync database after thead quit
cover bitbake: prserv/serv: sync database after thead quit
The following changes since commit d9d5b8b499af3ae01a1e33d0d3969c54c2d4ab1b:
depmodwrapper-cross: Update to use STAGING_KERNEL_BUILDDIR (2015-01-17 17:05:45 +0000)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib chonglu/primport
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=chonglu/primport
Chong Lu (1):
bitbake: prserv/serv: sync database after thead quit
bitbake/lib/prserv/serv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Signature · 1 line
1.9.1
PATCH 1/1 bitbake: prserv/serv: sync database after thead quit
We need sync database after thread quit, else we may get a empty table after import a PR database.
[YOCTO #6752]
--- bitbake/lib/prserv/serv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
bitbake/lib/prserv/serv.py +1 -1
@@ -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)
Signature · 1 line
1.9.1
Quoted 15 lines · Chong Lu
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 <[email protected]>--- bitbake/lib/prserv/serv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)bitbake/lib/prserv/serv.py +0
-0
bitbake/lib/prserv/serv.py class PRServer(SimpleXMLRPCServer): · line 93
Quoted 8 lines
bitbake/lib/prserv/serv.py +1
-1@@ -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
Quoted 28 lines · Richard Purdie
Quoted 15 lines · Chong Lu
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 <[email protected]>--- bitbake/lib/prserv/serv.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)bitbake/lib/prserv/serv.py +0
-0bitbake/lib/prserv/serv.py class PRServer(SimpleXMLRPCServer): · line 93
Quoted 8 lines
bitbake/lib/prserv/serv.py +1
-1@@ -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.
Quoted 4 lines
Cheers,
Richard
Hi Richard,
I try your patch in my environment, it can fix [YOCTO #6752]. Thanks for your improve.
Best Regards
Chong