diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-08-23 16:16:50 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-08-26 11:29:46 +0100 |
commit | 69aab78dd830b0ad570cf9b7bfe2da8e8b793e23 (patch) | |
tree | 8c799233df8ef5f3e9129da4c54241acea2c65f9 /bitbake/lib/bb/server/xmlrpc.py | |
parent | bfab986ccd59636d0b0e79309f020e55481b0567 (diff) | |
download | poky-69aab78dd830b0ad570cf9b7bfe2da8e8b793e23.tar.gz |
bitbake: bitbake: Add ui event handlers filtering
Add functionality to allow UIs to update and change the types of events they
recieve. To do this we need to add a new command and also need to be able
to obtain the current event hander ID. In the case of xmlrpc, this is
straightforward, in the case of the process server we need to save the result
in a multiprocessing.Value() so we can retrive it. An excplit command
was added to the server API to facilitate this.
The same function can also be used to mask or unmask specific log messages,
allowing the UI to optionally differ from the standard set of message
filtering.
Based upon work by Cristiana Voicu <cristiana.voicu@intel.com>
(Bitbake rev: ba5a6c88785d9889d4172ec79937ac2a5555327e)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/server/xmlrpc.py')
-rw-r--r-- | bitbake/lib/bb/server/xmlrpc.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/bitbake/lib/bb/server/xmlrpc.py b/bitbake/lib/bb/server/xmlrpc.py index d290550e9f..4dee5d9fea 100644 --- a/bitbake/lib/bb/server/xmlrpc.py +++ b/bitbake/lib/bb/server/xmlrpc.py | |||
@@ -95,7 +95,8 @@ class BitBakeServerCommands(): | |||
95 | """ | 95 | """ |
96 | s, t = _create_server(host, port) | 96 | s, t = _create_server(host, port) |
97 | 97 | ||
98 | return bb.event.register_UIHhandler(s) | 98 | self.event_handle = bb.event.register_UIHhandler(s) |
99 | return self.event_handle | ||
99 | 100 | ||
100 | def unregisterEventHandler(self, handlerNum): | 101 | def unregisterEventHandler(self, handlerNum): |
101 | """ | 102 | """ |
@@ -109,6 +110,9 @@ class BitBakeServerCommands(): | |||
109 | """ | 110 | """ |
110 | return self.cooker.command.runCommand(command, self.server.readonly) | 111 | return self.cooker.command.runCommand(command, self.server.readonly) |
111 | 112 | ||
113 | def getEventHandle(self): | ||
114 | return self.event_handle | ||
115 | |||
112 | def terminateServer(self): | 116 | def terminateServer(self): |
113 | """ | 117 | """ |
114 | Trigger the server to quit | 118 | Trigger the server to quit |