Doug Livesey
2011-Sep-25 17:02 UTC
How to handle image file data in a RoR web service/client?
Hi. I''m breaking an existing app out into separate services for performance reasons, but am not sure about how best to proceed with handling images. The model I''m breaking out into a service has multiple images associated with it. Historically, these were handled with attachment_fu, and moving forwards (in the service I''m writing), they will be handled with carrier wave. The image data will be caught by the client app in a multipart form, as normal, then the client app''s controller will need to pass that image data on to the web service (along with other attributes) to create the model in question. How do people usually handle this? (I''ve been scouring the web for hints, but not doing notably well.) The web service I''m writing uses JSON, but I guess I need to pass binary data up for image uploads? Any & all advice, and any pointers to resources that''ll teach me, are gratefully received. Cheers, Doug. -- Posted via http://www.ruby-forum.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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.