It's part of an importing app.  For each contact that the user tries
to import we need to check against the existing app for duplicates. 
We use a variety of checks including DoubleMetaphone and distance
calculations.  We wrote all the comparison scripts in actionscript and
they work very well except that we need all the contacts on the client
in order to compare each one against the pending import them.

Also, we use filtering and sorting on the client for the use to
quickly find contacts.  You need the entire collection to filter it
all by category etc..  We can probably move that to the server by
create separate calls for each filter, but once the contacts are
loaded actionscript works very quickly and thus it's more efficient to
do it on the client.

- Kevin

--- In [email protected], "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> That's outside my domain of knowledge.  Wouldn't hurt to try it.  I
> still don't know what you're planning on doing with 900 items in a
> single fetch though.
> 
>  
> 
> ________________________________
> 
> From: [email protected] [mailto:[EMAIL PROTECTED] On
> Behalf Of Kevin
> Sent: Tuesday, March 11, 2008 4:22 PM
> To: [email protected]
> Subject: [flexcoders] Re: Loading Large Data Set into Client "A script
> has executed..15 seconds" Error
> 
>  
> 
> Thanks. Would it help if I made all the properties in the ContactVO
> lazy? As I understand it that way I would only be pulling in the id's
> of the nested collections and not the full objects. Does that prevent
> flex from creating all the nested objects in the collections or does
> it still need to convert those arrayCollections even though it doesn't
> have the full objects yet?
> 
> - Kevin
> 
> --- In [email protected] <mailto:flexcoders%40yahoogroups.com>
> , "Alex Harui" <aharui@> wrote:
> >
> > All those nested array collections require conversion as well. You
> > would need to find a way to partially convert objects, which is a
> > planned feature, but not available yet.
> > 
> > 
> > 
> > The easiest answer is to not do a complete fill, and set a decent page
> > size.
> > 
> > 
> > 
> > ________________________________
> > 
> > From: [email protected] <mailto:flexcoders%40yahoogroups.com>
> [mailto:[email protected] <mailto:flexcoders%40yahoogroups.com>
> ] On
> > Behalf Of Kevin
> > Sent: Tuesday, March 11, 2008 2:28 PM
> > To: [email protected] <mailto:flexcoders%40yahoogroups.com> 
> > Subject: [flexcoders] Re: Loading Large Data Set into Client "A script
> > has executed..15 seconds" Error
> > 
> > 
> > 
> > I am loading POJO's from LCDS using the Hibernate Assembler. From
> > what I can tell that part of the equation takes about 10 - 15 sec.
> > (Which also seems long.) The object is fairly complex so that could
> > be some of the problem. Here is the paste of the properties and
> > collections nested in the object. Looking at this object, is there a
> > way to code around this problem? - Kevin
> > 
> > [Managed]
> > [RemoteClass(alias="com.onefoot.dbocl.vo.contacts.ContactVO")]
> > 
> > public class ContactVO extends RootObjectVO implements IValueObject
> > {
> > 
> > public var makePrivate : Boolean;
> > 
> > private var _prefix : String;
> > 
> > private var _firstName : String;
> > 
> > private var _lastName : String;
> > 
> > private var _alias : String;
> > 
> > private var _aliasEnabled : Boolean = false;
> > 
> > private var _title : String;
> > 
> > private var _company : String;
> > 
> > public var type : String;
> > 
> > [ArrayElementType("com.onefoot.dbocl.vo.contacts.PhoneVO")]
> > public var phones : ArrayCollection = new ArrayCollection();
> > 
> > [ArrayElementType("com.onefoot.dbocl.vo.contacts.EmailVO")]
> > public var emails : ArrayCollection = new ArrayCollection();
> > 
> > [ArrayElementType("com.onefoot.dbocl.vo.contacts.AddressVO")]
> > public var addresses : ArrayCollection = new ArrayCollection();
> > 
> > [ArrayElementType("com.onefoot.dbocl.vo.misc.ImageVO")]
> > public var images : ArrayCollection = new ArrayCollection();
> > 
> > [ArrayElementType("com.onefoot.dbocl.vo.contact.RelationshipVO")]
> > public var relationships : ArrayCollection = new ArrayCollection();
> > 
> > [ArrayElementType("com.onefoot.dbocl.vo.contact.CategoryVO")]
> > public var categories : ArrayCollection = new ArrayCollection();
> > 
> > //comes in as generic object from Java
> > public var customFields : *; 
> > 
> > public var additionalInfo : String = new String();
> > 
> > public var defaultEmail : EmailVO;
> > 
> > public var defaultAddress : AddressVO;
> > 
> > public var defaultPhone : PhoneVO;
> > 
> > private var _defaultImage : ImageVO;
> > 
> > }
> > 
> > --- In [email protected]
> <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com>
> > , "Alex Harui" <aharui@> wrote:
> > >
> > > If your resultFormat is 'object' and you're hitting a SOAP or other
> > > XML-based service, the XML must be parsed and converted into objects
> > > which can take time.
> > > 
> > > 
> > > 
> > > The real question is 900 objects times how many properties and
> > > sub-objects?
> > > 
> > > 
> > > 
> > > ________________________________
> > > 
> > > From: [email protected]
> <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com>
> > [mailto:[email protected]
> <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com>
> > ] On
> > > Behalf Of Kevin
> > > Sent: Tuesday, March 11, 2008 1:20 PM
> > > To: [email protected] <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com> 
> > > Subject: [flexcoders] Re: Loading Large Data Set into Client "A
> script
> > > has executed..15 seconds" Error
> > > 
> > > 
> > > 
> > > Thanks for the clarification. That helps. I think my resultFormat is
> > > 'object' but possibly, I don't understand it since this is all
> > > happening within LCDS. So here is what is happening and maybe you
> can
> > > help me figure out the solution:
> > > 
> > > 1) The client sets up a new DataService object and calls a fill on
> the
> > > destination.
> > > 
> > > 2) It appears from debugging that the fill comes in (looks like it
> > > took about 13 sec) and all the items are added to a cache:
> > > "13:33:43.545 Adding item to cache: contacts#:#3229 destination:
> > > contacts"
> > > 
> > > 3) Lastly, what looks to be about 19 seconds later, the following
> > > appears in the log and all the objects start tracing out in the
> > > debugger:
> > > 13:34:02.412 Result for contacts.fill(["contacts.all", []]) ->: [
> > > 
> > > The crash then happens about 2/3rd of the way into that process.
> > > 
> > > Since all of this is happening as part of the DataService fill, I am
> > > unclear as to how I can adjust this. My only other solution is to
> use
> > > paging and then continue to force load new pages of data. Ultimately
> > > I need all the object on the client so it would be nice if I could
> > > just call them all in one process. Any ideas.
> > > 
> > > Doesn't 900 objects seem a little small to timeout like this?
> > > 
> > > Thanks, 
> > > 
> > > - Kevin
> > > 
> > > --- In [email protected]
> <mailto:flexcoders%40yahoogroups.com> 
> > <mailto:flexcoders%40yahoogroups.com>
> > <mailto:flexcoders%40yahoogroups.com>
> > > , "Alex Harui" <aharui@> wrote:
> > > >
> > > > The player error msg still says 15 regardless of what you set.
> > > > 
> > > > 
> > > > 
> > > > It isn't the serialization or network transfer time that matters.
> > That
> > > > is asynchronous. What matters is the time to process the data once
> > the
> > > > request has arrived. Your resultFormat dictates what kind of
> > > conversion
> > > > has to happen and thus, how long it will take.
> > > > 
> > > > 
> > > > 
> > > > ________________________________
> > > > 
> > > > From: [email protected]
> <mailto:flexcoders%40yahoogroups.com> 
> > <mailto:flexcoders%40yahoogroups.com>
> > <mailto:flexcoders%40yahoogroups.com>
> > > [mailto:[email protected]
> <mailto:flexcoders%40yahoogroups.com> 
> > <mailto:flexcoders%40yahoogroups.com>
> > <mailto:flexcoders%40yahoogroups.com>
> > > ] On
> > > > Behalf Of Kevin
> > > > Sent: Tuesday, March 11, 2008 12:47 PM
> > > > To: [email protected]
> <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com>
> > <mailto:flexcoders%40yahoogroups.com> 
> > > > Subject: [flexcoders] Re: Loading Large Data Set into Client "A
> > script
> > > > has executed..15 seconds" Error
> > > > 
> > > > 
> > > > 
> > > > I looked at the docs on this and it says that the default value is
> > 60.
> > > > It's interesting that the error I get says the timeout period is
> 15
> > > > sec. I am wondering if this is a different timeout? Regardless,
> I'll
> > > > give it a shot.
> > > > 
> > > > How else do people load and serialize large DataSets?
> > > > 
> > > > - Kevin
> > > > 
> > > > --- In [email protected]
> <mailto:flexcoders%40yahoogroups.com> 
> > <mailto:flexcoders%40yahoogroups.com> 
> > > <mailto:flexcoders%40yahoogroups.com>
> > > <mailto:flexcoders%40yahoogroups.com>
> > > > , "Tracy Spratt" <tspratt@> wrote:
> > > > >
> > > > > On the Application object, you can set scriptTimeLimit. The
> > maximum
> > > > > value is 60 seconds, dang it.
> > > > > 
> > > > > Tracy
> > > > > 
> > > > > 
> > > > > 
> > > > > ________________________________
> > > > > 
> > > > > From: [email protected]
> <mailto:flexcoders%40yahoogroups.com> 
> > <mailto:flexcoders%40yahoogroups.com> 
> > > <mailto:flexcoders%40yahoogroups.com>
> > > <mailto:flexcoders%40yahoogroups.com>
> > > > [mailto:[email protected]
> <mailto:flexcoders%40yahoogroups.com> 
> > <mailto:flexcoders%40yahoogroups.com> 
> > > <mailto:flexcoders%40yahoogroups.com>
> > > <mailto:flexcoders%40yahoogroups.com>
> > > > ] On
> > > > > Behalf Of Kevin
> > > > > Sent: Tuesday, March 11, 2008 1:44 PM
> > > > > To: [email protected]
> <mailto:flexcoders%40yahoogroups.com> 
> > <mailto:flexcoders%40yahoogroups.com>
> > <mailto:flexcoders%40yahoogroups.com>
> > > <mailto:flexcoders%40yahoogroups.com> 
> > > > > Subject: [flexcoders] Loading Large Data Set into Client "A
> script
> > > has
> > > > > executed..15 seconds" Error
> > > > > 
> > > > > 
> > > > > 
> > > > > I am having a problem loading a large VO dataset into my client.
> > > There
> > > > > are only about 900 records at this point and from what I can
> guess
> > > the
> > > > > query takes about 5 - 6 seconds to return to the client.
> However,
> > > > > then as the data is serializing I can't make it through all the
> > data
> > > > > without getting a timeout error. 
> > > > > 
> > > > > Any suggestions on how to get around this. It seems like a
> rather
> > > > > small dataset to timeout like this. I know other's who are
> loading
> > > 60
> > > > > - 100K objects from servers in one call... I must be doing
> > something
> > > > > wrong.
> > > > > 
> > > > > Thanks for the help.
> > > > > 
> > > > > - Kevin
> > > > > 
> > > > > Error: Error #1502: A script has executed for longer than the
> > > default
> > > > > timeout period of 15 seconds.
> > > > > at
> > > > >
> > > >
> > >
> >
> mx.data::DataList/http://www.adobe.com/2006/flex/mx/internal::setSequenc
> <http://www.adobe.com/2006/flex/mx/internal::setSequenc> 
> > <http://www.adobe.com/2006/flex/mx/internal::setSequenc
> <http://www.adobe.com/2006/flex/mx/internal::setSequenc> > 
> > > <http://www.adobe.com/2006/flex/mx/internal::setSequenc
> <http://www.adobe.com/2006/flex/mx/internal::setSequenc> 
> > <http://www.adobe.com/2006/flex/mx/internal::setSequenc
> <http://www.adobe.com/2006/flex/mx/internal::setSequenc> > > 
> > > > <http://www.adobe.com/2006/flex/mx/internal::setSequenc
> <http://www.adobe.com/2006/flex/mx/internal::setSequenc> 
> > <http://www.adobe.com/2006/flex/mx/internal::setSequenc
> <http://www.adobe.com/2006/flex/mx/internal::setSequenc> > 
> > > <http://www.adobe.com/2006/flex/mx/internal::setSequenc
> <http://www.adobe.com/2006/flex/mx/internal::setSequenc> 
> > <http://www.adobe.com/2006/flex/mx/internal::setSequenc
> <http://www.adobe.com/2006/flex/mx/internal::setSequenc> > > > 
> > > > > eSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize> 
> > <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize> > 
> > > <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize> 
> > <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize> > > 
> > > > <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize> 
> > <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize> > 
> > > <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize> 
> > <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize
> <http://www.adobe.com/2006/flex/mx/internal::setSequenceSize> > > > > ()
> > > > > at
> > > > >
> > > >
> > >
> >
> mx.data::DataList/http://www.adobe.com/2006/flex/mx/internal::processSeq
> <http://www.adobe.com/2006/flex/mx/internal::processSeq> 
> > <http://www.adobe.com/2006/flex/mx/internal::processSeq
> <http://www.adobe.com/2006/flex/mx/internal::processSeq> > 
> > > <http://www.adobe.com/2006/flex/mx/internal::processSeq
> <http://www.adobe.com/2006/flex/mx/internal::processSeq> 
> > <http://www.adobe.com/2006/flex/mx/internal::processSeq
> <http://www.adobe.com/2006/flex/mx/internal::processSeq> > > 
> > > > <http://www.adobe.com/2006/flex/mx/internal::processSeq
> <http://www.adobe.com/2006/flex/mx/internal::processSeq> 
> > <http://www.adobe.com/2006/flex/mx/internal::processSeq
> <http://www.adobe.com/2006/flex/mx/internal::processSeq> > 
> > > <http://www.adobe.com/2006/flex/mx/internal::processSeq
> <http://www.adobe.com/2006/flex/mx/internal::processSeq> 
> > <http://www.adobe.com/2006/flex/mx/internal::processSeq
> <http://www.adobe.com/2006/flex/mx/internal::processSeq> > > > 
> > > > > uenceResult
> > > > >
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult> 
> > <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult> > 
> > > <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult> 
> > <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult> > > 
> > > > <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult> 
> > <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult> > 
> > > <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult> 
> > <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult
> <http://www.adobe.com/2006/flex/mx/internal::processSequenceResult> > >
> >
> > >
> > > > >
> > > >
> > >
> >
> ()[C:\depot\flex\branches\enterprise_corfu_b1\frameworks\projects\data\s
> > > > > rc\mx\data\DataList.as:2151]
> > > > > at
> > > > >
> > > >
> > >
> >
> DataListRequestResponder/result()[C:\depot\flex\branches\enterprise_corf
> > > > >
> > >
> u_b1\frameworks\projects\data\src\mx\data\ConcreteDataService.as:6779]
> > > > > at
> > > > >
> > > >
> > >
> >
> mx.rpc::AsyncRequest/acknowledge()[E:\dev\3.0.x\frameworks\projects\rpc\
> > > > > src\mx\rpc\AsyncRequest.as:74]
> > > > > at
> > > > >
> > > >
> > >
> >
> NetConnectionMessageResponder/resultHandler()[E:\dev\3.0.x\frameworks\pr
> > > > >
> ojects\rpc\src\mx\messaging\channels\NetConnectionChannel.as:469]
> > > > > at
> > > > >
> > > >
> > >
> >
> mx.messaging::MessageResponder/result()[E:\dev\3.0.x\frameworks\projects
> > > > > \rpc\src\mx\messaging\MessageResponder.as:199]
> > > > >
> > > >
> > >
> >
>


Reply via email to