<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-7650970815911230284</id><updated>2024-09-12T23:36:13.001-07:00</updated><category term="bean"/><category term="cache"/><category term="data grid"/><category term="document"/><category term="document translation"/><category term="google"/><category term="jboss"/><category term="jboss cache"/><category term="jmx"/><category term="manage"/><category term="mbean"/><category term="monitor"/><category term="server"/><category term="spring"/><category term="translate"/><title type='text'>JAB - Just Another Blog</title><subtitle type='html'>Lets share some of our thoughts..</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://jshuttle.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://jshuttle.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>sanmoy</name><uri>http://www.blogger.com/profile/16061521124526657995</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjE1o9nEG8vF3faAEAHr_fp-pCMtvQLhypCQ1byJGsByeI8WkCMccee0-lEPADLJwD8-GPAIhmDl5YHvH0BOj8gmGYE1kL2VLHWXm_lCKxVmxCv6ZQe2VL0u_axH9hOqw/s1600/*'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>4</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-7650970815911230284.post-5197055190622249937</id><published>2014-05-07T04:24:00.001-07:00</published><updated>2014-09-16T11:25:18.045-07:00</updated><title type='text'>Digitization of a mind boggling puzzle game</title><content type='html'>&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;If you don&#39;t want to kill your time with some mindless games, then this may be the best choice for you.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;This is an age old puzzle game. Though little obscure.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;So we thought, why not we give it a digital form and make it available for mobiles and tablets so that people will know and play this beautiful cute game.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgIeMdgM9Dw23vKknjXG-Lu9H2-1XxtyCuvgKMfbug_LElQn_UokIDe_PgHLUv5lnwqfdXQ2SjO12ZV0dR3A-dXQDLKlSW4iF-U3szMCcgH8AOzBTuTZx6gF0N9CjoWFH8hqURJ1dSZr35Q/s1600/icon_r.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgIeMdgM9Dw23vKknjXG-Lu9H2-1XxtyCuvgKMfbug_LElQn_UokIDe_PgHLUv5lnwqfdXQ2SjO12ZV0dR3A-dXQDLKlSW4iF-U3szMCcgH8AOzBTuTZx6gF0N9CjoWFH8hqURJ1dSZr35Q/s1600/icon_r.png&quot; height=&quot;200&quot; width=&quot;196&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;span style=&quot;font-family: play, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
&lt;br /&gt;
&lt;div class=&quot;font_8&quot; style=&quot;background-position: 0px 0px; border: 0px; font-family: play, sans-serif; font-size: 14px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;
Gameplay is simple. 12 colourful pieces to put together inside a triangle.&lt;/div&gt;
&lt;div class=&quot;font_8&quot; style=&quot;background-position: 0px 0px; border: 0px; font-family: play, sans-serif; font-size: 14px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;font_8&quot; style=&quot;background-position: 0px 0px; border: 0px; font-family: play, sans-serif; font-size: 14px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;
Player can rotate an element, flip an element and move it to its correct position. Some elements are symmetric. They cannot be rotated. Some are mirror asymmetric. Only these elements can be flipped.&lt;/div&gt;
&lt;div class=&quot;font_8&quot; style=&quot;background-position: 0px 0px; border: 0px; font-family: play, sans-serif; font-size: 14px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;font_8&quot; style=&quot;background-position: 0px 0px; border: 0px; font-family: play, sans-serif; font-size: 14px; outline: 0px; padding: 0px; vertical-align: baseline;&quot;&gt;
Play the tutorial to know the basic moves. Then you can dive into the game.&lt;/div&gt;
&lt;span style=&quot;font-family: play, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;If you want to challenge yourself like &quot;can I solve it without any hint&quot;, then medium stages are there for you.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;And if you love to get insanely challenged, then go ahead, jump into hardcore stages.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;I kept the game advertisement free, as I think, this game is for real puzzle lovers and stupid adds will destroy your thinking process !!&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;For download, please visit the below links&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span style=&quot;font-family: play, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 14px;&quot;&gt;&lt;a href=&quot;http://www.nascentsoftware.com/&quot;&gt;http://www.nascentsoftware.com/&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 14px;&quot;&gt;&lt;a href=&quot;https://itunes.apple.com/us/app/zentriangle/id823755270?mt=8&quot;&gt;https://itunes.apple.com/us/app/zentriangle/id823755270?mt=8&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif; font-size: 14px;&quot;&gt;&lt;a href=&quot;https://play.google.com/store/apps/details?id=com.ns.zentriangle&quot;&gt;https://play.google.com/store/apps/details?id=com.ns.zentriangle&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: play, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-family: play, sans-serif;&quot;&gt;&lt;span style=&quot;font-size: 14px;&quot;&gt;Facebook app will be launched soon.&lt;/span&gt;&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://jshuttle.blogspot.com/feeds/5197055190622249937/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/7650970815911230284/5197055190622249937' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default/5197055190622249937'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default/5197055190622249937'/><link rel='alternate' type='text/html' href='http://jshuttle.blogspot.com/2014/05/digitization-of-mind-boggling-puzzle.html' title='Digitization of a mind boggling puzzle game'/><author><name>sanmoy</name><uri>http://www.blogger.com/profile/16061521124526657995</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjE1o9nEG8vF3faAEAHr_fp-pCMtvQLhypCQ1byJGsByeI8WkCMccee0-lEPADLJwD8-GPAIhmDl5YHvH0BOj8gmGYE1kL2VLHWXm_lCKxVmxCv6ZQe2VL0u_axH9hOqw/s1600/*'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgIeMdgM9Dw23vKknjXG-Lu9H2-1XxtyCuvgKMfbug_LElQn_UokIDe_PgHLUv5lnwqfdXQ2SjO12ZV0dR3A-dXQDLKlSW4iF-U3szMCcgH8AOzBTuTZx6gF0N9CjoWFH8hqURJ1dSZr35Q/s72-c/icon_r.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7650970815911230284.post-7538437414902755069</id><published>2013-12-13T22:02:00.001-08:00</published><updated>2013-12-23T10:46:20.109-08:00</updated><title type='text'>Google killed html5 game development with android KitKat (4.4) release</title><content type='html'>Html5 is a nice platform for game development. Though the standardization is not&amp;nbsp;&lt;a href=&quot;http://dev.w3.org/html5/decision-policy/html5-2014-plan.html&quot;&gt;stable&lt;/a&gt;, it is mostly supported by all major browsers.&lt;br /&gt;
&lt;br /&gt;
Most advantage of html5 game development is, you will have a single code-base for all your platforms : windows, android, ios etc. The disadvantage is : it runs through a browser engine, which is not as fast as native implementation (read opengl) . So, if your aim is to build a NFS type game, definitely it is not the right choice.&lt;br /&gt;
&lt;br /&gt;
One more reason html5 is my favourite is, you can construct basic interfaces, buttons, forms, dialogs, scrolling pages using css and the same platform you can use for your game animation. If you are using webgl, you have to take care for everything.&lt;br /&gt;
&lt;br /&gt;
I wrote a small puzzle game in html5 and tested it across many devices. Android Jelly Bean has the exceptional rendering performance. Same device (samsung galaxy s2), when runs on JB, shows significant performance improvement, in comparison when it is running on android Ice Cream Sandwich. But anyhow, it was managed to run on ICS.&lt;br /&gt;
&lt;br /&gt;
Nightmare started after Google released the KitKat. Prior to this release, everyone was so delighted. &amp;nbsp;The new WebView will be powered by chrome and we can see even more performance boost for html5 games. But it looks like, google is going backward with this new release of android. The html5 canvas for webview is not hardware accelerated anymore and shows extremely poor performance. This phenomenon is so widespread that it affects almost everyone who relies on html5 canvas rendering. Games stopped working, apps slowed down to their death.&lt;br /&gt;
&lt;br /&gt;
There are several bugs raised.&amp;nbsp;And there is no hope that they will be fixed in near future.&lt;br /&gt;
&lt;a href=&quot;https://code.google.com/p/chromium/issues/detail?id=315111&quot;&gt;https://code.google.com/p/chromium/issues/detail?id=315111&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;https://code.google.com/p/chromium/issues/detail?id=239864&quot;&gt;https://code.google.com/p/chromium/issues/detail?id=239864&lt;/a&gt;&lt;br /&gt;
&lt;a href=&quot;https://code.google.com/p/chromium/issues/detail?id=329108&quot;&gt;https://code.google.com/p/chromium/issues/detail?id=329108&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://jshuttle.blogspot.com/feeds/7538437414902755069/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/7650970815911230284/7538437414902755069' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default/7538437414902755069'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default/7538437414902755069'/><link rel='alternate' type='text/html' href='http://jshuttle.blogspot.com/2013/12/google-killed-html5-game-development.html' title='Google killed html5 game development with android KitKat (4.4) release'/><author><name>sanmoy</name><uri>http://www.blogger.com/profile/16061521124526657995</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjE1o9nEG8vF3faAEAHr_fp-pCMtvQLhypCQ1byJGsByeI8WkCMccee0-lEPADLJwD8-GPAIhmDl5YHvH0BOj8gmGYE1kL2VLHWXm_lCKxVmxCv6ZQe2VL0u_axH9hOqw/s1600/*'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7650970815911230284.post-8557250464494041392</id><published>2011-09-24T01:13:00.000-07:00</published><updated>2011-09-24T05:54:21.201-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="document"/><category scheme="http://www.blogger.com/atom/ns#" term="document translation"/><category scheme="http://www.blogger.com/atom/ns#" term="google"/><category scheme="http://www.blogger.com/atom/ns#" term="translate"/><title type='text'>Document Translation using Google</title><content type='html'>Amongst many of google&#39;s incredible services, one is &quot;document translation&quot;. Google provides a web interface to translate a document. But the constraint is, the translated document will be shown as a web-page and you can not get the translated document in your original binary format. This backlog prompts me to develop a desktop application which will exploit Google&#39;s translation power to translate a document, right from your desktop. Currently this software supports the below file formats: &lt;br /&gt;
&lt;ul&gt;&lt;li&gt;doc &lt;/li&gt;
&lt;li&gt;xls &lt;/li&gt;
&lt;li&gt;ppt &lt;/li&gt;
&lt;li&gt;docx &lt;/li&gt;
&lt;li&gt;xlsx &lt;/li&gt;
&lt;li&gt;pptx &lt;/li&gt;
&lt;li&gt;txt &lt;/li&gt;
&lt;/ul&gt;The software is licensed under gnu lesser gpl and hosted in &lt;a href=&quot;http://code.google.com/p/google-document-translator/&quot;&gt;google codes&lt;/a&gt;. You can check out the source from &lt;a href=&quot;http://google-document-translator.googlecode.com/svn/trunk/%20google-document-translator&quot;&gt;google code svn&lt;/a&gt;.Compiled binaries are available from &lt;a href=&quot;http://code.google.com/p/google-document-translator/downloads/list&quot;&gt;downloads&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Google Document translator is written in java and requires &lt;a href=&quot;http://www.oracle.com/technetwork/java/javase/downloads/index.html&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;color: #0000cc;&quot;&gt;jre&lt;/span&gt;&lt;/a&gt; to run. This project uses &lt;br /&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href=&quot;http://poi.apache.org/&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;color: #0000cc;&quot;&gt;apache poi&lt;/span&gt;&lt;/a&gt; to handle microsoft office documents &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://code.google.com/p/google-api-translate-java/&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;color: #0000cc;&quot;&gt;google-api-translate-java&lt;/span&gt;&lt;/a&gt; to call google language api from a java client &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://dom4j.sourceforge.net/&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;color: #0000cc;&quot;&gt;dom4j&lt;/span&gt;&lt;/a&gt; for xml parsing &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://jaxen.codehaus.org/&quot; rel=&quot;nofollow&quot;&gt;jaxen&lt;/a&gt; for xpath &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://itextpdf.com/&quot; rel=&quot;nofollow&quot;&gt;&lt;span style=&quot;color: #0000cc;&quot;&gt;itext&lt;/span&gt;&lt;/a&gt; for pdf support ( in Progress ) &lt;/li&gt;
&lt;/ul&gt;&lt;br /&gt;
The software has a unique feature &quot;HTTP Translator&quot;. Google provides &lt;a href=&quot;http://code.google.com/apis/language/&quot;&gt;api for language translation&lt;/a&gt;.The service is free but it has been deprecated. Google will stop the service completely after December 1st 2011. This deprecated&amp;nbsp;api is replaced by a newer version, &lt;a href=&quot;http://code.google.com/apis/language/translate/overview.html&quot;&gt;google translate&amp;nbsp;api v2&lt;/a&gt;, equally powerful as its older counterpart. But, due to economic burden caused by extensive abuse ( as goolge says ) , they have made it as a paid service. So, I have come out with&amp;nbsp;this tricky solution, &quot;HTTP Translator&quot;. The translator uses simple http get post request and parse the response to translate a input text. As long as google continues their translation website, hope this http translator will work smoothly.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgoIqZFZMU35JF8o0eZGH_DjBRpHoHPYYS3BjI6fTRLaOKGK6F18KPCEFZ8LkEKzf2up9iuQtkx1T0HVeSVZEKFzoHPqdYq5m3XQ8lfKdykzXKS_HK5CEh_he9iR2MfZkpSQDCRm-gLqDdp/s1600/screenshot1.png&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;214&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgoIqZFZMU35JF8o0eZGH_DjBRpHoHPYYS3BjI6fTRLaOKGK6F18KPCEFZ8LkEKzf2up9iuQtkx1T0HVeSVZEKFzoHPqdYq5m3XQ8lfKdykzXKS_HK5CEh_he9iR2MfZkpSQDCRm-gLqDdp/s320/screenshot1.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiWtVoARrGXeyBNis4EFBSF8ZBQBC1KUb3Bl38EaAHfdKH5zfPz0nB-VTmFMKHJoBHjjCy9PGIPbiiM8rqZqwJf_A42CX8RaaKJ9RYsX2qQZFjMUCVammhX1HAU8OcmD0RV57rtZSDrwmVc/s1600/screenshot2.png&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;168&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiWtVoARrGXeyBNis4EFBSF8ZBQBC1KUb3Bl38EaAHfdKH5zfPz0nB-VTmFMKHJoBHjjCy9PGIPbiiM8rqZqwJf_A42CX8RaaKJ9RYsX2qQZFjMUCVammhX1HAU8OcmD0RV57rtZSDrwmVc/s200/screenshot2.png&quot; width=&quot;200&quot; /&gt;&lt;/a&gt;&amp;nbsp; &lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiWtVoARrGXeyBNis4EFBSF8ZBQBC1KUb3Bl38EaAHfdKH5zfPz0nB-VTmFMKHJoBHjjCy9PGIPbiiM8rqZqwJf_A42CX8RaaKJ9RYsX2qQZFjMUCVammhX1HAU8OcmD0RV57rtZSDrwmVc/s1600/screenshot2.png&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;
&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgoIqZFZMU35JF8o0eZGH_DjBRpHoHPYYS3BjI6fTRLaOKGK6F18KPCEFZ8LkEKzf2up9iuQtkx1T0HVeSVZEKFzoHPqdYq5m3XQ8lfKdykzXKS_HK5CEh_he9iR2MfZkpSQDCRm-gLqDdp/s1600/screenshot1.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;
&lt;/a&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://jshuttle.blogspot.com/feeds/8557250464494041392/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/7650970815911230284/8557250464494041392' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default/8557250464494041392'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default/8557250464494041392'/><link rel='alternate' type='text/html' href='http://jshuttle.blogspot.com/2011/09/document-translation-using-google.html' title='Document Translation using Google'/><author><name>sanmoy</name><uri>http://www.blogger.com/profile/16061521124526657995</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjE1o9nEG8vF3faAEAHr_fp-pCMtvQLhypCQ1byJGsByeI8WkCMccee0-lEPADLJwD8-GPAIhmDl5YHvH0BOj8gmGYE1kL2VLHWXm_lCKxVmxCv6ZQe2VL0u_axH9hOqw/s1600/*'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgoIqZFZMU35JF8o0eZGH_DjBRpHoHPYYS3BjI6fTRLaOKGK6F18KPCEFZ8LkEKzf2up9iuQtkx1T0HVeSVZEKFzoHPqdYq5m3XQ8lfKdykzXKS_HK5CEh_he9iR2MfZkpSQDCRm-gLqDdp/s72-c/screenshot1.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-7650970815911230284.post-6867131998843437331</id><published>2011-03-26T05:24:00.000-07:00</published><updated>2011-03-26T08:35:55.527-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="bean"/><category scheme="http://www.blogger.com/atom/ns#" term="cache"/><category scheme="http://www.blogger.com/atom/ns#" term="data grid"/><category scheme="http://www.blogger.com/atom/ns#" term="jboss"/><category scheme="http://www.blogger.com/atom/ns#" term="jboss cache"/><category scheme="http://www.blogger.com/atom/ns#" term="jmx"/><category scheme="http://www.blogger.com/atom/ns#" term="manage"/><category scheme="http://www.blogger.com/atom/ns#" term="mbean"/><category scheme="http://www.blogger.com/atom/ns#" term="monitor"/><category scheme="http://www.blogger.com/atom/ns#" term="server"/><category scheme="http://www.blogger.com/atom/ns#" term="spring"/><title type='text'>Registering Jboss Cache with MBeanServer</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;&lt;a href=&quot;http://www.jboss.org/jbosscache&quot; style=&quot;color: blue;&quot;&gt;Jboss Cache&lt;/a&gt;&lt;span style=&quot;color: blue;&quot;&gt; &lt;/span&gt;is an generic cache implemented in java and licensed under &lt;a href=&quot;http://www.gnu.org/licenses/lgpl-2.1.html&quot; style=&quot;color: blue;&quot;&gt;lgpl 2.1&lt;/a&gt;. Similar kind of implementations are also available from &lt;a href=&quot;http://www.apache.org/&quot; style=&quot;color: blue;&quot;&gt;apache&lt;/a&gt;&lt;span style=&quot;color: blue;&quot;&gt; &lt;/span&gt;(&lt;a href=&quot;http://jakarta.apache.org/jcs/index.html&quot;&gt; JCS &lt;/a&gt;- Java caching System ) and &lt;a href=&quot;http://www.oracle.com/index.html&quot;&gt;&lt;span style=&quot;color: blue;&quot;&gt;Oracle&lt;/span&gt; &lt;/a&gt;( &lt;a href=&quot;http://www.oracle.com/technetwork/middleware/coherence/index.html&quot;&gt;&lt;span style=&quot;color: blue;&quot;&gt;oracle coherence&lt;/span&gt; &lt;/a&gt;). All caches are almost having similar features and  provide enterprise-grade clustering solutions to Java-based frameworks.&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;&lt;a href=&quot;http://www.jboss.org/jbosscache&quot; style=&quot;color: blue;&quot;&gt;JBoss cache&lt;/a&gt; is already being used in different enterprise solution and fully tested   for robustness and performance. Though, a more powerful data grid   platform &quot;&lt;a href=&quot;http://www.jboss.org/infinispan&quot; style=&quot;color: blue;&quot;&gt;Infinispan&lt;/a&gt;&quot;  is already available from the same JBoss Community.&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;Here I will not go much details inside &lt;a href=&quot;http://www.jboss.org/jbosscache&quot; style=&quot;color: blue;&quot;&gt;JBoss cache&lt;/a&gt;, as numerous tutorials/example codes are already available in net and &lt;a href=&quot;http://www.jboss.org/&quot; style=&quot;color: blue;&quot;&gt;JBoss&lt;/a&gt; also provides a very informative &lt;a href=&quot;http://community.jboss.org/wiki/JBossCacheOfficialDocumentation&quot; style=&quot;color: blue;&quot;&gt;documentation&lt;/a&gt; for their cache. This blog will only cover a typical topic on how we can register Jboss cache with an &lt;a href=&quot;http://download.oracle.com/javase/tutorial/jmx/mbeans/index.html&quot;&gt;&lt;span style=&quot;color: blue;&quot;&gt;Mbean&lt;/span&gt; &lt;/a&gt;server.&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;Before proceeding further, I will assume my reader has basic knowledge on JBoss Cache, Spring and &lt;a href=&quot;http://download.oracle.com/javase/tutorial/jmx/index.html&quot; style=&quot;color: blue;&quot;&gt;JMX&lt;/a&gt;. Also, he should be able to setup the cache and run it successfully.&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;There are two ways to register JBoss cache with a MBeanServer&lt;/div&gt;&lt;ol style=&quot;font-family: inherit;&quot;&gt;&lt;li&gt;Programmatic Registration&lt;/li&gt;
&lt;li&gt;Register as a spring bean&lt;/li&gt;
&lt;/ol&gt;&lt;ul style=&quot;font-family: inherit;&quot;&gt;&lt;li&gt;&lt;b&gt;Programmatic Registration&lt;/b&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;The following code is self explanatory. It will create a cache with default configuration and start the cache. Then it will register the cache with platform MBeanServer. The for loop will add an object to the cache&amp;nbsp; in every 2 sec.&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoTableGrid&quot; style=&quot;background: none repeat scroll 0% 0% rgb(230, 230, 230); border-collapse: collapse; border: medium none;&quot;&gt;&lt;tbody&gt;
&lt;tr style=&quot;height: 44.5pt;&quot;&gt;   &lt;td style=&quot;border: 1pt solid windowtext; height: 44.5pt; padding: 0in 5.4pt; width: 6.15in;&quot; valign=&quot;top&quot; width=&quot;590&quot;&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;package&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; com.ne;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   java.lang.management.ManagementFactory;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   javax.management.MBeanServer;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   javax.management.ObjectName;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   org.jboss.cache.Cache;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   org.jboss.cache.CacheFactory;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   org.jboss.cache.DefaultCacheFactory;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   org.jboss.cache.jmx.JmxRegistrationManager;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;public&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;class&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; TestCache&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;{&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;public&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;static&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;void&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; main(String[]   args) &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;throws&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; Exception&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CacheFactory factory = &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;new&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; DefaultCacheFactory();&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: #3f7f5f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;//&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Cache cache = factory.createCache();&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Cache cache =   factory.createCache();&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cache.start();&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MBeanServer mbserver =   ManagementFactory.&lt;i&gt;getPlatformMBeanServer&lt;/i&gt;();&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectName oname = &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;new&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; ObjectName(&lt;/span&gt;&lt;span style=&quot;color: #2a00ff; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&quot;jboss.cache:service=Cache&quot;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; JmxRegistrationManager jmxManager   = &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;new&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; JmxRegistrationManager(mbserver, cache, oname);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; jmxManager.registerAllMBeans();&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;for&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;(&lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;int&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; i = 0 ; ;   i++)&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; String fqn = Integer.&lt;i&gt;toString&lt;/i&gt;(i);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cache.put(fqn, i, i);&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thread.&lt;i&gt;sleep&lt;/i&gt;(2000);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; System.&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #0000c0; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;out&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;.println(&lt;/span&gt;&lt;span style=&quot;color: #2a00ff; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&quot;one   node added : &quot;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;+i);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;}&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;div style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;There are several other ways to use &lt;/span&gt;&lt;span style=&quot;color: black; font-size: small;&quot;&gt;createCache() api. Such as&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;font-family: inherit;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &#39;Courier New&#39;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: black; font-family: &#39;Courier New&#39;; font-size: 10pt;&quot;&gt;Cache&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &#39;Courier New&#39;; font-size: 10pt;&quot;&gt; cache = factory.createCache(&lt;/span&gt;&lt;span style=&quot;color: #2a00ff; font-family: &#39;Courier New&#39;; font-size: 10pt;&quot;&gt;&quot;cache-configuration.xml&quot;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &#39;Courier New&#39;; font-size: 10pt;&quot;&gt;);&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &#39;Courier New&#39;; font-size: 10pt;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;color: #2a00ff; font-family: &#39;Courier New&#39;; font-size: 10pt;&quot;&gt;cache-configuration.xml &lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;will contain the cache settings, such as cache modes ( local, replicated etc ),&amp;nbsp; cache loaders, eviction policies. All details are available in JBoss Cache &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;a href=&quot;http://community.jboss.org/wiki/JBossCacheOfficialDocumentation&quot; style=&quot;color: blue;&quot;&gt;documentation&lt;/a&gt; and discussion about these cache properties are out of scope of&amp;nbsp; this blog.&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;ul&gt;&lt;li&gt;&lt;b&gt;Register as a spring bean&lt;/b&gt;&lt;/li&gt;
&lt;/ul&gt;The example which I am going to explain in this blog, is a modified form of the bean configuration written in JBoss Cache userguide. As I have mentioned earlier, basic understanding of spring ioc is required to understand this example.&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&amp;nbsp; &lt;b&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;At first, lets see the &lt;span style=&quot;color: #2a00ff; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;Cache-Context.xml&lt;/span&gt; file.&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoTableGrid&quot; style=&quot;background: none repeat scroll 0% 0% rgb(230, 230, 230); border-collapse: collapse; border: medium none;&quot;&gt;&lt;tbody&gt;
&lt;tr style=&quot;height: 44.5pt;&quot;&gt;   &lt;td style=&quot;border: 1pt solid windowtext; height: 44.5pt; padding: 0in 5.4pt; width: 6.15in;&quot; valign=&quot;top&quot; width=&quot;590&quot;&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;?&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;xml&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;version&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;1.0&quot;&lt;/span&gt;&lt;/i&gt;   &lt;span style=&quot;color: #7f007f;&quot;&gt;encoding&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;UTF-8&quot;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: teal;&quot;&gt;?&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;beans&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;xmlns&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;http://www.springframework.org/schema/beans&quot;&lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #7f007f;&quot;&gt;xmlns:xsi&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;http://www.w3.org/2001/XMLSchema-instance&quot;&lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #7f007f;&quot;&gt;xsi:schemaLocation&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;http://www.springframework.org/schema/beans   &lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; http://www.springframework.org/schema/beans/spring-beans.xsd&quot;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;bean&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;name&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;ExampleCacheConfig&quot;&lt;/span&gt;&lt;/i&gt;   &lt;span style=&quot;color: #7f007f;&quot;&gt;class&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;org.jboss.cache.config.Configuration&quot;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: teal;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;bean&lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: #3f5fbf; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;!-- Factory to build the Cache.   --&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;bean&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;name&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;DefaultCacheFactory&quot;&lt;/span&gt;&lt;/i&gt;   &lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #7f007f;&quot;&gt;class&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;org.jboss.cache.DefaultCacheFactory&quot;&lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #7f007f;&quot;&gt;factory-method&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;getInstance&quot;&lt;/span&gt;&lt;/i&gt;   &lt;span style=&quot;color: teal;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;bean&lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: #3f5fbf; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;!-- The cache itself --&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;bean&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;name&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;ExampleCache&quot;&lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #7f007f;&quot;&gt;factory-bean&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;DefaultCacheFactory&quot;&lt;/span&gt;&lt;/i&gt;   &lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;span style=&quot;color: #7f007f;&quot;&gt;factory-method&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;createCache&quot;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: teal;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;constructor-arg&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;ref&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;ExampleCacheConfig&quot;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: teal;&quot;&gt;/&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;constructor-arg&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;value&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;true&quot;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: teal;&quot;&gt;/&amp;gt;&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;bean&lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: #3f5fbf; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;!-- JMX Management --&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;bean&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;name&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;ExampleCacheJmxWrapper&quot;&lt;/span&gt;&lt;/i&gt;   &lt;span style=&quot;color: #7f007f;&quot;&gt;class&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;org.jboss.cache.jmx.CacheJmxWrapper&quot;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: teal;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;constructor-arg&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;span style=&quot;color: #7f007f;&quot;&gt;ref&lt;/span&gt;&lt;span style=&quot;color: black;&quot;&gt;=&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&quot;ExampleCache&quot;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: teal;&quot;&gt;/&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;bean&lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;beans&lt;/span&gt;&lt;span style=&quot;color: teal; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&amp;nbsp;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;Instead of drectly calling the&amp;nbsp; &lt;/span&gt;&lt;b style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;color: #7f0055;&quot;&gt;new&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: inherit;&quot;&gt; DefaultCacheFactory(); one bean is initialized &lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;DefaultCacheFactory&lt;span style=&quot;color: black;&quot;&gt;. &lt;/span&gt;&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: #2a00ff; font-family: inherit;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;A factory-method &lt;/span&gt;&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;createCache &lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;span style=&quot;font-family: inherit; font-size: small;&quot;&gt;is called on this bean which in turn initializes our &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;ExampleCache.&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt; Now &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;CacheJmxWrapper&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt; constructor takes an Cache type object, which is being pushed by the tag &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #3f7f7f; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;constructor-arg&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;. Custom cache definition can be configured inside the &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;ExampleCacheConfig &lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;bean definition. Now your cache is ready and can be accessed using spring APIs &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;acontext.getBean(&lt;/span&gt;&lt;span style=&quot;color: #2a00ff; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&quot;ExampleCache&quot;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #2a00ff; font-family: inherit;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #2a00ff;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;/div&gt;&lt;table border=&quot;1&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;MsoTableGrid&quot; style=&quot;background: none repeat scroll 0% 0% rgb(230, 230, 230); border-collapse: collapse; border: medium none;&quot;&gt;&lt;tbody&gt;
&lt;tr style=&quot;height: 44.5pt;&quot;&gt;   &lt;td style=&quot;border: 1pt solid windowtext; height: 44.5pt; padding: 0in 5.4pt; width: 6.15in;&quot; valign=&quot;top&quot; width=&quot;590&quot;&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;package&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; com.ne;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   org.jboss.cache.Cache;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   org.springframework.context.ApplicationContext;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;import&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   org.springframework.context.support.ClassPathXmlApplicationContext;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;public&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;class&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; TestCache&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;{&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;public&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;static&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;void&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; main(String[]   args) &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;throws&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; Exception&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ApplicationContext acontext = &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;new&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;   ClassPathXmlApplicationContext(&lt;/span&gt;&lt;span style=&quot;color: #2a00ff; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&quot;Cache-Context.xml&quot;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Cache cache = (Cache)acontext.getBean(&lt;/span&gt;&lt;span style=&quot;color: #2a00ff; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&quot;ExampleCache&quot;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;for&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;(&lt;/span&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;int&lt;/span&gt;&lt;/b&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt; i = 0 ; ;   i++)&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; String fqn = Integer.&lt;i&gt;toString&lt;/i&gt;(i);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; cache.put(fqn, i, i);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thread.&lt;i&gt;sleep&lt;/i&gt;(2000);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; System.&lt;/span&gt;&lt;i&gt;&lt;span style=&quot;color: #0000c0; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;out&lt;/span&gt;&lt;/i&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;.println(&lt;/span&gt;&lt;span style=&quot;color: #2a00ff; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&quot;one   node added : &quot;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;+i);&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;}&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;  &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;div class=&quot;MsoNormal&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;ul&gt;&lt;li&gt;&lt;b&gt;&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: inherit;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;JBoss Cache Statistics&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;br /&gt;
JBoss Exposes various runtime statistics which can be viewed graphically through jconsole. The set of all available statistics are documented in cache userguide. A sample jconsole screenshot is attached below.&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;  &lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;  &lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiS0RmwZuRZYsxDDwj0GIsXUqQbR4kY85ORBz4edynK9g1B-fJBCHstEba-UKXUiLTkCkw3Qmp2W7BfK8Ywz6A50Eo2Dvr312saK2ISkB5dhdDyzewNDzLC8fyBoiZFjsgGNPm-dK-ULKjR/s1600/blog-jboss-1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiS0RmwZuRZYsxDDwj0GIsXUqQbR4kY85ORBz4edynK9g1B-fJBCHstEba-UKXUiLTkCkw3Qmp2W7BfK8Ywz6A50Eo2Dvr312saK2ISkB5dhdDyzewNDzLC8fyBoiZFjsgGNPm-dK-ULKjR/s1600/blog-jboss-1.jpg&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
Some lifecycle operations (create/start/stop/destroy) on the cache can also be invoked through jconsole interface. Various details about the cache&#39;s current state (number of nodes, lock information, etc.) can be retrieved accordingly.&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;  &lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;  &lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh2depmA2_qaTv6ROBMfnA5HtsvRi8xlUoN1lcP8WQGrp-xR6ylUzeFNFDLjL4whJCSDoQtt7nwnmW_RazoTuqoG8K3xx5jzksh3on-m_0kX9P3mnHb-O43TqemCApojEXkvhOYlmCndmd2/s1600/blog-jboss-2.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;209&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh2depmA2_qaTv6ROBMfnA5HtsvRi8xlUoN1lcP8WQGrp-xR6ylUzeFNFDLjL4whJCSDoQtt7nwnmW_RazoTuqoG8K3xx5jzksh3on-m_0kX9P3mnHb-O43TqemCApojEXkvhOYlmCndmd2/s640/blog-jboss-2.jpg&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span style=&quot;color: #7f0055; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;  &lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-size: 10pt;&quot;&gt;&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://jshuttle.blogspot.com/feeds/6867131998843437331/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/7650970815911230284/6867131998843437331' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default/6867131998843437331'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/7650970815911230284/posts/default/6867131998843437331'/><link rel='alternate' type='text/html' href='http://jshuttle.blogspot.com/2011/03/registering-thejboss-cache-with.html' title='Registering Jboss Cache with MBeanServer'/><author><name>sanmoy</name><uri>http://www.blogger.com/profile/16061521124526657995</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjE1o9nEG8vF3faAEAHr_fp-pCMtvQLhypCQ1byJGsByeI8WkCMccee0-lEPADLJwD8-GPAIhmDl5YHvH0BOj8gmGYE1kL2VLHWXm_lCKxVmxCv6ZQe2VL0u_axH9hOqw/s1600/*'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiS0RmwZuRZYsxDDwj0GIsXUqQbR4kY85ORBz4edynK9g1B-fJBCHstEba-UKXUiLTkCkw3Qmp2W7BfK8Ywz6A50Eo2Dvr312saK2ISkB5dhdDyzewNDzLC8fyBoiZFjsgGNPm-dK-ULKjR/s72-c/blog-jboss-1.jpg" height="72" width="72"/><thr:total>1</thr:total></entry></feed>