[Seaside] ThreadPool with Seaside - how?

Sabine Manaa manaa.sabine at gmail.com
Thu Jul 27 07:42:49 UTC 2017


when the report generation is invoked, the session is alive and I have a
long session time.
So, it is unlikely that the session will expire.
If it does expire nevertheless, the user will not notice it (because he is
logged out) and I will stop report generation if the session is not
available.

Ramon, I tested your suggestion and with the session passed into the fork
with the local variable, it works.

I was mislead by the method >>queueWorkAndExpireIn:session:

This works
| theSession |
theSession := self session.
[ theSession dummyMethod ] queueWorkAndExpireIn: 25 seconds session: self
session ]

and this works too:
| theSession |
theSession := self session.
[ theSession dummyMethod2 ] queueWork ]);

==>I don't understand for what the session parameter in
>>queueWorkAndExpireIn:session: is used.

But I can also use queueWork.

This/the smalltalk side seems to work all fine now with the ThreadPool.
Thank you for this!

I also use an external program to
* merge multiple  PDFs into one
* and to generate pngs from pdfs for the preview
(https://pdfbox.apache.org).

The remaining problem is, that I have many pdfbox calls which create a high
load on the machine...
:-)




--
View this message in context: http://forum.world.st/ThreadPool-with-Seaside-how-tp4956812p4957069.html
Sent from the Seaside General mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/seaside/attachments/20170727/dde021a5/attachment.html>


More information about the seaside mailing list