bigdata4u / spymemcached

Automatically exported from code.google.com/p/spymemcached
0 stars 0 forks source link

Problem regards Storing files inside Memcached server? #288

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
HI,

I having an input file(.JSON,.jpg,.txt,etc..).That file i need to store into 
memcached server.
I don't want to convert file to byte[] before passing to memcached server.
If any possibility to store file inside Memcached server?
I am using spymemcached tool.

Example:

MemcachedClient mc=new MemcachedClient(new 
InetSocketAddress("192.168.7.104",11211));  
File file=new File("D:\\test.txt");
mc.set("Key1",3600,file);
mc.get("Key1");

Plz replay if any sollution..
Thanks in Advance..
Sekhar.

Original issue reported on code.google.com by msekhar...@gmail.com on 22 Oct 2013 at 1:39

GoogleCodeExporter commented 8 years ago
Hi Team,
  I even tried converting the file to byte[] and push it to kestrel server, but while retrieving the file i am seeing some extra bytes of information (ofcourse they belong the last line of the file). 

Same with the compressed files either. They are being decoded as String in lie 
of accepting them as a byte[] when read from the MemcachedNode. (Guess this 
might help you, the flags that is being set while storing the cacheddata object 
to queue is being read as zero (0) while retrieving it should be 2048 (8 << 8) 
).

Thanks
Dharma S

Original comment by dso...@gmail.com on 29 Oct 2013 at 2:27

GoogleCodeExporter commented 8 years ago
do you see the same problem when using a vanilla memcached server?

Original comment by ingen...@gmail.com on 7 Nov 2013 at 9:42