I will be sending about 3000 REST POSTs every 15 seconds. What is the best way to bundle them? Would I have to create a custom action and/or controller unbundle them? Is there an easier way through a plugin or library? thanks chirag --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On 6/21/07, chirag <patelc75-/E1597aS9LQAvxtiuMwx3w@public.gmane.org> wrote:> > I will be sending about 3000 REST POSTs every 15 seconds. What is the > best way to bundle them? Would I have to create a custom action and/or > controller unbundle them? Is there an easier way through a plugin or > library?I just committed a patch that handles xml arrays. Try this in your console to see what the xml should look like:>> posts = Post.find(:all) >> xml = posts.to_xml(:root => ''posts'') >> puts xmlIt works both ways:>> Hash.from_xml(xml)If you''re POSTing to an xml-formatted rails action, the parsing to the params hash should be all handled for you of course. -- Rick Olson http://lighthouseapp.com http://weblog.techno-weenie.net http://mephistoblog.com --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On Jun 21, 10:22 am, "Rick Olson" <technowee...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > I just committed a patch that handles xml arrays. Try this in your > console to see what the xml should look like: >Rick, thanks! What do you mean "by committed a patch"? A patch to what?> If you''re POSTing to an xml-formatted rails action, the parsing to the > params hash should be all handled for you of course.What do you mean by "handled for you"? I created the controllers and actions using the scaffold_resource generator. Are you saying that the existing POST action will recognize that the POSTs are bundled in an array and process each individual one all automatically? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On 6/22/07, chirag <patelc75-/E1597aS9LQAvxtiuMwx3w@public.gmane.org> wrote:> > > > On Jun 21, 10:22 am, "Rick Olson" <technowee...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > I just committed a patch that handles xml arrays. Try this in your > > console to see what the xml should look like: > > > > Rick, thanks! What do you mean "by committed a patch"? A patch to > what?to Rails.> > If you''re POSTing to an xml-formatted rails action, the parsing to the > > params hash should be all handled for you of course. > > What do you mean by "handled for you"? I created the controllers and > actions using the scaffold_resource generator. Are you saying that the > existing POST action will recognize that the POSTs are bundled in an > array and process each individual one all automatically?It''ll parse the xml into params for you. -- Rick Olson http://lighthouseapp.com http://weblog.techno-weenie.net http://mephistoblog.com --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---