[flexcoders] Re: What does 'DataList with no references found in the index mean'?
I'm trying to keep this topic alive because I have not been able to work around it. Am I really the only one who has ever seen this? Any hints on where this might be coming from at all? AT this point I'll take random guesses even! :) --- In flexcoders@yahoogroups.com, billy_d_white [EMAIL PROTECTED] wrote: I'm getting the following error when I try to re-fill an ArrayCollection using LCDS 2.5(FDS) + Cairngorm 2.2.1 + Java Backend: Error: DataList with no references found in the index! at mx.data::ConcreteDataService/mx.data:ConcreteDataService::getDataLists()\ [C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as:4\ 324] at mx.data::ConcreteDataService/mx.data:ConcreteDataService::isItemReferenc\ ed()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.\ as:3900] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseDataList()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Concre\ teDataService.as:2895] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseAssociations()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Co\ ncreteDataService.as:2839] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseDataList()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Concre\ teDataService.as:2898] at mx.data::ConcreteDataService/mx.data:ConcreteDataService::internalFill()\ [C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as:4\ 496] at ()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as\ :853] at mx.data::ConcreteDataService/fill()[C:\dev\enterprise_borneo_rc\framewor\ ks\mx\data\ConcreteDataService.as:869] at mx.data.mxml::DataService/fill()[C:\dev\enterprise_borneo_rc\frameworks\\ mx\data\mxml\DataService.as:526] Does anyone know what this means? I've never seen it before and there is no mention of it anywhere. Here's the background: - I'm getting this when I execute a fill to get a set of managed objects from my Java server running LCDS 2.5. However, I ONLY get this error after I've updated a one of the managed objects and then refill that ArrayCollection with different objects. In this case, I've got a set of Report objects that are related to a single Student object. When I click a Student from the list, my code retrieves the related set of Report objects using a fill with parameters and I display the resulting Report objects. Everything is fine until I update one of those Report objects and commit the changes back to the server (via LCDS). After that, when I click a different Student to retrieve their Reports (using a fill which overwrites the ArrayCollection's previous fill), I get this error. - This is all coming about because I'm have tons of problems with mismatched references. When I load my objects in FDS/LCDS, everything is fine. But as I make changes and/or retrieve new fills, I'm finding that the references between my objects are becoming fractured. I implemented Jeff Vroom's UID solution to try to fix this and I think it worked, but now I'm hitting this error. Any help is appreciated. Bill
[flexcoders] Re: What does 'DataList with no references found in the index mean'?
Anyone? Could this be something new in LCDS? I do not recall seeing the 'enterprise_borneo_rc' before. Jeff, you're the FDS expert. Any ideas? --- In flexcoders@yahoogroups.com, billy_d_white [EMAIL PROTECTED] wrote: I'm getting the following error when I try to re-fill an ArrayCollection using LCDS 2.5(FDS) + Cairngorm 2.2.1 + Java Backend: Error: DataList with no references found in the index! at mx.data::ConcreteDataService/mx.data:ConcreteDataService::getDataLists()\ [C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as:4\ 324] at mx.data::ConcreteDataService/mx.data:ConcreteDataService::isItemReferenc\ ed()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.\ as:3900] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseDataList()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Concre\ teDataService.as:2895] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseAssociations()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Co\ ncreteDataService.as:2839] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseDataList()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Concre\ teDataService.as:2898] at mx.data::ConcreteDataService/mx.data:ConcreteDataService::internalFill()\ [C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as:4\ 496] at ()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as\ :853] at mx.data::ConcreteDataService/fill()[C:\dev\enterprise_borneo_rc\framewor\ ks\mx\data\ConcreteDataService.as:869] at mx.data.mxml::DataService/fill()[C:\dev\enterprise_borneo_rc\frameworks\\ mx\data\mxml\DataService.as:526] Does anyone know what this means? I've never seen it before and there is no mention of it anywhere. Here's the background: - I'm getting this when I execute a fill to get a set of managed objects from my Java server running LCDS 2.5. However, I ONLY get this error after I've updated a one of the managed objects and then refill that ArrayCollection with different objects. In this case, I've got a set of Report objects that are related to a single Student object. When I click a Student from the list, my code retrieves the related set of Report objects using a fill with parameters and I display the resulting Report objects. Everything is fine until I update one of those Report objects and commit the changes back to the server (via LCDS). After that, when I click a different Student to retrieve their Reports (using a fill which overwrites the ArrayCollection's previous fill), I get this error. - This is all coming about because I'm have tons of problems with mismatched references. When I load my objects in FDS/LCDS, everything is fine. But as I make changes and/or retrieve new fills, I'm finding that the references between my objects are becoming fractured. I implemented Jeff Vroom's UID solution to try to fix this and I think it worked, but now I'm hitting this error. Any help is appreciated. Bill
[flexcoders] What does 'DataList with no references found in the index mean'?
I'm getting the following error when I try to re-fill an ArrayCollection using LCDS 2.5(FDS) + Cairngorm 2.2.1 + Java Backend: Error: DataList with no references found in the index! at mx.data::ConcreteDataService/mx.data:ConcreteDataService::getDataLists()\ [C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as:4\ 324] at mx.data::ConcreteDataService/mx.data:ConcreteDataService::isItemReferenc\ ed()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.\ as:3900] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseDataList()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Concre\ teDataService.as:2895] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseAssociations()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Co\ ncreteDataService.as:2839] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal:\ :releaseDataList()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\Concre\ teDataService.as:2898] at mx.data::ConcreteDataService/mx.data:ConcreteDataService::internalFill()\ [C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as:4\ 496] at ()[C:\dev\enterprise_borneo_rc\frameworks\mx\data\ConcreteDataService.as\ :853] at mx.data::ConcreteDataService/fill()[C:\dev\enterprise_borneo_rc\framewor\ ks\mx\data\ConcreteDataService.as:869] at mx.data.mxml::DataService/fill()[C:\dev\enterprise_borneo_rc\frameworks\\ mx\data\mxml\DataService.as:526] Does anyone know what this means? I've never seen it before and there is no mention of it anywhere. Here's the background: - I'm getting this when I execute a fill to get a set of managed objects from my Java server running LCDS 2.5. However, I ONLY get this error after I've updated a one of the managed objects and then refill that ArrayCollection with different objects. In this case, I've got a set of Report objects that are related to a single Student object. When I click a Student from the list, my code retrieves the related set of Report objects using a fill with parameters and I display the resulting Report objects. Everything is fine until I update one of those Report objects and commit the changes back to the server (via LCDS). After that, when I click a different Student to retrieve their Reports (using a fill which overwrites the ArrayCollection's previous fill), I get this error. - This is all coming about because I'm have tons of problems with mismatched references. When I load my objects in FDS/LCDS, everything is fine. But as I make changes and/or retrieve new fills, I'm finding that the references between my objects are becoming fractured. I implemented Jeff Vroom's UID solution to try to fix this and I think it worked, but now I'm hitting this error. Any help is appreciated. Bill
[flexcoders] Re: Generate PDF
You should be able to add a function in JavaScript that opens the popup window in the html template that wraps the flash code. Then you can call that function from within the flash/flex code using the ExternalInterface API or the navigatetoURL function. Check out the Flex 2 Developer's Guide in the Help section of the flex docs. There is a section called Accessing JavaScript functions from Flex that will explain the details. -Bill --- In flexcoders@yahoogroups.com, Eduardo Dias [EMAIL PROTECTED] wrote: Hi, I'm doing a http call to the server and the response is a input stream of a PDF file, i'm not using Livecycle Data Services 2.5. How i can take this file and open in a different browser window? Regards, Eduardo Dias
[flexcoders] Re: PDF Preview
I've used the iFrame solution and it works surprisingly well. Basically you have to modify the html template to include with the required javascript functions and then you use the IFrame mxml component to display the PDF. I just generate the PDF on the serverside (using iText) and then display the results in the iFrame. It works great in both IE and Firefox. The only problem I've come across is that when I do not have enough information to generate a PDF, I send back an HTML page with an error and sometimes that HTML page does not show up correctly in Firefox. However, it could be something I'm just doing wrong so I would say to give it is a shot since the PDF displays correctly in both IE and Firefox. -Bill --- In [EMAIL PROTECTED], Kevin [EMAIL PROTECTED] wrote: I know this has been asked before, but I haven't seen many solutions posted. Is there a way to preview a PDF in Flex? As far as I can tell there are two possible options: 1) Preview the PDF in an iFrame (Has anyone tried this? Does it work cross platform?) 2) Convert the PDF to SWF load in Flex. (Is there existing server code for this conversion? This seems rather processor intensive for large PDF's) I am still struggling with printable document creation using Flex. Has anyone heard whether Adobe is interested in building a basic Print Preview Component (similar to the Acrobat Reader Plugin) for Flex? Seems like this would be a valuable asset to the Flex community. - Kevin
[flexcoders] Is Cairngorm 2.2 available yet?
Has Cairngorm 2.2 been released yet? I saw that they beta was available over on the cairngorm-devel group a few months ago but there has been no discussion of it since and there is nothing about it on Adobe Labs. I posted on that groups but it looks like that group does not have much traffic. Anyone know if this has been/will be released and where to find out more about it?
[flexcoders] Re: DateField Bug
I ran into this exact same issue the other day. I have a form with a datefield/datepicker component and I found that if it is set to, say today's date, and you then expand the date chooser and reselect the same date, it comes back with NaN/NaN/NaN as the selected date. Anyone else seen this or know what might be causing it? --- In flexcoders@yahoogroups.com, Chad Callahan [EMAIL PROTECTED] wrote: When selecting the date that the DateField object is already set to, the DateField text display becomes empty. Does selecting the same date as is already selected cause the new selected date to become null? Is there a property I can set to disable this feature? CHAD CALLAHAN PROGRAMMER T8DESIGN.COM | P 319.266.7574 - x195 | 877.T8IDEAS | F 888.290.4675 This e-mail, including attachments, is covered by the Electronic Communications Privacy Act, 18 U.S.C. 2510-2521, is confidential, and may be legally privileged. If you are not the intended recipient, you are hereby notified that any retention, dissemination, distribution, or copying of this communication is strictly prohibited. Please reply to the sender that you have received the message in error, and then please delete it. Thank you.
[flexcoders] Re: Developing Rich Clients, Source Code?
Maybe you can email Steve or Alistar directly and ask them. I've found that they are normally pretty responsive to emails. Also, their previous book Reality J2EE is fantastic as well. It is a little bit older and focuses on build Flash (prior to Flex) UIs with J2EE on the backend, but the book is fanatastic because it doubles as a development planning handbook. They cover things like client interviews, iterative development and spike spolutions which are a great way to work! Highly recommended! - Bill --- In flexcoders@yahoogroups.com, lostinrecursion [EMAIL PROTECTED] wrote: Hi all, I had the pleasure of picking up the book, Developing Rich Clients with Macromedia Flex, by our community brethren Steven Webster and Alistair McLeod. At first I was hesitant to pick it up because of the fact it was Flex 1.5 and I am a Flex 2 convert. But, I HIGHLY recommend it to anyone who wants to get a ground running start on their development. Would anyone know where I can find the source code for this book? Originally it was available on the iteration::two website. But that site has been reporting an Apache server error for a while. Does anyone have it that could be kind enough to post it here so that I could use it along with my studies? Thanks -Kenny/LIR
[flexcoders] Re: FDS with Java Question: Why is it grouping requests?
I think I'm just not closing or committing something correctly because it looks like I'm supposed to do something else besides revertChanges to 'clear-out' the previous (failed) request. I've added this change and it did remove part of the problem. But now I'm in a sort of limbo. Take for example a deletion of a course subject using deleteItem(). Previously, I would delete 'Art' which should cause an error. It works fine and returns the correct error code from the serverside. Then I would delete 'Science' but it would still be trying to delete 'Art' on the backend. Using revertChanges() fixed this issue. However, now I'm getting 2 fault events on the clientside for each deleteItem() call after the first call. So I can delete 'Art' and things work great (it shows me the serverside error code when the delete fails.) But when I try to delete 'Science', it works correctly on the backend (trying to delete Science and returning the error code), but on the client side, I get TWO fault events. Oddly enough, the tokens contained inside both of these FaultEvents have the correct server side error code (Cannot delete Science) but the body property of the first token still has a reference to the 'Art' object, while the second one has the 'Science' object in the body property. Even more interesting, from this point on, I will always get 2 faultEvents and no more. It is not adding a return event for each call, but rather it is treating them like a stack of 2 with the previous event being removed and the latest even being added. I always get 2 with the first having the previous subject value in the body property. Any ideas? --- In flexcoders@yahoogroups.com, Jeff Vroom [EMAIL PROTECTED] wrote: When you get the fault for the first delete, you probably just need to call revertChanges - either for all changes or just that item. After any fault, all messages you commit as part of that batch get reverted - i.e. put back into the uncommitted list. When you revert them, we'll undo those changes - i.e. recreate the deleted item. This is necessary to keep the client's view of the managed state in sync with the server's view. Jeff From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of billy_d_white Sent: Monday, February 26, 2007 9:52 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] FDS with Java Question: Why is it grouping requests? Maybe Vroom or one of you other FDS experts can tell my what I'm doing wrong : I'm using Cairngorm with a Java/Spring backend. I'm using autocommit and autosync enabled and when I perform a deleteItem which I want to fail, it calls my Java assembler which attempts the deletion and fails. I customize the error message and send it back as a MessageException. So far so good. However, if I then try another deletion, the request is sent to the assembler with an array of inside the DataMessage and this array contains the previous delete request as well as the new delete request. Apparently it is trying to batch the multiple requests since the previous one failed. (These are stored in that _token_chain_ property of the request) How do I avoid this and make each deletion request atomic so it will not attempt to execute the previous (failed) request? Do I need to re-write the service call on the client to use the manual commit() call or something like that? Any
[flexcoders] Re: Cairngorm FDS Sample
Jason, Two questions/comments: 1. Are you not creating AsyncToken references from your calls to the ds.createItem and ds.deleteItem? So far you have pretty much what I have, but things get tricky for me when I get the result or fault callbacks. If I have a fault, it gets called 2x for some reason. 2. Regarding the updates to a specific item: Are you not keen on the solution of just pulling the specific item to be updated from the managed collection and updating it and then letting FDS take care of the backend syncronization? Or have you tried a call to ds.getItem() and then modified the resulting object returned after the user has edit it? I'm just making sure you knew that it was possible, although it does not quite follow them same pattern as createItem and deleteItem.I can post code samples if you need them. thanks Bill --- In flexcoders@yahoogroups.com, [EMAIL PROTECTED] wrote: Heya, I was looking for one too and there doesn't seem to be one. I'm able to currently encapsulate Create/Read/Delete actions in commands, but I haven't yet found a reliable way to encapsulate Updates in a command. Everything else works very nicely. Example of fill: var ev:ProductEvent = new ProductEvent(ProductEvent.FIND_ALL); ev.collection = model.products; CairngormEventDispatcher.getInstance().dispatchEvent(ev); Execute: public function execute(event:CairngormEvent):void { var ds:DataSource = new DataSource(productHome); var ev:ProductEvent = event as ProductEvent; ds.fill(ev.collection); // event is carrying a reference to an arbitrary collection contained in your model } Example of createItem: var ev:ProductEvent = new ProductEvent(ProductEvent.INSERT); ev.product = someProduct; CairngormEventDispatcher.getInstance().dispatchEvent(ev); Execute: public function execute(event:CairngormEvent):void { var ds:DataSource = new DataSource(productHome); var ev:ProductEvent = event as ProductEvent; ds.createItem(ev.product); // event is carrying a reference to a product bean } Example of deleteItem: var ev:ProductEvent = new ProductEvent(ProductEvent.DELETE); ev.product = someProduct; CairngormEventDispatcher.getInstance().dispatchEvent(ev); Execute: public function execute(event:CairngormEvent):void { var ds:DataSource = new DataSource(productHome); var ev:ProductEvent = event as ProductEvent; ds.deleteItem(ev.product); // event is carrying a reference to a product bean } When you find a good way to handle updates, you let me know ;) Currently there is no fine-grained approach to updating only one specific record manually, which kinda sucks. Jay Proulx [EMAIL PROTECTED] From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of auddaraj Sent: February 26, 2007 2:54 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Cairngorm FDS Sample Hi, We are planning to use Cairngorm in our flex project which uses FDS. I tried looking around for samples that use FDS(not remoting) but no luck. From www.cairngormdocs.org I am able to find number of sample that use webservices, remoting etc.. Can anyone suggest a sample Cairngorm app that uses FDS(Data services). I am trying to see how FDS methods like fill etc. fit into cairngorm model Thanks, ANAND.
[flexcoders] FDS with Java Question: Why is it grouping requests?
Maybe Vroom or one of you other FDS experts can tell my what I'm doing wrong : I'm using Cairngorm with a Java/Spring backend. I'm using autocommit and autosync enabled and when I perform a deleteItem which I want to fail, it calls my Java assembler which attempts the deletion and fails. I customize the error message and send it back as a MessageException. So far so good. However, if I then try another deletion, the request is sent to the assembler with an array of inside the DataMessage and this array contains the previous delete request as well as the new delete request. Apparently it is trying to batch the multiple requests since the previous one failed. (These are stored in that _token_chain_ property of the request) How do I avoid this and make each deletion request atomic so it will not attempt to execute the previous (failed) request? Do I need to re-write the service call on the client to use the manual commit() call or something like that? Any
[flexcoders] Re: FDS with Java Question: Why is it grouping requests?
Here is a little more detail from my log files This is the first delete request: body = [ Flex Message (flex.data.messages.DataMessage) operation = delete id = ASObject(2486357){subjectid=96} clientId = 23F55D89-4178-1760-96E1-FF423E27F73C correlationId = ABF2677D-C583-C966-5B13-FF432FB054B8 destination = subject.destination messageId = 35CF2AAC-D46C-7E0D-6DFB-FF432FA9A88E timestamp = 1172513697724 timeToLive = 0 body = SUBJECT[subjectid:96,subjectname:Art] hdr(DSEndpoint) = my-rtmp, Flex Message (flex.data.messages.UpdateCollectionMessage) operation = update_collection id = null clientId = null correlationId = ABF2677D-C583-C966-5B13-FF432FB054B8 destination = subject.destination messageId = 47C26DFC-113C-824B-F6AE-FF432FA86D76 timestamp = 0 timeToLive = 0 body = [ [EMAIL PROTECTED](12937429){subjectid=96}] ] collectionId = [ ] replace = false updateMode = client_update ] And this is the second one: As you can see, there are now 2 objects queued for deletion: body = [ Flex Message (flex.data.messages.DataMessage) operation = delete id = ASObject(32142860){subjectid=96} clientId = 23F55D89-4178-1760-96E1-FF423E27F73C correlationId = 2B16A7AB-6386-A38D-8C3E-FF43ADE3146B destination = subject.destination messageId = 35CF2AAC-D46C-7E0D-6DFB-FF432FA9A88E timestamp = 1172513730039 timeToLive = 0 body = SUBJECT[subjectid:96,subjectname:Art] hdr(DSEndpoint) = my-rtmp, Flex Message (flex.data.messages.DataMessage) operation = delete id = ASObject(32250654){subjectid=112} clientId = 23F55D89-4178-1760-96E1-FF423E27F73C correlationId = 2B16A7AB-6386-A38D-8C3E-FF43ADE3146B destination = subject.destination messageId = 7C9CA1BB-B404-37C4-A3B2-FF43ADE3748E timestamp = 0 timeToLive = 0 body = SUBJECT[subjectid:112,subjectname:Computer Science], Flex Message (flex.data.messages.UpdateCollectionMessage) operation = update_collection id = null clientId = null correlationId = 2B16A7AB-6386-A38D-8C3E-FF43ADE3146B destination = subject.destination messageId = 47C26DFC-113C-824B-F6AE-FF432FA86D76 timestamp = 0 timeToLive = 0 body = [ [EMAIL PROTECTED](32016377){subjectid=96}], [EMAIL PROTECTED](20392168){subjectid=112}] ] collectionId = [ ] replace = false updateMode = client_update ] Any ideas on how to clear that previous delete request (which failed on purpose)? Thanks --- In flexcoders@yahoogroups.com, billy_d_white [EMAIL PROTECTED] wrote: Maybe Vroom or one of you other FDS experts can tell my what I'm doing wrong : I'm using Cairngorm with a Java/Spring backend. I'm using autocommit and autosync enabled and when I perform a deleteItem which I want to fail, it calls my Java assembler which attempts the deletion and fails. I customize the error message and send it back as a MessageException. So far so good. However, if I then try another deletion, the request is sent to the assembler with an array of inside the DataMessage and this array contains the previous delete request as well as the new delete request. Apparently it is trying to batch the multiple requests since the previous one failed. (These are stored in that _token_chain_ property of the request) How do I avoid this and make each deletion request atomic so it will not attempt to execute the previous (failed) request? Do I need to re-write the service call on the client to use the manual commit() call or something like that? Any
[flexcoders] Re: FDS with Java Question: Why is it grouping requests?
Excellent! Thanks Dimitrios, that was the missing piece. Now I just have figure out why my 'fault' method is getting called twice for each call after the initial call. When I delete an item (which should fail), it calls the fault method in my responder. Then, for every subsequent delete call, my fault method gets called 2x. Strange. Thanks --- In flexcoders@yahoogroups.com, Dimitrios Gianninas [EMAIL PROTECTED] wrote: Maybe u need to call revertchanges() after the fault occurs to put everything back the way it was and then allow the user to delete the other record of his choosing. Dimitrios Gianninas RIA Developer Optimal Payments Inc. From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of billy_d_white Sent: Monday, February 26, 2007 12:52 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] FDS with Java Question: Why is it grouping requests? Maybe Vroom or one of you other FDS experts can tell my what I'm doing wrong : I'm using Cairngorm with a Java/Spring backend. I'm using autocommit and autosync enabled and when I perform a deleteItem which I want to fail, it calls my Java assembler which attempts the deletion and fails. I customize the error message and send it back as a MessageException. So far so good. However, if I then try another deletion, the request is sent to the assembler with an array of inside the DataMessage and this array contains the previous delete request as well as the new delete request. Apparently it is trying to batch the multiple requests since the previous one failed. (These are stored in that _token_chain_ property of the request) How do I avoid this and make each deletion request atomic so it will not attempt to execute the previous (failed) request? Do I need to re-write the service call on the client to use the manual commit() call or something like that? Any -- WARNING --- This electronic message and its attachments may contain confidential, proprietary or legally privileged information, which is solely for the use of the intended recipient. No privilege or other rights are waived by any unintended transmission or unauthorized retransmission of this message. If you are not the intended recipient of this message, or if you have received it in error, you should immediately stop reading this message and delete it and all attachments from your system. The reading, distribution, copying or other use of this message or its attachments by unintended recipients is unauthorized and may be unlawful. If you have received this e-mail in error, please notify the sender. AVIS IMPORTANT -- Ce message électronique et ses pièces jointes peuvent contenir des renseignements confidentiels, exclusifs ou légalement privilégiés destinés au seul usage du destinataire visé. L'expéditeur original ne renonce à aucun privilège ou à aucun autre droit si le présent message a été transmis involontairement ou s'il est retransmis sans son autorisation. Si vous n'êtes pas le destinataire visé du présent message ou si vous l'avez reçu par erreur, veuillez cesser immédiatement de le lire et le supprimer, ainsi que toutes ses pièces jointes, de votre système. La lecture, la distribution, la copie ou tout autre usage du présent message ou de ses pièces jointes par des personnes autres que le destinataire visé ne sont pas autorisés et pourraient être illégaux. Si vous avez reçu ce courrier électronique par erreur, veuillez en aviser l'expéditeur.
[flexcoders] Re: Cairngorm FDS Sample
So far I'm finding that using FDS mixed with Cairngorm is pretty difficult. 1. When I define my services in the services.xml file, if I specify 'autoSyncEnabled' in the XML declaration, it throws a null pointer exception. It looks to me like things are getting initialized out of order. 2. I've had to specify fault handlers in the services.xml file if you want to user 'fault' attributes in the service declaration tags. If I do not do this, then some errors do not get handled at all, even if I have a fault handler method declared correctly on my responder (ie my calling command) 3. Many of the solutions I read about on this forum that show how to handle calls to the backend in FDS are not easily applied to a Cairngorm structure. For example, it is hard to call service.revertChanges in my fault routine because my fault handler method is in my command object and the service call is made in my delegate object. I have to create a reference to the service using the ServiceLocator solely to call revertChanges in the event of a fault. Anyone else experience these problems using FDS and Cairngorm together? If not, I'd love to see some examples showing me what I'm doing wrong. Thanks --- In flexcoders@yahoogroups.com, auddaraj [EMAIL PROTECTED] wrote: Thanks for getting back posting your sample, Jeff. Yes Cairngorm store uses remoteobject which requires FDS, however they don't make you data management services. I would be intersted if any one might have any tips or sample app using data management services with Cairngorm. --- In flexcoders@yahoogroups.com, Jeffry Houser jeff@ wrote: I thought that any use of RemoteObject was accessing Flex Data Services (or a ColdFusion server). The Cairngorm Store 2.1 uses RemoteObject and therefore must be using Flex Data Services. I also converted the Cairngorm Store to work with a CF backend if anyone is interested, download are more details are here: http://www.jeffryhouser.com/index.cfm/2007/2/19/Learning-Cairngorm- Part-3 . At 02:53 PM 2/26/2007, you wrote: Hi, We are planning to use Cairngorm in our flex project which uses FDS. I tried looking around for samples that use FDS(not remoting) but no luck. From www.cairngormdocs.org I am able to find number of sample that use webservices, remoting etc.. Can anyone suggest a sample Cairngorm app that uses FDS(Data services). I am trying to see how FDS methods like fill etc. fit into cairngorm model Thanks, ANAND. -- Jeffry Houser, Software Developer, Writer, Songwriter, Recording Engineer AIM: Reboog711 | Phone: 1-203-379-0773 -- My Company: http://www.dot-com-it.com My Podcast: http://www.theflexshow.com My Blog: http://www.jeffryhouser.com Connecticut Macromedia User Group: http://www.ctmug.com
[flexcoders] Re: FDS and Cairngorm / Individual Item Updates
I think the updates should take care of themselves. In my app (which uses Cairngorm, FDS, Java, Hibernate, Spring) I have all my actionscript domain objects on the flex side declared with the [Managed] and [RemoteClass] tags. So if you call the fill method to populate a collection, you can then take any object from that collection and update its properties. Then FDS will figure out automatically that the object has been updated and make the call to the server. In my case with Java, I've got an Assembler and FDS willc all the updateItem method anytime I edit an object in that collection. So when I have an form, I create the fields on the form, then populate them with the value of the object (from the filled collection) that is being edited. When the user hits the 'save' button, I copy the values back into the object that was selected for editing, at which point the call to the updateItem method on the backend occurs automatically. :) --- In flexcoders@yahoogroups.com, [EMAIL PROTECTED] wrote: Hey All, I'm having an issue finding a best-practice approach for CRUD operations with FDS. Create/Read/Delete are easy, I'm having a problem with updates. I can easily encapsulate CRD's in my Commands, but there doesn't seem to be an option to explicitly commit only a single record with FDS. In a non-cairngorm application, this is pretty easy, I can create a record, then call ds.createItem(), update it and then ds.commit(). The DataService object is local to the interface that is managing the record. No problem, one record committed (correct?). However, with Cairngorm: 1.Get a list of records a. dispatch ProductEvent.GET_ALL b. GetAllProductsCommand.execute() c. ds = new DataService(productHome); d. ds.fill(model.products); 2.Edit a product a. myList.dataProvider = model.products b. dispatch ProductEvent.EDIT, event.product = myList.selectedItem c. interface changes to the product form d. make modifications via a form e. dispatch ProductEvent.SAVE, event.product = myform.product f. SaveProductCommand.execute() g. ds = new DataService(productHome); h. .. how do we commit just this one record? Even if I still had a reference to the original DataService from the fill operation, I may not want to commit all records that changed, only the one that I'm interested in. This would be equivalent to keeping my DataService in my ServiceLocator. The only other option I can think of is that SaveProductCommand works like this, which messes up conflict checks: 1.product = (event as ProductEvent).product; 2.ds = new DataService(productHome); 3.ds.getItem({product_id: product.product_id}); 4.locally synchronize the item retrieved from ds.getItem() with the product we received in the product event 5.ds.commit() When we do this though, we very likely have the most recent copy of the object from the database, so we're not sure that something hadn't changed before getting it. Am I making this too complex? Is there another way to simply commit one particular record? I can think of all sorts of workarounds, but all of them violate the Cairngorm protocols. I can definitely see the other developers on the team bypassing our Command logic making Cairngorm a little useless :-) Jay Proulx Application Developer Internet Delivery Services - eVision Team [EMAIL PROTECTED] (613) 783-6711
[flexcoders] Re: issue with dataManagementService and spring (i suppose)
Did you ever get a solution to this issue? I'm having the same issue and my setup is very similar (Tomcat with FDS, Spring, Hibernate, etc). I've found that I can create an object, and it immediately appears in the list component so the fill method is picking it up after it is saved on the backend. However, I cannot delete it without getting the not managed by this service error. If I click around and trigger the fill again, it still gives the error. However, if I close the client browser, start a new one, and login again, I can then go and delete that item with no problems. Any ideas? Bill --- In flexcoders@yahoogroups.com, fabio_sebastiano [EMAIL PROTECTED] wrote: Hi all, i'm facing a really frustrating issues with my web application taht use flex 2.0, fds and integrate spring and flex. Everything works fine if a retrieve data from server and display them, but if i try to make anykind of update on them, it gives me this error: [RPC Fault faultString=Item with id '755B8019-F6C0-1DAA-4B7C-09D02B5271B3' not managed by this service. Error on destination 'ente'. faultCode=Local.Call.Failed faultDetail=null] at mx.data::ConcreteDataService/http://www.adobe.com/2006/flex/mx/internal::dispatchFaultEvent() at Function/http://adobe.com/AS3/2006/builtin::apply() at mx.rpc::AsyncDispatcher/::timerEventHandler() at flash.utils::Timer/flash.utils:Timer::_timerDispatch() at flash.utils::Timer/flash.utils:Timer::tick()+ 1) In the Data-management-config.xml, here's the destionation definition: ... destination id=ente adapter ref=java-dao / properties sourceEnteAssembler/source factoryspring/factory metadata identity property=codEnte/ /metadata /properties /destination 2) i've got an assembler class that extends Abstract Assembler and overide update, create, delete and fill methods. Fill method works fine. 3) i've got an AS3 mapping file with managed and remotclass metadata 4) spring seems to be well configured because it could retrieve object and beans. Where the error is Thank you so much Fabios
[flexcoders] Re: Spring Enable Flex
Use the FlexFactory. It allows you to integrate Flex Data Services with whatever framework you want. See this thread: http://www.adobe.com/cfusion/webforums/forum/messageview.cfm?catid=583threadid=1169760enterthread=y#4190415 --- In flexcoders@yahoogroups.com, suzy lawson [EMAIL PROTECTED] wrote: There isn't much to do to get Flex to talk with Spring! All you need to do is put a delegate class in the middle which is nothing more than a simple POJOFlex calls Pojo, Pojo invokes Spring Beans... - How low will we go? Check out Yahoo! Messenger's low PC-to-Phone call rates. -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links * To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ * To unsubscribe from this group, send an email to: [EMAIL PROTECTED] * Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
[flexcoders] FlexFactory example
I'm wanting to use Spring for my backend for Flex Data Services. I found the docs on using a class that implements the FlexFactory interface, but the really is not enough detail in the docs to fully understand how to fill out the FlexFactory implementation class. Has anyone successfully used this class? Do I create a single FlexFactory class for all of my destinations that I want to use Spring with? Or do I create a FlexFactory impl for each destination? Thanks Bill Yahoo! Groups Sponsor ~-- Yahoo! Groups gets a make over. See the new email design. http://us.click.yahoo.com/XISQkA/lOaOAA/yQLSAA/nhFolB/TM ~- -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links * To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ * To unsubscribe from this group, send an email to: [EMAIL PROTECTED] * Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/