did you tried with another language like perl, php...

2011/5/23 Ashu gupta <[email protected]>:
> Yes, Others keys whose value's size .5KB-1KB is returning in 4-5 ms.
>
> On May 23, 6:28 pm, Roberto Spadim <[email protected]> wrote:
>> others keys return in 4 ms? or every key return in 25~40ms?
>>
>> 2011/5/23 Ashu gupta <[email protected]>:
>>
>>
>>
>> > Below is the info
>>
>> > Memcache Client is SpyMemcache version memcached-2.3.1.jar
>> > Client Code is
>> > public Object getKeyValue(String key) {
>> >        return getKeyValue(key, TIME_TO_RETRIEVE_VALUE_FROM_CACHE);
>> >    }
>> >    public Object getKeyValue(String key, int time) {
>> >        MemcachedClient client = null;
>> >        try {
>> >            Object myObj = null;
>> >            client = getFreeClient();
>> >            long startTime = 0;
>> >            long deliverTime = 0;
>> >            if (client != null) {
>> >                startTime = Calendar.getInstance().getTimeInMillis();
>> >                myObj = client.get(key);
>> >                deliverTime =
>> > Calendar.getInstance().getTimeInMillis();
>> >            }
>> >            long diff = deliverTime - startTime;
>> >            s_logger.error("Time to deliver key " + key + " is " +
>> > diff);
>> >            if (diff > 4) {
>> >                s_logger.error("Time to reterive key is more than 4
>> > millisecond,key is " + key + " time taken : "
>> >                        + diff);
>> >            }
>> >            return myObj;
>> >        } catch (Exception e) {
>> >            s_logger.error("Not able to get KeyValue pair for key " +
>> > key, e);
>> >        } finally {
>> >            if (client != null) {
>> >                addFreeClient(client);
>> >            }
>> >        }
>> >        return null;
>> >    }
>>
>> > client = new MemcachedClient(new InetSocketAddress("localhost",
>> > 11211));
>>
>> > memcache server memory is 512MB
>> > memcache server version memcached-1.4.5 downloaded 
>> > fromhttp://www.memcached.org/
>>
>> > client memory is 1GB
>>
>> > Both Client and server is on same machine (my local system)
>>
>> > I have set of keys in my memcache server . One of the key size is 25KB
>> > which i have checked with stats sizes but when i am trying to key that
>> > key's Value in my local system it is taking aroung 30-40 Millisecond
>> > as i have heard that memcache should not take more than 4-5
>> > millisecond. Please help me where i am wrong in the implementation.
>>
>> > On May 22, 9:41 pm, Roberto Spadim <[email protected]> wrote:
>> >> maybe your source code, library version, memcache daemon version,
>> >> operational system if client and server, server memory, client memory,
>> >> server cpu, client cpu, etc..
>>
>> >> 2011/5/22 Ashu gupta <[email protected]>:
>>
>> >> > Dear Henrik,
>>
>> >> > Can u please tell me what more information do i need to provide . I am
>> >> > new to memcache and i don't know more about memcache so please let me
>> >> > know what are the info that you required so that it will helpful for
>> >> > you to solve my problem.
>>
>> >> > On May 22, 3:17 pm, Henrik Schröder <[email protected]> wrote:
>> >> >> Do you think you provided enough information in your original email to
>> >> >> enable anyone else to help you?
>>
>> >> >> /Henrik
>>
>> >> >> On Sun, May 22, 2011 at 11:15, Ashu gupta <[email protected]> 
>> >> >> wrote:
>> >> >> > Dear Dustin,
>>
>> >> >> > Sorry i didn't get you.
>>
>> >> >> > On May 21, 11:18 pm, Dustin <[email protected]> wrote:
>> >> >> > > On May 21, 5:28 am, Ashu gupta <[email protected]> wrote:
>>
>> >> >> > > > Hi All,
>>
>> >> >> > > > I have implemented memcache in my system but i am facing Speed
>> >> >> > > > Problem . I am using spymemcache as a client. One of my value 
>> >> >> > > > size is
>> >> >> > > > around 25KB but it is taking around 30-40 milisecond in order to
>> >> >> > > > reterieve that key's value. Please suggest why it is taking so 
>> >> >> > > > much
>> >> >> > > > time what can be possible cause for this.
>>
>> >> >> > >   I think your bug is around line 13.
>>
>> >> --
>> >> Roberto Spadim
>> >> Spadim Technology / SPAEmpresarial
>>
>> --
>> Roberto Spadim
>> Spadim Technology / SPAEmpresarial



-- 
Roberto Spadim
Spadim Technology / SPAEmpresarial

Reply via email to