Property Tester threading question [message #330139] |
Wed, 16 July 2008 13:03  |
Eclipse User |
|
|
|
Originally posted by: x_raajes.ugs.com
In our RCP app, we have property testers that determine the enable/disable
conditions for menu items (in the menu bar as well as in context menus),
using the Eclipse 3.3 menus/commands/handlers mechanism. Many times, the
conditions are based on some property on the domain object that was
right-clicked on, and to determine the property value, we have to make a
server call (to the DB).
We are making a conscious effort to avoid making server calls from within
the UI thread, to avoid locking up the UI. However, the property tester is
sometimes activated from the UI thread, and since it makes a call to the
server to determine the properties, we have a server call on the UI thread.
If I try to start the server call in another background thread, then I
wouldn't be able to return the right value from the test() method of the
property tester (because the thread wouldn't have completed yet). I am
wondering if anyone has come across such an issue, and if they have a
reasonable solution for this.
|
|
|
|
Powered by
FUDForum. Page generated in 0.02386 seconds