pivot-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Roger L. Whitcomb" <Roger.Whitc...@ingres.com>
Subject RE: What is legal to do in second thread?
Date Fri, 22 Apr 2011 18:05:19 GMT
Thanks, Greg.


Roger Whitcomb | Architect, Engineering | Roger.Whitcomb@ingres.com
<mailto:Roger.Whitcomb@ingres.com> | Ingres | 500 Arguello Street |
Suite 200 | Redwood City | CA | 94063 | USA
7068&sspn=50.557552,73.037109&ie=UTF8&t=h&z=16&iwloc=addr>  | +1
650-587-5596 | fax: +1 650-587-5550

From: Greg Brown [mailto:gk_brown@verizon.net] 
Sent: Friday, April 22, 2011 10:07 AM
To: user@pivot.apache.org
Subject: Re: What is legal to do in second thread?


	Trying to understand the Pivot threading model:  what is okay to
do in a background thread re: the GUI objects?

	-          Is it legal to change the data model (of a TreeView
or similar)?



-          Is it legal to update the text of a TextInput (or similar)?



What are the implications of doing things that aren't "legal"?  Are we
threatening to crash or destabilize the JVM?  


Probably not.

Or is it that we may have race conditions or data corruption because
data structures are not thread-safe?


Yes, that is possible.


Pivot's threading model is basically the same as Swing's - any UI
updates need to be done on the UI thread. Any time you want to call into
the UI thread from a background thread, you need to call




View raw message