Re: [Zope] threading cont ...boundary=------------98A416F9F4157B1993D63C72
ZScheduler has been superceded by Xron http://www.zope.org/Members/lstaffor/Xron -- Loren From: "Martijn Pieters" [EMAIL PROTECTED] On Wed, Aug 09, 2000 at 10:12:50AM +0800, Nicholas Lo wrote: In fact, I'm trying to use ZOPE to do some automation, eg. reminder emails, news clipping, or maybe some WAP applications as well. I want to make it able to schedule itselfs so as to better utilise resources, make ZOPE more or less real-time, and to prevent overloading or spam from the content source. Well, since ZOPE runs from source, I think we may extend it to do some remote control works as well. eg. redirect your fax at home to your email account, allow you to listen to your home voice mails, etc. Have a look at ZScheduler, which just just that. If not exactly what you need, it will certainly show you how to access the Zope database from a seperate thread: http://www.zope.org//Members/lstaffor/ZScheduler ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] threading cont ...boundary=------------98A416F9F4157B1993D63C72
Nicholas Lo writes: ... database modification seen inside but not outside of process ... Obviously, the database modifications have not been commited. Auto-Commit in Zope is coupled to *one* thread serving the request: It works by registering with the "transaction" associated with the current thread. At the end of a request the transaction of the current thread is commited (or aborted, if an error occured). If registration is done in a different thread, the actions are not commited/aborted at the end of the request. Why do you want to make your life more difficult by splitting a Zope thread into several? Dieter ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] threading cont ...boundary=------------98A416F9F4157B1993D63C72
Dieter Maurer wrote: Nicholas Lo writes: ... database modification seen inside but not outside of process ... Obviously, the database modifications have not been commited. Auto-Commit in Zope is coupled to *one* thread serving the request: It works by registering with the "transaction" associated with the current thread. At the end of a request the transaction of the current thread is commited (or aborted, if an error occured). If registration is done in a different thread, the actions are not commited/aborted at the end of the request. Why do you want to make your life more difficult by splitting a Zope thread into several? Dieter oic ... so, is there anyway to make database routines run in separate threads? In fact, I'm trying to use ZOPE to do some automation, eg. reminder emails, news clipping, or maybe some WAP applications as well. I want to make it able to schedule itselfs so as to better utilise resources, make ZOPE more or less real-time, and to prevent overloading or spam from the content source. Well, since ZOPE runs from source, I think we may extend it to do some remote control works as well. eg. redirect your fax at home to your email account, allow you to listen to your home voice mails, etc. anyway, thanks Nicholas Lo ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] threading cont ...boundary=------------98A416F9F4157B1993D63C72
On Wed, Aug 09, 2000 at 10:12:50AM +0800, Nicholas Lo wrote: In fact, I'm trying to use ZOPE to do some automation, eg. reminder emails, news clipping, or maybe some WAP applications as well. I want to make it able to schedule itselfs so as to better utilise resources, make ZOPE more or less real-time, and to prevent overloading or spam from the content source. Well, since ZOPE runs from source, I think we may extend it to do some remote control works as well. eg. redirect your fax at home to your email account, allow you to listen to your home voice mails, etc. Have a look at ZScheduler, which just just that. If not exactly what you need, it will certainly show you how to access the Zope database from a seperate thread: http://www.zope.org//Members/lstaffor/ZScheduler -- Martijn Pieters | Software Engineermailto:[EMAIL PROTECTED] | Digital Creations http://www.digicool.com/ | Creators of Zope http://www.zope.org/ | ZopeStudio: http://www.zope.org/Products/ZopeStudio - ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] threading
Just a simple question. According to Amos' How-To: Thread Safety in Zope 2, what is mutable global or shared variables?? What is the scope of such global variables? Zope wide? module wide? If global variable is not permitted, how can I approach thread programming in Zope? Without global variables, how can I control threads? Please kindly help Regards, Nicholas Lo begin:vcard n:Lo;Nicholas tel;pager:+852 7475 5330 tel;cell:+852 9225 0555 tel;fax:+852 2610 2225 tel;work:+852 7111 9353 x-mozilla-html:FALSE url:http://www.siliconcreation.com org:Silicon Creation version:2.1 email;internet:[EMAIL PROTECTED] title:Technical Director adr;quoted-printable:;;18/F=0D=0ATower 2=0D=0AMetroPlaza;Kwai Fong;;;Hong Kong x-mozilla-cpt:;0 fn:Nicholas Lo end:vcard
[Zope] threading cont ...
First, thanks to Dieter :) Well, I have written a simple test products, which I have attached to this message as a .tgz file. This product does vert little things. When B1 is pressed, two new threads will start, one will update column of the database table, while the other will prompt the current time. When B2 is pressed, all threads will terminate. When B3 is pressed, it will show the database table. For this product, I used the SybaseDAv2 to connect to the local Sybase 11.9.2. The problem is, I can always see the results by pressing B3. However, when I looked into the database using isql, nothing has ever changed :( What's wrong? I really have no clue. Please kindly help. Regards, Nicholas Lo boring.tgz begin:vcard n:Lo;Nicholas tel;pager:+852 7475 5330 tel;cell:+852 9225 0555 tel;fax:+852 2610 2225 tel;work:+852 7111 9353 x-mozilla-html:FALSE url:http://www.siliconcreation.com org:Silicon Creation version:2.1 email;internet:[EMAIL PROTECTED] title:Technical Director adr;quoted-printable:;;18/F=0D=0ATower 2=0D=0AMetroPlaza;Kwai Fong;;;Hong Kong x-mozilla-cpt:;0 fn:Nicholas Lo end:vcard