summaryrefslogtreecommitdiffstats
path: root/lib/bb/ui/uievent.py
AgeCommit message (Collapse)Author
2015-03-24uievent: catch and log exceptions in receiving eventsAlexandru DAMIAN
This patch prevents tracebacks and instead logs exceptions that may happen during event processing. [YOCTO #7216] Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com>
2014-06-06uievent: retry on handler registration failureAlexandru DAMIAN
The registration of a remote UI event handler may fail if the server cooker is currently in some certain states. This may happen, for example, when a remote UI is started very fast after the bitbake server is started, and the server hadn't time to finish initial configuration parsing. Rather than fail outright, we have the remote UI event retry registration for five time at one-second intervals, in the hope it will succeed. Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-06xmlrpc: client - remove fatal errorsAlexandru DAMIAN
When we use the XMLRPC client API to connect to a bitbake server, we want to receive errors from the API instead of having the API exiting without warning. Thus the "bb.fatal" calls have been replaced with "bb.warn" calls, and we re-raise the original exception for handling by the original caller. The bitbake starting script has been modified to properly test for failures in calling the client API and handle them. Additional error handling added in the client, as to prevent fatal crashes. Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-03-30server/xmlrpc: Simlify featureset handlingRichard Purdie
Rather than passing featureset around various places where the data doesn't really belong, run a command at connection time to set the appropriate features. This is similar to what the process server does. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-18bitbake: cooker,xmlrpc,servers: implement CookerFeaturesAlexandru DAMIAN
Implementing feature set selection that allows a client to enable specific features in the server at connection time. Only enabling of features is supported, as there is no way to safely remove data loaded into the cooker. Once enabled, a feature will remain enabled for the life of the cooker. Client-server connection now supports specifying the feature set required by the client. This is implemented in the Process server using a managed proxy list, so the server cooker will now load dynamically needed features based on what client connects to it. In the XMLRPC server the feature set is requested by using a parameter for registerUIHandler function. This allows observer-only clients to also specify features for the server. The server code configuration now is completly separated from the client code. All hardcoding of client knowledge is removed from the server. The extra_caches is removed as the client can now specify the caches it needs using the feature. The UI modules now need to specify the desired featureSet. HOB is modified to conform to the featureSet specification. The only feature available is CookerFeatures.HOB_EXTRA_CACHES which forces loading the bb.cache_extra:HobRecipeInfo class. Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-17knotty, xmlrpc: add observer-only modeAlexandru DAMIAN
I add an observer only mode for the knotty UI and the XMLRPC server that will allow the UI to register a callback with a server in order to receive events. The observer-UI is able to send read-only commands to the server, and also is able to register as an event handler. Read-only commands are the commands that do not change the state of the server and have been marked as such in the command module. The observer can switch to a full client if it calls addClient at any time, and the server has no other client running. Signed-off-by: Alexandru DAMIAN <alexandru.damian@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-12-04uievent: Fix an init raceRichard Purdie
There is a race where the registerEventHandler() server call may happen in a different thread to the main UI, causing the main UI to see httplib.CannotSendRequest exceptions. This moves the call into the main thread, removing the init race and fixing errors I was seeing with the xmlrpc backend. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23bitbake: Add client socket info for BitBakeServerConnectionDongxiao Xu
In server/client split model, the client will bind to a specific address and port. We need to pass the values to BitBakeServerConnection(). Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-06-08xmlrpc/event: Add ability to send pickled events to UI if requestedRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-05-27uievent: fix queueing of events for xmlrpc before UI has loadedJoshua Lock
The change to Queue up events before the UI is spawned broke the xmlrpc server because the uievent implementation of BBUIEventQueue expects pickled strings for its queue_event() method. This is because the RPC exposed event.send() method must accept pickled strings, but for xmlrpc event.send() is just mapped to queue_event(). Work around this by adding a send_event method which unpickles strings and hands them off to queue_event() which can then be used for the remapping. Signed-off-by: Joshua Lock <josh@linux.intel.com>
2010-11-21Split up the ParseProgress eventChris Larson
We now have ParseStarted, ParseProgress, and ParseCompleted. I think this clarifies matters, and avoids sending all our statistics with every parse progress event. Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-04-11Apply some 2to3 transforms that don't cause issues in 2.6Chris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-04-09Formatting cleanupsChris Larson
Signed-off-by: Chris Larson <chris_larson@mentor.com>
2010-01-19event.py: Convert to using pickle for events and isinstance in knotty UI handlerRichard Purdie
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2009-05-11[ui] Fix import statements reported by pyflakesHolger Hans Peter Freyther
We ignore the following kind of warnings import gtk import gtk.glade... as glade is not imported by default and need that extra line, pyflakes does not know...
2008-04-06utils.py: Improve compile/execute error messagesRichard Purdie
2007-08-18uievent.py: Fix teardown racesRichard Purdie
2007-08-18Add the start of several UI modulesRichard Purdie