Error NetConnection Error al usar Actionscript RemoteObject con muchos datos

I have an air (4.5.1) mobile project that send an ArrayCollection to the server (Tomcat/BlazeDS)

The server manage the object and return a string containing the result (ok/error/etc)..

Everything worked fine, until:

I tried to send an ArrayCollection with length > 35000 (not sure border limit).

After sending the arraycollection the UI seems like frozen for a little time, and after that I got a FaultEvent Error NetConnection.Call.Failed: HTTP: Failed

The server however received the request, parsed it and returned the result string

So, because the program get the faultevent, I cannot be sure (from the client) that the request is finished correctly...

How can I fix it? and is this problem generated by the length of the arraycollection? Other ideas?

Muchas Gracias

preguntado el 09 de marzo de 12 a las 15:03

If screen is getting frozen, try to use compression and reduce amount of data that you are sending to server at once by doing partial requests. -

You can use a tool like ServiceCapture to get the size of the request too. At 35 thousand rows, it could be a large size. ( Like sending an mp3 over the wire). Perhaps the server is timing out before the request can finish. -

Why would you ever send over 35K rows?! Seems ridiculous to me. -

@J_A_X: Why does it? this program is like a cloud but when the client sync, it need to receive and send all the datas modified by all users, so having a lot of users, made a lot of updated/added rows.. Anyway 35k rows are about ~1-2Mb so this is not a bandwidth problem... -

1-2mb in one haul is enorme for a web application. It's quite possible that either the server fails what to do with it or the client completely stop after trying to parse and update all the data. There has to be a better, more efficient algorithm than this. I don't understand why one client needs to know about "all the data modified by all users". In all my years, I have never seen this need because it would be impossible to display all this information at the same time in a coherent way. -

1 Respuestas

This is an on going issue with Flex/Air/Flash. The problem you are running into is a defualt value for requestTimeout of 30 seconds. Even if you change the value in your remoteObject, it is not getting used correctly. There are MANY MANY documented bugs on adobe regarding this issue. Below is a link to a site that has collected some info about this problem from around the web. To date adobe has yet to fix the problem even though that claim they have in previous versions.

RemoteObject Issue

respondido 30 mar '12, 15:03

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.