Thanks Peter to reply.
Actually my table consist more than 15 columns and each column have lots of
validation like presence validation,format validation.
Major issue is user will upload CSV file which can consist hundred's of
rows.Through active record validating each row consuming lots of time.

That's why I am thinking to move validation rule to cache level. It will
fast process.

Is this can be possible to validate data on cache level ?



On Sun, Nov 3, 2013 at 2:38 AM, Peter Hickman <
peterhickman...@googlemail.com> wrote:

> Memcached is only useful for storing the responses and unless the
> validation rules are incredibly complicated using memcached is not going to
> speed anything up.
>
> Simply not the right tool for the job, the real question is why are your
> validation rules so slow.
>
>
>
> On 2 November 2013 20:16, Fahim Patel <pafa...@gmail.com> wrote:
>
>> Hi All ,
>>
>> Can we validate request input data using memcache ? Actually I am facing
>> scenario in which user uploading CSV file which can have hundreds of rows
>> and to validate each row using ActiveRecord taking long time.
>>
>> I have below question:-
>>
>> 1. So can we cache our validation rule in memcache ?
>> 2. If it is possible to store validation rules in memcache but can I able
>> to perform
>> validation check ?
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Ruby on Rails: Talk" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to rubyonrails-talk+unsubscr...@googlegroups.com.
>>
>> To post to this group, send email to rubyonrails-talk@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/rubyonrails-talk/10f8edbc-b78c-4cbe-9712-62e57b7105e9%40googlegroups.com
>> .
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Ruby on Rails: Talk" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/rubyonrails-talk/-h-dG0UWT5o/unsubscribe
> .
> To unsubscribe from this group and all its topics, send an email to
> rubyonrails-talk+unsubscr...@googlegroups.com.
> To post to this group, send email to rubyonrails-talk@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/rubyonrails-talk/CALxYQy4x4-5JGcT6bLdq8w13BuJgo-9Vf225JEdnEiGKKUPReg%40mail.gmail.com
> .
>
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rubyonrails-talk+unsubscr...@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rubyonrails-talk/CA%2B_35O0e6rwBAGkSjhcZ_NAc%2BvWbcfMzVgrLz_Cuu_KMLaBjQA%40mail.gmail.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to