flex-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Frédéric THOMAS <webdoubl...@hotmail.com>
Subject RE: A script has executed for longer than ....
Date Thu, 25 Jun 2015 15:45:19 GMT
> Can I implement workers if I use Flex 3 with 4.13 SDK?

If you want to use https://github.com/doublefx/easyWorker, the minimum is Apache Flex 4.13.0
FP 11.5 AIR 3.5, for Flex 3, I guess yes too as the only added class was in core IIRC

Frédéric THOMAS


----------------------------------------
> From: markzolotoy@gmail.com
> Date: Thu, 25 Jun 2015 15:35:59 +0000
> Subject: Re: A script has executed for longer than ....
> To: users@flex.apache.org
>
> Can I implement workers if I use Flex 3 with 4.13 SDK?
>
> On Thu, Jun 25, 2015 at 10:29 AM Frédéric THOMAS <webdoublefx@hotmail.com>
> wrote:
>
>>> In the threadCompleteHandler function?
>>
>> Worker and Pseudo-Worker are low level API from which you can certainly
>> achieve your goal, if you prefer to use an easier Thread like API, you can
>> download an compile https://github.com/doublefx/easyWorker
>>
>> Using it, I would probably create a Thread lib containing only the classes
>> an functions you need, instantiate it at application / module startup or
>> even create a pool of Threads and use it whenever you will receive your
>> data.
>>
>> Frédéric THOMAS
>>
>>
>> ----------------------------------------
>>> From: markzolotoy@gmail.com
>>> Date: Thu, 25 Jun 2015 15:17:43 +0000
>>> Subject: Re: A script has executed for longer than ....
>>> To: users@flex.apache.org
>>>
>>> In the threadCompleteHandler function?
>>>
>>> On Thu, Jun 25, 2015 at 10:03 AM Alex Harui <aharui@adobe.com> wrote:
>>>
>>>> In the callback function. The callback function would probably process
>>>> some node and update variables so when it gets called again it knows to
>>>> process a different node.
>>>>
>>>> On 6/25/15, 7:46 AM, "mark goldin" <markzolotoy@gmail.com> wrote:
>>>>
>>>>>I see. Alex, I am looking into the article you have provided. Just a
>> quick
>>>>>question. Where do I put my code to process xml? Because you code is
>>>>>rendering screen I am not sure how to adapt your code to my needs.
>>>>>
>>>>>On Thu, Jun 25, 2015 at 9:33 AM Alex Harui <aharui@adobe.com> wrote:
>>>>>
>>>>>> That sounds like pseudo-threading. You would have to break it up
in
>> one
>>>>>> frame, handle chunks in separate frames, and assemble in the last
>> frame.
>>>>>> With pseudo-threading, you don’t have to break it up and lose
>> parenting
>>>>>> and re-assemble, you just keep some state around, and process chunks
>> in
>>>>>> each frame.
>>>>>>
>>>>>> -Alex
>>>>>>
>>>>>> On 6/25/15, 7:20 AM, "mark goldin" <markzolotoy@gmail.com>
wrote:
>>>>>>
>>>>>>>What if I break xml into pieces for separate processing and then
put
>>>>>>them
>>>>>>>together into one final xml?
>>>>>>>
>>>>>>>On Thu, Jun 25, 2015 at 9:12 AM Alex Harui <aharui@adobe.com>
wrote:
>>>>>>>
>>>>>>>> Well, xml is terribly slow. If you can server-side process
it into
>>>>>>>> something else (RemoteObject/AMF to ValueObjects is considered
to be
>>>>>>the
>>>>>>>> fastest, ObjectProxy is also slow, JSON might be fast) then
you
>>>>>>might be
>>>>>>>> able to process all of the data in 60 seconds in ActionScript.
>>>>>>However,
>>>>>>>> if one of your customers happens to be running a virus scan
or some
>>>>>>>>other
>>>>>>>> heavy job at the same time, you might find it exceeds 60
seconds
>>>>>>anyway.
>>>>>>>>
>>>>>>>> Workers or Pseudo-threading [1] might help you. Also having
the
>>>>>>server
>>>>>>>>do
>>>>>>>> the processing and send you the results.
>>>>>>>>
>>>>>>>> -Alex
>>>>>>>>
>>>>>>>> [1]
>>>>>> http://blogs.adobe.com/aharui/2008/01/threads_in_actionscript_3.html
>>>>>>>>
>>>>>>>> On 6/25/15, 6:52 AM, "mark goldin" <markzolotoy@gmail.com>
wrote:
>>>>>>>>
>>>>>>>>>I have a large xml data that UI needs to process. I am
getting the
>>>>>>>>above
>>>>>>>>>message about timing out. Not sure I can break my function
into
>>>>>>smaller
>>>>>>>>>pieces. Any other idea?
>>>>>>>>>
>>>>>>>>>Thanks
>>>>>>>>
>>>>>>>>
>>>>>>
>>>>>>
>>>>
>>>>
>>
 		 	   		  
Mime
View raw message