RE: [Zope] Auto restart (at Zope's own initiative !!!)
Would that make a difference between dying when imported at the beginning of a script, and not dying when imported within a run() method? Knowing C, I'd expect randomness, but this behavior is consistent. ---------- Keith J. Farmer kfarmer@thuban.org http://www.thuban.org -----Original Message----- From: Brian Lloyd [mailto:brian@zope.com] Sent: Tuesday, January 29, 2002 11:52 Re-read my post :) You are "pulling a set of row from a database" by calling a dll or API of some sort; you need to understand the threading requirements of that API and write your calls to it in a compatible way.
Would that make a difference between dying when imported at the beginning of a script, and not dying when imported within a run() method? Knowing C, I'd expect randomness, but this behavior is consistent.
Sure it could. If the dll you are calling maintains per-thread data structures or uses API calls that are sensitive to threading, you may well need to load and call it within the same thread to avoid a crash. When you import outside of a Thread.run(), you are loading the dll in a different thread than you are calling it from. Brian Lloyd brian@zope.com Software Engineer 540.361.1716 Zope Corporation http://www.zope.com
participants (2)
-
Brian Lloyd -
Keith J. Farmer