[Red5devs] Flash Crashing
Eyon Land
ELand at PENSON.COM
Tue Sep 23 09:26:51 PDT 2008
Yes, I have a method on the client that I'm calling from the server
where I pass an ArrayList of ObjectMap(s)
conn.invoke("records",new Object[]{
query.values(),
query.getName(),
"ALL"});
Where query.values() is an ArrayList<ObjectMap>
And query.getName() is a string.
Should I synchronize on the connection?
Eyon
----------------------------------------------------------------------
Message: 1
Date: Tue, 23 Sep 2008 05:42:39 +1000
From: Daniel Rossi <spam at electroteque.org>
Subject: Re: [Red5devs] Red5devs Digest, Vol 33, Issue 29
To: red5devs at osflash.org
Message-ID: <C7C85B7A-29A9-483F-8D1B-9717EE7EA5D1 at electroteque.org>
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes
Whats the server / client code. Arte you trying to call a method on
the client ?
On 23/09/2008, at 1:37 AM, Eyon Land wrote:
> Daniel/Walter,
>
> Thanks for the detailed response.
>
> I've tried using the latest subversion code as of Thursday and get the
> same behavior. On the client side I've tried using both the latest
> Flash 9 player and the new Flash 10 beta player and also get the same
> access violation in IE (Unhandled exception at 0x3018d838 in
> iexplore.exe: 0xC0000005: Access violation reading location
> 0x00000074.)
> I have not tried Firefox yet.
>
> Here's the really weird part, when I run the Flex debugger (latest
> code
> from adobe) the flex debugger will crash but it will cause IE to hang
> and become unusable. If I leave my IE browser running and no longer
> responding on my machine, other users on other machines never have a
> problem and their IE never crashes. If I don't allow Flex to crash
> and
> hang though, they will continue to intermittently crash. (By the
> way my
> Flex IDE is running on the same machine as the Red5 server. In this
> case the server is the Red5 0.7.0 final and the machine has 2 quad
> cores
> running Windows XP Pro 32bit)
>
> I don't know what to make of this. I like your idea about reducing
> the
> amount of data. I was wondering whether I should be synchronizing on
> the connection to be threadsafe? Also, I thought I could try the
> Wowza
> server and see if I see the same crashing behavior.
>
>
>
> Eyon
>
>
>
>
> Message: 1
> Date: Sat, 20 Sep 2008 05:20:18 +1000
> From: Daniel Rossi <spam at electroteque.org>
> Subject: Re: [Red5devs] Flash crashing
> To: red5devs at osflash.org
> Message-ID: <ABE8EBD1-E212-48D0-97D8-9D5CC8C8639D at electroteque.org>
> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes
>
> Hi there was a problem with AMF calls with a version of red5 it was
> fixed in a later svn version. could it be that ? when a method call
> to a
> client happens it crashes the flash.
>
> On 20/09/2008, at 4:14 AM, Walter Tak wrote:
>
>> If Flash crashes then this might not be a Red5 issue but a Flash
>> issue.
>>
>> This might also depend on the version of the Flash player used and
>> even if it's uses as a stand-alone player, in Internet Explorer or
>> with Firefox.
>>
>> Furthermore ; does the problem occur with large amounts of data being
>> transmitted with one (1) call or will Flash crash when you are
>> sending
>
>> many small chunks of data ?
>>
>> Do understand that the Flash-player is not really a neat , memory
>> optimized piece of code. It's pretty easy to write a few lines of
>> code
>
>> and have Flash eat hundreds of megabytes of memory, resulting in a
>> crash or your OS becoming unstable since Flash is allocating memory.
>>
>> Red5 is packaging data into an AMF container which is , imho , not
>> really optimized for transmitting large chunks of data. While you are
>> sending 1k of data the actual AMF payload might be double, tripple or
>> tenfold of that, depending on the complexity of the structure you are
>> sending from
>> Red5 to
>> Flash and vice versa.
>>
>> I would , if I were you , create a simple loop on Red5 and start
>> sending out those 'large amount of data' you are talking about.
>> Increase the amount of data on each testrun. Start with 10.000 class
>> and send 100 bytes, increase it to 1kb , 10kb , 100kb etc.
>>
>> Have a careful look at your CPU load and memory usage on the client
>> (if you are running Windows add more columns to the task manager like
>> memory deltas and vm size). If you see a steadily increase there then
>> you know it's the Flash player that is the bottlneck. Either optimize
>> your dataflow and/or make sure your Flash-client releases variables.
>> The Flash-player's AS3 garbage collector
>> (GC) is pretty .. uncontrollable. AS2 is even worse. fyi.
>>
>> PS make sure you don't test this scenario on a PC with Red5 AND Flash
>> running or else you cannot see which app is responsible for the
>> problem
>> (Red5 or the client/browser) ; use another PC with low-end hardware
>> (cpu and
>> memory) to catch the problem asap ; if you test on high-end hardware
>> (quad core and 4gb) it might take a while before you notice the
>> crash.
>>
>> Walter
> STATEMENT OF CONFIDENTIALITY: This message and any attachments are
> intended solely for the person or entity to which it is addressed
> and may contain confidential or privileged information. If the
> recipient of this message is not the addressee or a person
> responsible for delivering the message to the addressee, such
> recipient is prohibited from reading or using this message in any
> way. If you have received this message in error, please call the
> sender of this message immediately and delete the message from any
> computer.
>
> _______________________________________________
> Red5devs mailing list
> Red5devs at osflash.org
> http://osflash.org/mailman/listinfo/red5devs_osflash.org
STATEMENT OF CONFIDENTIALITY: This message and any attachments are intended solely for the person or entity to which it is addressed and may contain confidential or privileged information. If the recipient of this message is not the addressee or a person responsible for delivering the message to the addressee, such recipient is prohibited from reading or using this message in any way. If you have received this message in error, please call the sender of this message immediately and delete the message from any computer.
More information about the Red5devs
mailing list