Thanks, Greg. We thought so but just wanted to check for sure.
Roger Whitcomb | Architect, Engineering | [email protected]| Ingres | 500 Arguello Street | Suite 200 | Redwood City | CA | 94063 | USA <http://www.google.com/maps?f=q&hl=en&geocode=&q=500+Arguello+Street+%7C +Suite+200+%7C+Redwood+City+%7C+CA+%7C+94063+%7C+USA+&sll=37.0625,-95.67 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:[email protected]] Sent: Monday, July 18, 2011 11:49 AM To: [email protected] Subject: Re: Question about background tasks Yes, it is safe to call isPending() on a task from another thread. On Jul 18, 2011, at 2:42 PM, Roger L. Whitcomb wrote: Regarding org.apache.pivot.util.concurrent.Task<V> derived tasks: Is it safe for one task running on a background thread to call the isPending() method of some other task that is running on a different background thread? Our particular use case involves two background tasks that need to coordinate (minimally) with each other. A second task wants to keep running at least as long as the first task is still in progress. So the second task periodically checks theisPending() method of the first task. Roger Whitcomb Architect, Engineering Ingres Corporation [email protected] PHONE +1 650.587.5596 FAX +1 650.587.5550 www.ingres.com <http://www.ingres.com/> This transmission is confidential and intended solely for the use of the recipient named above. It may contain confidential, proprietary, or legally privileged information. If you are not the intended recipient, you are hereby notified that any unauthorized review, use, disclosure or distribution is strictly prohibited. If you have received this transmission in error, please contact the sender by reply e-mail and delete the original transmission and all copies from your system.
