Memcached
is an in-memory key-value store for small chunks of arbitrary data
(strings, objects) from results of database calls, API calls, or page
rendering.
Memcached is a general-purpose distributed memory caching system that was originally developed by Danga Interactive for LiveJournal,
but is now used by many other sites. It is often used to speed up
dynamic database-driven websites by caching data and objects in RAM to
reduce the number of times an external data source (such as a database
or API) must be read. Memcached runs on Unix, Linux, Windows and Mac OS X
and is distributed under a permissive free software license.
Memcached's
APIs provide a giant hash table distributed across multiple machines.
When the table is full, subsequent inserts cause older data to be purged
in least recently used (LRU) order.
Architecture
Who uses Memcache?
- YouTube
- Reddit
- Zynga
- Facebook
- Orange
- Twitter
- Wikipedia
- Google App Engine, AppScale, Windows Azure and Amazon Web Services also offer a memcached service through an API
Used For?
Pros
1) Reduces database load.
2) Perfect for websites with high database load.
3) Significantly reduces the number of retrieval requests to database
4) Cuts down the I/O access (hard disk)
Cons
1) Not a persistent data store.
2) Not a database.
3) Not application specific
4) Cannot cache large object
Configuring Memcached (For Ubuntu)
Step 1) Install Libevent
$ cd libevent-1.4.11-stable$ autoconf
$ ./configure --prefix=/usr/local
$ make
$ sudo make install
$ ./configure --prefix=/usr/local
$ make
$ sudo make install
Step 2) Install Memcached
$ cd memcached-1.4.0$ autoconf$ ./configure --prefix=/usr/local$ make$ sudo make install
Step 3) Run memcached
Start memcached as a daemon with 512MB of memory on port 11211(default).
Then you can telnet to the server and port and use any of the available commands.
$ memcached -d -m 512 127.0.0.1 -p 11211
$ telnet localhost 11211Trying ::1...
Connected to localhost.
Escape character is '^]'.get joe
ENDset joe 0 3600 10 (Note: TTL 3600 and 10 bytes)California
STOREDget joe
VALUE joe 0 10
California
END
$ telnet localhost 11211Trying ::1...
Connected to localhost.
Escape character is '^]'.get joe
ENDset joe 0 3600 10 (Note: TTL 3600 and 10 bytes)California
STOREDget joe
VALUE joe 0 10
California
END
Step 4) Spy Memcached (Memcached Java Client)
public class Users implements Serializable{
private int id;
private String name ;
// Getter and Setter methods
}
public class MemcachedDemo {
public static void main(String[] args) {
Users users = new Users();
users.setId(1);
users.setName("Sunil123");
try {
MemcachedClient c=new MemcachedClient(new InetSocketAddress("127.0.0.1", 1121));
c.set("someKey_1", 2592000, users);
Object myObject=c.get("someKey_1");
System.out.println("Object 1: " + myObject);
System.out.println("Statistics: " + c.getStats());
System.out.println("Statistics of individual Items: " + c.getStats("items"));
c.delete("someKey_2");
c.shutdown();
c=null ;
} catch (IOException e) {
e.printStackTrace();
}
}
}
Thanks for sharing this webpage.It is really good and useful.
ReplyDeleteRegards,
AWS Training | AWS Training in Chennai | AWS course in Chennai
Awesome blog with informative content... thanks for sharing such a wonderful blog... Java Training in Chennai | Dot Net Training in Chennai
ReplyDeleteNice post. CCNP Training Institute in Chennai | CCNP Training Institute in Velachery.
ReplyDeleteAmazing blog about the various informative information of the programming languages. PHP is one such programming language which is more easier to learn and has lot of scope in future which is provided in Php Training institute in Chennai
ReplyDeleteThank you for this valuable information. I have got some important suggestions from it. I'm working in Brave Technologies Private Limited. We provides lowest price of ERP Software for our clients. Contact us on info@bravetechnologies.in
ReplyDeleteManufacturing ERP software Chennai | Automotive ERP in Chennai
Really an amazing post..! By reading your blog post i gained more information.
ReplyDeleteBulk SMS Services in Chennai
Very Nice Post…Thanks.Very interesting and Helpful Tips…..Thanks For Sharing.
ReplyDeleteExecutive MBA Distance Education
Wonderful post. Web Designing Training Institute in Chennai | Web Designing Training Institute in Velachery.
ReplyDeleteInformative post, thanks for this useful article.
ReplyDeleteSix Sigma Certification Training in Chennai | Six Sigma Certification Exam Center in Chennai | Best ISTQB Certification Training in Chennai
Very informative, Thanks for sharing your post...
ReplyDeleteWeb Designing Training in velachery | Web Designing Training institute in chennai |Best Web Designing Training in Chennai
Thanks for your amazing article..Its really useful to me..Keep updating.
ReplyDeleteISTQB Certification Training in Chennai | ISTQB Certification Classes in Chennai | ISTQB Exam Center in Chennai | ISTQB Training in Chennai
I have read your blog its very Interesting. Thanks for sharing..
ReplyDeleteMCSE Certification Training in Chennai | MCSE Training in Chennai | MCSE Certification Classes in Chennai | Online Training in Chennai
Amazing article..Thanks for sharing..Software Testing Training Institute in Chennai | Software Testing Training Institute in Velachery.
ReplyDeletevery interesting article,thanks for sharing.
ReplyDeletetop mobile app development company
mobile apps development company in Mumbai
Android app development company Mumbai
iPhone app development companies mumbai
iOS app development companies mumbai
Windows apps development companies mumbai
Excellent concept with understandable manner. Thanks for sharing such a nice blog. Software Testing Training Institute in Chennai | Selenium Training Institute in Chennai
ReplyDeleteVery lovely information such a nice post..Thanks for sharing..
ReplyDeleteBest Final Year Project Center in Chennai | No.1 Diploma Project in Chennai | Best BBA/MBA Project Center in Chennai
Thanks for taking the time to discuss this Database topic and I feel very happy about it. Keep Sharing.. Best Dot Net Training in Chennai | Best Java Training in Chennai | Best Web Design Training in Chennai
ReplyDeleteExcellent information from your article..I really love reading and following your post as I find them extremely informative and interesting.
ReplyDeleteBest B.E/B.Tech Project Center in Chennai | No.1 M.E/M.Tech Projects in Chennai | Best IT Project Center in Chennai
Thanks for posting this useful and interesting article..
ReplyDeleteBE Project Center in Chennai | ME Project Center in Chennai | MSC Project Center in Chennai
Thanks for sharing an informative post...
ReplyDeleteMobile app developers Dubai
Thanks For Your valuable posting, it was very informative
ReplyDeleteWebdesign Lüdenscheid
Thank you very much for your very informative post. In my opinion, I can offer you to read an article with a similar topic on how mobile applications can boost sales of your business in 2017 :https://softwaredevelopment.ae/can-mobile-app-development-increase-2017-sales/
ReplyDeletethis is really too useful and have more ideas from yours. keep sharing many techniques.
ReplyDeleteJava Project Center in Chennai | Best Java Projects in Velachery
Interesting post! This is really helpful for me. I like it! Thanks for sharing!
ReplyDeleteImage Processing Project Center in Chennai | Image Processing Project Center in Velachery
Nice and interesting blog to read.... keep updating!!Thanks for sharing...Embedded Projects Center in Chennai | Embedded Projects Center in Velachery
ReplyDeleteVery impressive and innovative post..Thanks for updating..
ReplyDeleteNo.1 IOS Training Institute in Velachery | Best Android Training Institute in Velachery | Core Java Training Institute in Chennai
I really enjoyed while reading your article, the information you have delivered in this post was damn good. Keep sharing your post with efficient news.
ReplyDeleteMSC Project Center in Chennai | MSC Project Center in Velachery
Informative blog and it was up to the point describing the information very effectively. Thanks to blog author for wonderful and informative post.
ReplyDeleteMobile application developers in Chennai | Android application developers in Chennai | Android app
developers Chennai | PHP developers chennai
Those guidelines additionally worked to become a good way to recognize that other people online have the identical fervor like mine to grasp great deal more around this condition.
ReplyDeleteandroid training in bangalore
I am so happy to read such a wonderful post...Thank you for updating...VLSI Project Center in Chennai | VLSI Project Center in Velachery
ReplyDeleteImpressive blog with lovely information. really very useful article for us thanks for sharing such a wonderful blog...
ReplyDeleteMCA Project Center in Chennai | MCA Project Center in Velachery
Thanks for this grateful information. all this information is very important to all the users and can be used good at all this process.
ReplyDeleteWeb Designing Training Institute in Chennai | Web Designing Training Institute in Velachery
Interesting post. This is really helpful for me. I like it. Thanks for sharing
ReplyDeleteBest VMware Training Institute in Chennai | Best VMware Training Institute in Velachery
Thanks a lot for Sharing the valuable information keep posting everyone ..Java Project Center in Chennai | Java Project Center in Velachery
ReplyDeleteI read that Post and got it fine and informative. Please share more like that..
ReplyDeletehr and payroll software in chennai
Good Post! Thank you so much for sharing this pretty post, it was so good to read and useful to improve my knowledge as updated one, keep blogging.
ReplyDeletepython training in omr
python training in annanagar | python training in chennai
python training in marathahalli | python training in btm layout
python training in rajaji nagar | python training in jayanagar
Thank you for taking the time to provide us with your valuable information. We strive to provide our candidates with excellent care and we take your comments to heart.As always, we appreciate your confidence and trust in us
ReplyDeletejava training in omr
java training in annanagar | java training in chennai
java training in marathahalli | java training in btm layout
java training in rajaji nagar | java training in jayanagar
Great article. Very interesting thanks for sharing.
ReplyDeleteBest Mobile App Development Companies Dubai
Good post and it is useful to gain knowledge for me. Thanks
ReplyDeleteAndroid App Development Company In Dubai
Best Iphone App Development Companies Dubai
Read all the information that i've given in above article. It'll give u the whole idea about it.
ReplyDeleteData Science with Python training in chenni
Data Science training in chennai
Data science training in velachery
Data science training in tambaram
Data Science training in OMR
Data Science training in anna nagar
Data Science training in chennai
Data science training in Bangalore
I love the information you provide here and can’t wait to take a look when I get home. I’m surprised at how fast your blog loaded on my cell phone. I’m not even using WIFI, just 3G. Anyways, awesome blog!
ReplyDeletefire and safety course in chennai
Awesome blog! Thanks for sharing this with us. Do share more such posts.
ReplyDeleteMobile Testing Training in Chennai
Mobile Automation Testing Training in Chennai
Oracle DBA Training in Chennai
Unix Training in Chennai
Embedded System Course Chennai
IoT Training in Chennai
ReplyDeleteThank you sharing the info very well explained.
MCSE Training in Delhi
Great content thanks for sharing this informative blog which provided me technical information keep posting.
ReplyDeleteAWS training in chennai | AWS training in annanagar | AWS training in omr | AWS training in porur | AWS training in tambaram | AWS training in velachery
trendyol indirim kodu
ReplyDeletecami avizesi
cami avizeleri
avize cami
no deposit bonus forex 2021
takipçi satın al
takipçi satın al
takipçi satın al
takipcialdim.com/tiktok-takipci-satin-al/
instagram beğeni satın al
instagram beğeni satın al
btcturk
tiktok izlenme satın al
sms onay
youtube izlenme satın al
no deposit bonus forex 2021
tiktok jeton hilesi
tiktok beğeni satın al
binance
takipçi satın al
uc satın al
sms onay
sms onay
tiktok takipçi satın al
tiktok beğeni satın al
twitter takipçi satın al
trend topic satın al
youtube abone satın al
instagram beğeni satın al
tiktok beğeni satın al
twitter takipçi satın al
trend topic satın al
youtube abone satın al
takipcialdim.com/instagram-begeni-satin-al/
perde modelleri
instagram takipçi satın al
instagram takipçi satın al
takipçi satın al
instagram takipçi satın al
betboo
marsbahis
Finish the Selenium Training in Chennai from Infycle Technologies, the best software training institute in Chennai which is providing professional software courses such as Data Science, Artificial Intelligence, Java, Hadoop, Big Data, Android, and iOS Development, Oracle, etc with 100% hands-on practical training. Dial 7502633633 to get more info and a free demo and to grab the certification for having a peak rise in your career.
ReplyDeletesmm panel
ReplyDeleteSmm panel
iş ilanları
instagram takipçi satın al
HIRDAVATÇI BURADA
HTTPS://WWW.BEYAZESYATEKNİKSERVİSİ.COM.TR
SERVİS
Jeton hilesi indir
pendik samsung klima servisi
ReplyDeleteataşehir mitsubishi klima servisi
pendik lg klima servisi
pendik daikin klima servisi
tuzla toshiba klima servisi
ataşehir lg klima servisi
çekmeköy alarko carrier klima servisi
ataşehir alarko carrier klima servisi
çekmeköy daikin klima servisi
Need professional WordPress Web Design Services? We're experts in developing attractive mobile-friendly WordPress websites for businesses. Contact us today! https://just99marketing.com/wordpress-web-design
ReplyDelete