<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/atom10full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" gd:etag="W/&quot;CkYDRnczfip7ImA9WhRbEEw.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412</id><updated>2012-01-31T03:42:57.986-08:00</updated><category term="SQL" /><category term="cloud" /><category term="cache" /><category term="compute grid" /><category term="data grid" /><category term="grid" /><title>GridGain - Real Time Big Data</title><subtitle type="html">GridGain by Dmitriy Setrakyan</subtitle><link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/posts/default" /><link rel="alternate" type="text/html" href="http://gridgain.blogspot.com/" /><link rel="next" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default?start-index=26&amp;max-results=25&amp;redirect=false&amp;v=2" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><generator version="7.00" uri="http://www.blogger.com">Blogger</generator><openSearch:totalResults>100</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/atom+xml" href="http://feeds.feedburner.com/gridify" /><feedburner:info uri="gridify" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:emailServiceId>gridify</feedburner:emailServiceId><feedburner:feedburnerHostname>http://feedburner.google.com</feedburner:feedburnerHostname><entry gd:etag="W/&quot;CUEBRXozcSp7ImA9WhRVFkQ.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-4232888386683636825</id><published>2012-01-15T22:00:00.000-08:00</published><updated>2012-01-15T22:00:54.489-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-01-15T22:00:54.489-08:00</app:edited><title>GridGain 3.6.0 Released!</title><content type="html">I am glad to announce that we have released &lt;a href="http://www.gridgain.com/"&gt;GridGain 3.6.0&lt;/a&gt; -&amp;nbsp;&lt;b style="background-attachment: initial; background-clip: initial; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Real Time Big Data&lt;/b&gt;&lt;span style="background-color: white; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: white; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px;"&gt;platform that allows anyone easily develop, scale and manage compute and data intensive big data applications using&lt;/span&gt;&lt;span style="background-color: white; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px;"&gt;&amp;nbsp;&lt;/span&gt;&lt;b style="background-attachment: initial; background-clip: initial; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;integrated Compute and In-Memory Data Grids&lt;/b&gt;&lt;span style="background-color: white; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="background-color: white; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px;"&gt;with Java, Scala and Groovy native APIs.&lt;/span&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px; margin-bottom: 15px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;
Some of the key new features and enhancements:&lt;/div&gt;
&lt;ul style="background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px; list-style-image: initial; list-style-position: initial; margin-bottom: 15px; margin-left: 16px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;“Write From Behind Caching” was finally added to IMDGs&lt;/li&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;REST batch operation support introduced (putAll, removeAll)&lt;/li&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Eviction filters added&lt;/li&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Segmentation handling for half-connected network sockets&lt;/li&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Improvements in GridGain Visor&lt;/li&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;New eviction performance optimizations&lt;/li&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Significant IMDG preloading performance enhancements&lt;/li&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;New optimization for lock-free reads and low contention writes&lt;/li&gt;
&lt;li style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Cumulative bug fixes and multitude of performance&lt;/li&gt;
&lt;/ul&gt;
&lt;div style="background-attachment: initial; background-clip: initial; background-color: white; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-image: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #666666; font-family: Georgia, 'Times New Roman', serif; font-size: 14px; line-height: 22px; margin-bottom: 15px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;
You can download it &lt;a href="http://www.gridgain.com/downloads.html"&gt;here&lt;/a&gt;.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-4232888386683636825?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/4232888386683636825/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=4232888386683636825" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4232888386683636825?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4232888386683636825?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/_RRukZzjSYU/gridgain-360-released.html" title="GridGain 3.6.0 Released!" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>1</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2012/01/gridgain-360-released.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0cBRnk9cSp7ImA9WhRSGU0.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-4868768840697900309</id><published>2011-11-21T12:55:00.001-08:00</published><updated>2011-11-21T12:57:37.769-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-11-21T12:57:37.769-08:00</app:edited><title>GridGain is hiring</title><content type="html">&lt;div class="separator" style="clear: both; text-align: center;"&gt;
&lt;a href="http://www.gridgain.com/images/faces.gif" imageanchor="1" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"&gt;&lt;img border="0" height="36" src="http://www.gridgain.com/images/faces.gif" width="320" /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div style="background-color: white; color: #222222; font-family: 'Lucida Grande', 'Lucida Sans Unicode', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 1.5; margin-bottom: 15px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;
&lt;a href="http://www.gridgain.com/"&gt;GridGain&lt;/a&gt; Systems is&amp;nbsp;&lt;strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;rapidly growing&lt;/strong&gt;&amp;nbsp;and we are&amp;nbsp;&lt;strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;a href="http://www.gridgain.com/careers.html" style="color: #004477; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;hiring&lt;/a&gt;&lt;/strong&gt;&amp;nbsp;talented Java/Scala top-level engineers in both of our locations:&lt;br /&gt;
- Saint Petersburg, Russia&lt;br /&gt;
- Foster City, CA, USA&lt;/div&gt;
&lt;div style="background-color: white; color: #222222; font-family: 'Lucida Grande', 'Lucida Sans Unicode', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 1.5; margin-bottom: 15px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;
Come work for one of the&amp;nbsp;&lt;strong style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;hotest startups&lt;/strong&gt;&amp;nbsp;in the Silicon Valley! Cutting edge work and top level benefits and compensation. We also guarantee sleepless nights, unsolvable problems and insane debugging of complex distributed systems just in the first week&amp;nbsp;&lt;img alt=":)" class="wp-smiley" src="http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif?m=1305847871g" style="border-bottom-color: rgb(221, 221, 221); border-bottom-style: none; border-bottom-width: 2px; border-color: initial; border-left-color: rgb(221, 221, 221); border-left-style: none; border-left-width: 2px; border-right-color: rgb(221, 221, 221); border-right-style: none; border-right-width: 2px; border-top-color: rgb(221, 221, 221); border-top-style: none; border-top-width: 2px; border-width: initial; margin-bottom: 0px; margin-left: 5px; margin-right: 5px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;" /&gt;&lt;/div&gt;
&lt;div style="background-color: white; color: #222222; font-family: 'Lucida Grande', 'Lucida Sans Unicode', Helvetica, Arial, sans-serif; font-size: 13px; line-height: 1.5; margin-bottom: 15px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;
All the&amp;nbsp;&lt;a href="http://www.gridgain.com/careers.html" style="color: #004477; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;details are here&lt;/a&gt;.&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-4868768840697900309?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/4868768840697900309/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=4868768840697900309" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4868768840697900309?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4868768840697900309?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/vNQVtWYd_Y4/gridgain-is-hiring.html" title="GridGain is hiring" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/11/gridgain-is-hiring.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C08BQn8_fSp7ImA9WhRSEE0.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-2913270628549012532</id><published>2011-11-11T00:53:00.001-08:00</published><updated>2011-11-11T00:57:33.145-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-11-11T00:57:33.145-08:00</app:edited><title>GridGain 3.5 Released!</title><content type="html">We’ve just released &lt;a href="http://www.gridgain.com/"&gt;GridGain 3.5&lt;/a&gt; – our latest stable release of GridGain’s Real Time Big Data platform that allows anyone easily develop, scale and manage compute and data intensive JVM based applications using integrated Compute and In-Memory Data Grid with Java, Scala and Groovy native APIs.&lt;br /&gt;
&lt;br /&gt;
Some of the key new features and enhancements:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Significant performance improvements throughout the product&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Previously deprecated APIs have been removed&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Improvements and bug fixes in GridGain Visor&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Enhancements to GridProjection interface&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Ability to programmatically start remote nodes in bulk&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Customizable closure-based MapReduce&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Enhancements in affinity and co-location&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Bug fixes in eviction policies in Data Grid&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Significant improvements and performance enhancements in Swap SPI&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://www.gridgain.com/downloads.shtml"&gt;Download&lt;/a&gt; &amp;nbsp;GridGain 3.5 today!&lt;br /&gt;
&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-2913270628549012532?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/2913270628549012532/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=2913270628549012532" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/2913270628549012532?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/2913270628549012532?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/MsvwkczXdO8/gridgain-35-released.html" title="GridGain 3.5 Released!" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/11/gridgain-35-released.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CUYNRXw-eSp7ImA9WhdaEUU.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-8167068018476526144</id><published>2011-10-21T00:45:00.000-07:00</published><updated>2011-10-21T00:46:34.251-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-10-21T00:46:34.251-07:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="cloud" /><category scheme="http://www.blogger.com/atom/ns#" term="cache" /><category scheme="http://www.blogger.com/atom/ns#" term="grid" /><category scheme="http://www.blogger.com/atom/ns#" term="data grid" /><category scheme="http://www.blogger.com/atom/ns#" term="compute grid" /><title>PDC Theorem – The Underlying Principle of Real-Time Distributed Processing</title><content type="html">Nikita, CEO at &lt;a href="http://www.gridgain.com"&gt;GridGain Systems&lt;/a&gt;, wrote a cool blog on &lt;a href="http://gridgaintech.wordpress.com/2011/10/19/pdc-theorem-the-underlying-principle-of-real-time-distributed-processing/"&gt;PDC Theorem – The Underlying Principle of Real-Time Distributed Processing&lt;/a&gt; where he talks in some detail about important principles of distributed programming, such as real-time processing, data partitioning, and collocation of computations and data. Take a look at it - should be a good and interesting read.&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-8167068018476526144?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/8167068018476526144/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=8167068018476526144" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/8167068018476526144?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/8167068018476526144?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/7wSamH9BX7Y/pdc-theorem-underlying-principle-of.html" title="PDC Theorem – The Underlying Principle of Real-Time Distributed Processing" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/10/pdc-theorem-underlying-principle-of.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0YNRng4cSp7ImA9WhdXGUQ.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-4024271401548236678</id><published>2011-08-29T16:39:00.000-07:00</published><updated>2011-09-02T13:26:37.639-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-09-02T13:26:37.639-07:00</app:edited><title>How about distributed queues?</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/-RVx7t0pSyZc/TlwnUguhQbI/AAAAAAAAACw/7POL2WAijuM/s1600/queue-icon.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 128px; height: 128px;" src="http://2.bp.blogspot.com/-RVx7t0pSyZc/TlwnUguhQbI/AAAAAAAAACw/7POL2WAijuM/s200/queue-icon.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5646431266151678386" /&gt;&lt;/a&gt;Did you ever wish you could take a data structure you are familiar with and distribute it over grid? For example, why not take &lt;span style="font-style:italic;"&gt;java.util.concurrent.BlockingDeque&lt;/span&gt; and add something to it on one node and poll it from another node? Or why not have a distributed primary key generator which would guarantee uniqueness on all nodes? Or how about a distributed &lt;span style="font-style:italic;"&gt;java.util.concurrent.atomic.AtomicLong&lt;/span&gt; which can be updated and read from any node on the grid? GridGain gives you such capability. What &lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; did is actually take most of the data structures from &lt;span style="font-style:italic;"&gt;java.util.concurrent&lt;/span&gt; framework and made sure they could be used in distributed fashion.
&lt;br /&gt;
&lt;br /&gt;In this blog I want to show how flexible GridGain distributed queues are. On top implementing &lt;span style="font-style:italic;"&gt;java.util.Collection&lt;/span&gt; interface and supporting different modes of operation, like collocated vs. non-collocated, or bounded vs. ubounded modes, you can actually control how elements are ordered within queues. GridGain supports &lt;span style="font-weight:bold;"&gt;FIFO&lt;/span&gt;, &lt;span style="font-weight:bold;"&gt;LIFO&lt;/span&gt;, and &lt;span style="font-weight:bold;"&gt;Priority&lt;/span&gt; based queues out of the box. 
&lt;br /&gt;
&lt;br /&gt;FIFO queues (first-in-first-out) are the most traditional queues where elements are added from the tail and polled form the queue head. LIFO queues (last-in-first-out) resemble more of stack features instead of queues. In LIFO queues elements are added and polled from the tail. 
&lt;br /&gt;
&lt;br /&gt;But the most interesting queue type is Priority queue where user can control the order of the elements. Priority queues order elements within the queue based on priority attribute specified by the user. Priority attribute of a queue element is annotated via &lt;a href="http://www.gridgain.com/javadoc30E/org/gridgain/grid/cache/datastructures/GridCacheQueuePriority.html"&gt;@GridCacheQueuePriority&lt;/a&gt; annotation. Here is an example of how priority queue can be created and used.
&lt;pre class="java" name="code"&gt;
public void priorityQueueExample() {
    Random rand = new Random();

    Grid grid = G.grid();

    // Initialize new unbounded collocated priority queue.
    GridCacheQueue&amp;lt;PriorityItem&amp;gt; queue = 
        grid.cache().queue("myqueue", PRIORITY);

    // Store 20 elements in queue with random priority.
    for (int i = 0; i &amp;lt; 20; i++) {
        int priority = rand.nextInt(20);

        queue.put(new PriorityItem(priority, "somedata-" + i));
    }

    PriorityItem item = null;

    int lastPriority = 0;

    do {
        item = queue.poll();

        // Ensure the elements are correctly ordered based on priority.
        assert lastPriority &amp;lt;= item.priority();

        lastPriority = item.priority();
    }
    while (item != null);
}

...

// Class defining sample queue element with its priority specified via
// @GridCacheQueuePriority annotation attached to priority field.
private static class PriorityItem implements Serializable {
    // Priority of queue item.
    @GridCacheQueuePriority
    private final int priority;

    private final String data;

    private SampleItem(int priority, String data) {
        this.priority = priority;
        this.data = data;
    }

    public int priority() {
        return priority;
    }
}
&lt;/pre&gt;
&lt;br /&gt;Read more about GridGain queues &lt;a href="http://www.gridgain.com/book/book.html#_distributed_data_structures"&gt;here&lt;/a&gt;.
&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-4024271401548236678?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/4024271401548236678/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=4024271401548236678" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4024271401548236678?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4024271401548236678?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/pgfFqRFTwdo/how-about-distributed-queues.html" title="How about distributed queues?" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-RVx7t0pSyZc/TlwnUguhQbI/AAAAAAAAACw/7POL2WAijuM/s72-c/queue-icon.png" height="72" width="72" /><thr:total>1</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/08/how-about-distributed-queues.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0UCQ3w7fCp7ImA9WhdXFks.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-8741443874683675463</id><published>2011-08-15T11:47:00.000-07:00</published><updated>2011-08-29T17:47:42.204-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-08-29T17:47:42.204-07:00</app:edited><title>Clever Singletons on the Grid</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/-CVd33L-jNrQ/TklwVvqEoRI/AAAAAAAAAB8/KfZaJptaGUM/s1600/Alien-smoking-icon.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 96px; height: 96px;" src="http://2.bp.blogspot.com/-CVd33L-jNrQ/TklwVvqEoRI/AAAAAAAAAB8/KfZaJptaGUM/s200/Alien-smoking-icon.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5641163527130751250" /&gt;&lt;/a&gt;When working in distributed environment often you need to have a consistent local state per grid node that is reused between various job executions. For example, what if multiple jobs require database connection pool for their execution - how do they get this connection pool to be initialized once and then reused by all jobs running on the same grid node? Essentially you can think about it as a per-grid-node singleton service, but the idea is not limited to services only, it can be just a regular Java bean that holds some state to be shared by all jobs running on the same grid node.
&lt;br /&gt;
&lt;br /&gt;In &lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; versions 2.x and earlier this approach was handled by using &lt;a href="http://www.gridgain.com/javadoc30E/org/gridgain/grid/resources/GridUserResource.html"&gt;@GridUserResource&lt;/a&gt; annotation to annotate fields within &lt;a href="http://www.gridgain.com/javadoc30E/org/gridgain/grid/GridTask.html"&gt;GridTask&lt;/a&gt; or &lt;a href="http://www.gridgain.com/javadoc30E/org/gridgain/grid/GridJob.html"&gt;GridJob&lt;/a&gt; classes to specify singleton beans. However, this approach was dependent on &lt;a href="http://www.gridgain.com/javadoc30E/org/gridgain/grid/GridDeploymentMode.html"&gt;GridDeploymentMode&lt;/a&gt; configuration and, for &lt;span style="font-style:italic;"&gt;ISOLATED&lt;/span&gt; or &lt;span style="font-style:italic;"&gt;PRIVATE&lt;/span&gt; deployment modes, resource could be initialized multiple times, once per &lt;span style="font-style:italic;"&gt;GridTask&lt;/span&gt;. This forced users to use various hacks in their logic and generally was not very convenient to use.
&lt;br /&gt;
&lt;br /&gt;Starting with GridGain 3.0, &lt;a href="http://www.gridgain.com/javadoc30E/org/gridgain/grid/GridNodeLocal.html"&gt;GridNodeLocal&lt;/a&gt; per-grid-node local storage was introduced. The name was borrowed from &lt;a href="http://download.oracle.com/javase/6/docs/api/java/lang/ThreadLocal.html"&gt;ThreadLocal&lt;/a&gt; class in Java, because just like &lt;span style="font-style:italic;"&gt;ThreadLocal&lt;/span&gt; provides unique per-thread space in Java, &lt;span style="font-style:italic;"&gt;GridNodeLocal&lt;/span&gt; provides unique per-grid-node space in GridGain. &lt;span style="font-style:italic;"&gt;GridNodeLocal&lt;/span&gt; implements &lt;span style="font-style:italic;"&gt;java.util.concurrent.ConcurrentMap&lt;/span&gt; interface and is absolutely lock-free. In fact, it simply extends &lt;a href="http://download.oracle.com/javase/6/docs/api/java/util/concurrent/ConcurrentHashMap.html"&gt;java.util.concurrent.ConcurrentHashMap&lt;/a&gt; implementation and, therefore, inherits all the methods available there.
&lt;br /&gt;
&lt;br /&gt;Here is an example of how &lt;span style="font-style:italic;"&gt;GridNodeLocal&lt;/span&gt; could be used to create some user specific singleton service from a simple GridGain job:&lt;pre name="code" class="java:nogutter"&gt;final Grid grid = G.start(..);

// Execute runnable job on some remote grid node.
grid.run(BALANCE, new Runnable() {
  public void run() {
    GridNodeLocal&amp;lt;String, MySingleton&amp;gt; nodeLocal = grid.nodeLocal();

    // 1. Check if f someone already created our singleton service. 
    MySingleton service = nodeLocal.get(&amp;quot;myservice&amp;quot;);

    if (service == null) {
      // 2. Create new singleton service.
      MySingleton other = 
        nodeLocal.putIfAbsent(&amp;quot;myservice&amp;quot;, service = new MySingleton(..));

      if (other != null) 
        service = other;
    }

    // Perform operations with our singleton service.
    ...
  }
});&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-8741443874683675463?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/8741443874683675463/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=8741443874683675463" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/8741443874683675463?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/8741443874683675463?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/TvRbQSDLIuE/clever-singletons-on-grid.html" title="Clever Singletons on the Grid" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-CVd33L-jNrQ/TklwVvqEoRI/AAAAAAAAAB8/KfZaJptaGUM/s72-c/Alien-smoking-icon.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/08/clever-singletons-on-grid.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0ENSHs5fyp7ImA9WhdXFks.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-1336885854170585581</id><published>2011-06-22T20:03:00.000-07:00</published><updated>2011-08-29T17:54:59.527-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-08-29T17:54:59.527-07:00</app:edited><title>Even better AtomicInteger and AtomicLong in Java</title><content type="html">Last week I blogged about &lt;a href="http://gridgain.blogspot.com/2011/06/better-atomiclong-and-atomicinteger-in.html"&gt;"Better AtomicInteger and AtomicLong in Java"&lt;/a&gt; and how I added it to &lt;a href="http://www.gridgain.com/"&gt;GridGain&lt;/a&gt; &lt;span style="font-style:italic;"&gt;'lang.utils'&lt;/span&gt; package to be used within GridGain project and by our user base. Recently I made it even better. The standard JDK atomic &lt;span style="font-style:italic;"&gt;'compareAndSet(..)'&lt;/span&gt; operations always check for some 'expected' value and if it matches, then the set happens. What if you simply want to set a value if its greater or less than current value, or if it simply does not match the current value?
&lt;br /&gt;
&lt;br /&gt;Again, code looks pretty simple:
&lt;pre class="java" name="code"&gt;
public class MyAtomicInteger extends AtomicInteger {
  ... // Omitting methods from previous blog
  public boolean setIfGreater(int update) {         
     while (true) {             
          int cur = get();

          if (update &amp;gt; cur) {
              if (compareAndSet(cur, update))
                  return true;
          }
          else
              return false;
      }
  }

  public boolean setIfGreaterEquals(int update) {
      while (true) {
          int cur = get();

          if (update &amp;gt;= cur) {
              if (compareAndSet(cur, update))
                  return true;
          }
          else
              return false;
      }
  }

  public boolean setIfLess(int update) {
      while (true) {
          int cur = get();
          
          if (update &amp;lt; cur) {
              if (compareAndSet(cur, update))
                 return true;
          }
          else
              return false;
      }
  }      
  
  public boolean setIfLessEquals(int update) {
      while (true) {
          int cur = get();

          if (update &amp;lt;= cur) {
              if (compareAndSet(cur, update))
                  return true;
          }
          else
              return false;
      }
  }

  public boolean setIfNotEquals(int update) {
      while (true) {
        int cur = get();

        if (update != cur) {
            if (compareAndSet(cur, update))
                return true;
        }
        else
            return false;
      }
  }
}
&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-1336885854170585581?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/1336885854170585581/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=1336885854170585581" title="13 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/1336885854170585581?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/1336885854170585581?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/Zahv6SS2bNQ/even-better-atomicinteger-and.html" title="Even better AtomicInteger and AtomicLong in Java" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>13</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/06/even-better-atomicinteger-and.html</feedburner:origLink></entry><entry gd:etag="W/&quot;AkMMRX0zeCp7ImA9WhZbFU4.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-6070403977220329190</id><published>2011-06-18T15:27:00.000-07:00</published><updated>2011-06-19T19:54:44.380-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-06-19T19:54:44.380-07:00</app:edited><title>Better AtomicLong and AtomicInteger in Java</title><content type="html">I was always annoyed by the fact that AtomicLong.compareAndSet(...) method in Java only checked for exact equality. What if you need to check if the value is less than or greater than? So I finally just created my own AtomicLong and AtomicInteger classes and added them to &lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; utilities to be used by us and by all our users.&lt;br /&gt;&lt;br /&gt;The code is very simple:&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;public class MyAtomicLong extends AtomicLong {&lt;br /&gt;    public boolean greaterAndSet(long check, long update) {&lt;br /&gt;        while (true) {&lt;br /&gt;            long cur = get();&lt;br /&gt;&lt;br /&gt;            if (check &gt; cur) {&lt;br /&gt;                if (compareAndSet(cur, update))&lt;br /&gt;                    return true;&lt;br /&gt;            }&lt;br /&gt;            else&lt;br /&gt;                return false;&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    public boolean greaterEqualsAndSet(long check, long update) {&lt;br /&gt;        while (true) {&lt;br /&gt;            long cur = get();&lt;br /&gt;&lt;br /&gt;            if (check &gt;= cur) {&lt;br /&gt;                if (compareAndSet(cur, update))&lt;br /&gt;                    return true;&lt;br /&gt;            }&lt;br /&gt;            else&lt;br /&gt;                return false;&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    public boolean lessAndSet(long check, long update) {&lt;br /&gt;        while (true) {&lt;br /&gt;            long cur = get();&lt;br /&gt;&lt;br /&gt;            if (check &lt; cur) {&lt;br /&gt;                if (compareAndSet(cur, update))&lt;br /&gt;                    return true;&lt;br /&gt;            }&lt;br /&gt;            else&lt;br /&gt;                return false;&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;    public boolean lessEqualsAndSet(long check, long update) {&lt;br /&gt;        while (true) {&lt;br /&gt;            long cur = get();&lt;br /&gt;&lt;br /&gt;            if (check &lt;= cur) {&lt;br /&gt;                if (compareAndSet(cur, update))&lt;br /&gt;                    return true;&lt;br /&gt;            }&lt;br /&gt;            else&lt;br /&gt;                return false;&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Based on the comments I received, I have also added predicate-based &lt;span style="font-style:italic;"&gt;'checkAndSet(...)'&lt;/span&gt; method:&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;    public boolean checkAndSet(GridPredicate&amp;lt;Long&amp;gt; p, long update) {&lt;br /&gt;        while (true) {&lt;br /&gt;            long cur = get();&lt;br /&gt;&lt;br /&gt;            if (p.apply(cur)) {&lt;br /&gt;                if (compareAndSet(cur, update))&lt;br /&gt;                    return true;&lt;br /&gt;            }&lt;br /&gt;            else&lt;br /&gt;                return false;&lt;br /&gt;        }&lt;br /&gt;    }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Of course in GridGain these classes are named &lt;span style="font-style:italic;"&gt;GridAtomicInteger&lt;/span&gt; and &lt;span style="font-style:italic;"&gt;GridAtomicLong&lt;/span&gt;, since we prefix all our classes with the word &lt;span style="font-style:italic;"&gt;Grid&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-6070403977220329190?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/6070403977220329190/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=6070403977220329190" title="9 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/6070403977220329190?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/6070403977220329190?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/tkGxw3te5K4/better-atomiclong-and-atomicinteger-in.html" title="Better AtomicLong and AtomicInteger in Java" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>9</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/06/better-atomiclong-and-atomicinteger-in.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkIGQ3c7cSp7ImA9WhZUFkk.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-7035291524257953884</id><published>2011-06-09T11:34:00.000-07:00</published><updated>2011-06-09T11:35:22.909-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-06-09T11:35:22.909-07:00</app:edited><title>Remote Actors vs. GridGain and Concurrency Unification</title><content type="html">&lt;span class="Apple-style-span" style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Helvetica, Arial, sans-serif; font-size: 13px; "&gt;&lt;p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 0px; line-height: 1.5; "&gt;We are migrating and finishing the upcoming GridGain’s book “Pragmatic Cloud Computing with GridGain using Java and Scala”. Here’s a short chapter that I’ve just finished on the subject of:&lt;/p&gt;&lt;p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 0px; line-height: 1.5; "&gt;&lt;a href="http://bit.ly/jH014v" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; color: rgb(0, 68, 119); text-decoration: underline; "&gt;“Remote Actors vs. GridGain and Concurrency Unification”&lt;/a&gt;&lt;/p&gt;&lt;p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 0px; line-height: 1.5; "&gt;Enjoy!&lt;/p&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-7035291524257953884?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/7035291524257953884/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=7035291524257953884" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/7035291524257953884?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/7035291524257953884?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/yLqYHm132V8/remote-actors-vs-gridgain-and.html" title="Remote Actors vs. GridGain and Concurrency Unification" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/06/remote-actors-vs-gridgain-and.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A04CR3g_cCp7ImA9WhZVGUg.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-8295154776729949210</id><published>2011-06-01T13:23:00.000-07:00</published><updated>2011-06-01T13:26:06.648-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-06-01T13:26:06.648-07:00</app:edited><title>GridGain 3.1.0 Released</title><content type="html">&lt;a href="http://www.gridgain.com/images/logo2_bw_no_ver.png" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 177px; height: 50px;" src="http://www.gridgain.com/images/logo2_bw_no_ver.png" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: rgb(34, 34, 34); font-family: 'Lucida Grande', 'Lucida Sans Unicode', Helvetica, Arial, sans-serif; font-size: 13px; "&gt;&lt;p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 0px; line-height: 1.5; "&gt;We’ve just released &lt;a href="http://www.gridgain.com/downloads.html" title="Download GridGain 3.1.0" target="_blank" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; color: rgb(0, 68, 119); text-decoration: underline; "&gt;GridGain 3.1.0&lt;/a&gt; – our latest stable release of GridGain’s &lt;b style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "&gt;High Performance Cloud Computing&lt;/b&gt; platform that allows anyone easily develop, scale and manage compute and data intensive JVM based applications.&lt;/p&gt;&lt;p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 0px; line-height: 1.5; "&gt;Some of the key new features and enhancements (combined with 3.0.9 announcement last week):&lt;/p&gt;&lt;ul style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 30px; line-height: 18px; "&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Improvements in stability and performance for Data Grid&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;New &lt;a href="http://www.gridgain.com/javadoc30E/org/gridgain/grid/cache/datastructures/package-summary.html" target="_blank" in_tag="ul" checked_link="http://www.gridgain.com/javadoc30E/org/gridgain/grid/cache/datastructures/package-summary.html" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; color: rgb(0, 68, 119); text-decoration: underline; "&gt;Distributed Data Structures&lt;/a&gt;:&lt;ul style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 30px; line-height: 18px; "&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;GridCacheAtomicLong&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;GridCacheAtomicReference&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;GridCacheAtomicSequence&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;GridCacheAtomicStamped&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;GridCacheQueue&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Fully distributed &lt;a href="http://www.gridgain.com/javadoc30E/org/gridgain/grid/lang/package-summary.html" target="_blank" in_tag="ul" kaspersky_status="skipped" checked_link="http://www.gridgain.com/javadoc30E/org/gridgain/grid/lang/package-summary.html" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; color: rgb(0, 68, 119); text-decoration: underline; "&gt;Functional Programming framework&lt;/a&gt; for Java&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Distributed Java closure execution&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Improved AOP-based distributed execution&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Improved Data Grid querying support for:&lt;ul style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 30px; line-height: 18px; "&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Native SQL (including full joints support)&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Predicate-based Full Scan&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Lucene&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;H2 text&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Support for local and remote reduction and transformations in Data Grid queries&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Improved Scala-based DSL for Compute and Data Grid:&lt;ul style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 30px; line-height: 18px; "&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Enhanced distributed closure execution with zero deployment&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Ad-hoc Data Grid queries&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Interactive GridGain Scala REPL&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Work with Compute and Data Grid from Scala REPL&lt;/li&gt;&lt;/ul&gt;&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Dramatically enhanced GridGain Visor for distributed monitoring and management&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Brand new TCP/IP guaranteed discovery SPI for large cloud-based deployments&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;New enterprise licensing mechanism with dynamic hot-upgradability&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;New optimized marshaling&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;Improved documentation and examples&lt;/li&gt;&lt;/ul&gt;&lt;p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 0px; line-height: 1.5; "&gt;&lt;a href="http://www.gridgain.com/downloads.html" title="Download GridGain 3.1.0" target="_blank" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; color: rgb(0, 68, 119); text-decoration: underline; "&gt;GridGain 3.1.0&lt;/a&gt; comes in two editions:&lt;/p&gt;&lt;ul style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 30px; line-height: 18px; "&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;&lt;b style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "&gt;Free Community Edition&lt;/b&gt;, GPLv3 licensed&lt;/li&gt;&lt;li style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 5px; margin-left: 0px; "&gt;&lt;b style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "&gt;Enterprise Edition&lt;/b&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 15px; margin-left: 0px; line-height: 1.5; "&gt;Enjoy!&lt;/p&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-8295154776729949210?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/8295154776729949210/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=8295154776729949210" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/8295154776729949210?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/8295154776729949210?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/F1McS2Bic_Q/gridgain-310-released.html" title="GridGain 3.1.0 Released" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/06/gridgain-310-released.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0ACQngyeip7ImA9WhZVGUg.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-1137639896359203668</id><published>2011-06-01T13:20:00.001-07:00</published><updated>2011-06-01T13:22:43.692-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-06-01T13:22:43.692-07:00</app:edited><title>Presenting at Scala Days 2011</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.gridgain.com/images/scalar.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 314px; height: 40px;" src="http://www.gridgain.com/images/scalar.png" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; will be presenting at Scala Days 2011 on June 2nd, 2011. The event is hosted by Stanford University. The presentation starts at Session 3: Parallelism track at 3:50pm.&lt;br /&gt;&lt;br /&gt;If you are around – stop by to see a non-stop Scala distributed coding. Should be fun!&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-1137639896359203668?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/1137639896359203668/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=1137639896359203668" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/1137639896359203668?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/1137639896359203668?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/RfCUH9tNIYQ/presenting-at-scala-days-2011.html" title="Presenting at Scala Days 2011" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/06/presenting-at-scala-days-2011.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkACQXk4fyp7ImA9WhZVGEU.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-3106529784731341149</id><published>2011-05-31T11:17:00.000-07:00</published><updated>2011-05-31T15:26:00.737-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-05-31T15:26:00.737-07:00</app:edited><title>Cool GridGain Transaction Example</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.gridgain.com"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 96px; height: 96px;" src="http://3.bp.blogspot.com/-3cFgfRB7IKc/TeU26qjlWcI/AAAAAAAAABw/jGHwrbdgegw/s200/cool-icon.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5612952892071041474" /&gt;&lt;/a&gt;I never planned to create an example like this, but one of the users in our community forums &lt;a href="http://is.gd/2XMsKz"&gt;pushed me to do it&lt;/a&gt;. Basically the user was complaining that he gets some deadlock behavior on the grid when he reads and updates the same object from cache on multiple grid nodes in parallel. Naturally I got worried and created the following test, which passes by the way :)&lt;br /&gt;&lt;br /&gt;In this example we basically store array of size N in cache and execute N jobs on the grid, each of which gets an array from cache and flips the array cell assigned to it from zero to one. As a result you start out with an array of all zeros and you end up with array of all ones. The cache is configured in PARTITIONED mode with synchronous commits. By default, every key stored in the cache is backed up on another node. Here is how the code looks like:&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;// Number of grids in the test.&lt;br /&gt;private static final int GRID_COUNT = 4;&lt;br /&gt;&lt;br /&gt;public void testTransactions() throws GridException {&lt;br /&gt;    // Start multiple grid nodes in the same JVM.&lt;br /&gt;    for (int i = 0; i &lt; GRID_COUNT; i++) {&lt;br /&gt;        GridConfigurationAdapter cfg = new GridConfigurationAdapter();&lt;br /&gt;&lt;br /&gt;        // I am specifically omitting other configuration details. &lt;br /&gt;        cfg.setGridName("grid-" + i);&lt;br /&gt;&lt;br /&gt;        G.start(cfg);&lt;br /&gt;    }&lt;br /&gt; &lt;br /&gt;    try {&lt;br /&gt;        // Try job count N = 1000&lt;br /&gt;        checkTransactions(1000);&lt;br /&gt;    }&lt;br /&gt;    finally {&lt;br /&gt;        G.stopAll(true);&lt;br /&gt;    }&lt;br /&gt;}&lt;br /&gt; &lt;br /&gt;private void checkTransactions(final int jobCnt) throws GridException {&lt;br /&gt;    // Get frist grid node.&lt;br /&gt;    Grid grid = G.grid("grid-0");&lt;br /&gt; &lt;br /&gt;    final GridCache&amp;lt;String, int[]&amp;gt; cache = grid.cache();&lt;br /&gt; &lt;br /&gt;    Collection&amp;lt;GridFuture&amp;lt;?&amp;gt;&amp;gt; futs = new LinkedList&amp;lt;GridFuture&amp;lt;?&amp;gt;&amp;gt;();&lt;br /&gt; &lt;br /&gt;    for (int i = 0; i &amp;lt; jobCnt; i++) {&lt;br /&gt;        // Run these jobs in parallel on all grid nodes.&lt;br /&gt;        GridFuture&amp;lt;?&amp;gt; fut = grid.runAsync(&lt;br /&gt;            GridClosureCallMode.BALANCE, &lt;br /&gt;            new GridInClosureX&amp;lt;Integer&amp;gt;() {&lt;br /&gt;                @Override &lt;br /&gt;                public void applyx(Integer i) throws GridException {&lt;br /&gt;                    GridCacheTx tx = &lt;br /&gt;                        cache.startTx(PESSIMISTIC, REPEATABLE_READ);&lt;br /&gt;&lt;br /&gt;                    try {&lt;br /&gt;                        int[] arr = cache.get("TestKey");&lt;br /&gt; &lt;br /&gt;                        if (arr == null)&lt;br /&gt;                            arr = new int[jobCnt];&lt;br /&gt; &lt;br /&gt;                        arr[i] = 1;&lt;br /&gt; &lt;br /&gt;                        cache.put("TestKey", arr);&lt;br /&gt;&lt;br /&gt;                        tx.commit();&lt;br /&gt;                    }&lt;br /&gt;                    finally {&lt;br /&gt;                        tx.end();&lt;br /&gt;                    }&lt;br /&gt;                }&lt;br /&gt;            }, &lt;br /&gt;            i);&lt;br /&gt; &lt;br /&gt;        futs.add(fut);&lt;br /&gt;    }&lt;br /&gt; &lt;br /&gt;    for (GridFuture&amp;lt;?&amp;gt; fut : futs)&lt;br /&gt;        fut.get(); // Wait for completion.&lt;br /&gt; &lt;br /&gt;    // Get array from cache.&lt;br /&gt;    int[] arr = cache.get("TestKey");&lt;br /&gt; &lt;br /&gt;    assert arr != null;&lt;br /&gt;    assert jobCnt == arr.length;&lt;br /&gt; &lt;br /&gt;    // Make sure that all array cells got flipped to 1.&lt;br /&gt;    for (int i : arr)&lt;br /&gt;        assert i == 1;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;By the way, we have recently released &lt;a href="http://www.gridgain.com"&gt;GridGain 3.1.0&lt;/a&gt;, so give it a try.&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-3106529784731341149?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/3106529784731341149/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=3106529784731341149" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/3106529784731341149?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/3106529784731341149?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/cJm-CwRrp50/cool-gridgain-transaction-example.html" title="Cool GridGain Transaction Example" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/-3cFgfRB7IKc/TeU26qjlWcI/AAAAAAAAABw/jGHwrbdgegw/s72-c/cool-icon.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/05/cool-gridgain-transaction-example.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkYDR3c_cSp7ImA9WhZWGEg.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-168658007576483880</id><published>2011-05-19T17:05:00.001-07:00</published><updated>2011-05-19T17:09:36.949-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-05-19T17:09:36.949-07:00</app:edited><title>GridGain 3.0.9 released</title><content type="html">&lt;a href="http://www.gridgain.com/images/logo2_bw_no_ver.png" onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 177px; height: 50px;" src="http://www.gridgain.com/images/logo2_bw_no_ver.png" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Long anticipated GridGain 3.0.9 has been released today.&lt;br /&gt;&lt;br /&gt;Some of the highlights of this release:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Massive improvements in stability and performance for Data Grid.&lt;/li&gt;&lt;li&gt;New distributed data structures:&lt;/li&gt;&lt;li&gt;Distributed Atomic&lt;/li&gt;&lt;li&gt;Distributed Queues&lt;/li&gt;&lt;li&gt;Much improved Data Grid querying support.&lt;/li&gt;&lt;li&gt;Improved Scalar DSL.&lt;/li&gt;&lt;li&gt;Dramatically enhanced monitoring &amp;amp; management via GridGain Visor.&lt;/li&gt;&lt;li&gt;Brand new TCP-based discovery SPI with support for large cloud-based deployments.&lt;/li&gt;&lt;li&gt;Improved documentation and examples.&lt;/li&gt;&lt;li&gt;New licensing support with dynamic hot-upgrade capabilities.&lt;/li&gt;&lt;li&gt;New optimized marshaling.&lt;/li&gt;&lt;li&gt;Go ahead and &lt;a href="http://www.gridgain.com/"&gt;download GridGain 3.0.9.&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;Enjoy!&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-168658007576483880?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/168658007576483880/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=168658007576483880" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/168658007576483880?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/168658007576483880?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/d7hVWyAGoP8/gridgain-309-released.html" title="GridGain 3.0.9 released" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/05/gridgain-309-released.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0EFQn07eip7ImA9WhZXE0s.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-436535389277765021</id><published>2011-05-02T11:35:00.000-07:00</published><updated>2011-05-02T11:40:13.302-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-05-02T11:40:13.302-07:00</app:edited><title>Sitting on the cloud with Nikita Ivanov</title><content type="html">Nikita Ivanov, CEO at &lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; gave a pretty cool interview on Cloud Computing and how GridGain fits in it. You can read the interview at Dzone: &lt;a href="http://jetbrains.dzone.com/articles/sitting-cloud-nikita-ivanov"&gt;http://jetbrains.dzone.com/articles/sitting-cloud-nikita-ivanov&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Enjoy!&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-436535389277765021?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/436535389277765021/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=436535389277765021" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/436535389277765021?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/436535389277765021?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/xBvu_PZyRG8/sitting-on-cloud-with-nikita-ivanov.html" title="Sitting on the cloud with Nikita Ivanov" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/05/sitting-on-cloud-with-nikita-ivanov.html</feedburner:origLink></entry><entry gd:etag="W/&quot;AkMEQHkzeip7ImA9WhZQFEs.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-6460916768849916155</id><published>2011-04-20T16:53:00.000-07:00</published><updated>2011-04-22T03:33:21.782-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-04-22T03:33:21.782-07:00</app:edited><title>Asynchronous Functional APIs in Java</title><content type="html">The major limitation of &lt;span style="font-style:italic;"&gt;java.util.concurrent.Future&lt;/span&gt; class is lack of a good way to listen for future completion asynchronously. Even though Java futures are asynchronous in nature and meant to eliminate synchronous waits, the only way to get a future result is to synchronously wait for future completion. In many cases this defeats the purpose and Java futures cannot be used.&lt;br /&gt;&lt;br /&gt;To avoid this problem in &lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; we created our own future which allows for asynchronous listening for future completion. In addition to that we have also resolved the inconveniences of error handling and added &lt;span style="font-style:italic;"&gt;'duration()'&lt;/span&gt;method to tell users how long the future took to execute. Here is how you can add a listener to get notified, say for completion of &lt;span style="font-style:italic;"&gt;putAsync(..)&lt;/span&gt; operation on distributed cache:&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;...&lt;br /&gt;GridCache&amp;lt;Integer, String&amp;gt; cache = grid.cache();&lt;br /&gt;&lt;br /&gt;// Asynchronously put a value into cache.&lt;br /&gt;GridFuture&amp;lt;String&amp;gt; fut = cache.putAsync(1, "1");&lt;br /&gt;&lt;br /&gt;// Pass in a closure which will be called whenever future completes.&lt;br /&gt;fut.listenAsync(new GridInClosureX&amp;lt;GridFuture&amp;lt;String&amp;gt;&amp;gt;() {&lt;br /&gt;    public void applyx(GridFuture&amp;lt;String&amp;gt; fut) throws GridException {&lt;br /&gt;        V previousValue = fut.get();&lt;br /&gt;&lt;br /&gt;        long duration = fut.duration();&lt;br /&gt;&lt;br /&gt;        System.out.println("Finished cache put operation [prev=" + &lt;br /&gt;            previousValue +  ", duration=" + duration + "ms]"); &lt;br /&gt;    }&lt;br /&gt;});&lt;br /&gt;...&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;GridFuture is used for all asynchronous operations in GridGain, including both, compute and data grid features. Hope you find it useful.&lt;br /&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-6460916768849916155?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/6460916768849916155/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=6460916768849916155" title="9 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/6460916768849916155?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/6460916768849916155?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/9282UOGPGmI/asynchronous-functional-apis-in-java.html" title="Asynchronous Functional APIs in Java" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>9</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/04/asynchronous-functional-apis-in-java.html</feedburner:origLink></entry><entry gd:etag="W/&quot;AkUDSXo9fyp7ImA9WhZSFEg.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-4548000346683772286</id><published>2011-03-29T15:17:00.000-07:00</published><updated>2011-03-29T21:11:18.467-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-03-29T21:11:18.467-07:00</app:edited><title>Querying Cached Data - Paradigm Shift</title><content type="html">Why would you ever query cached data if you can query your persistent store, such as database? Well, the answer is the same as for accessing data by key from cache vs. getting it from database - for performance and scalability. However, querying cache is not exactly the same as querying your database - the main difference is that if cache only has a subset of data stored in database, then you will be only querying that subset, so query result will be reflecting only in-memory state. Does this matter? Depends on your application requirements and also depends on the amount of data you are able to store in cache.&lt;br /&gt;&lt;br /&gt;With introduction of cloud computing and virtual instances, the amount of memory available to your grid on the cloud becomes virtually limitless. Adding nodes to your grid has become as simple as calling AWS API on EC2 whenever your application demands it. On top of it, if GridGain swap space is configured, all the data that cannot fit in memory on a single node will be overflown to disk. Also, your application may not even have that much data, or maybe querying cached data, which usually contains data that has been accessed relatively recently, is good enough. Thus in many cases querying cache is becoming to look more and more like querying your database.&lt;br /&gt;&lt;br /&gt;Now that you made a decision in your project that you want to query cached data, the next question becomes how to cache query results. Most of us are familiar with Hibernate and it's support for 2nd Level Caching which also comes with Query Cache. The way query cache works in Hibernate is generally the way we are used to think of caching queried data. In a nutshell, a query is issued against the database and the results of the query are then stored in cache in a single collection. If you have multiple queries, then multiple collections containing query results are stored. Now if you ever update a single bean in Hibernate which can potentially affect the query result (pretty much any change to the queried tables), Hibernate is forced to invalidate (remove) the cached query results from cache and reload them on-demand next time. This significantly increases memory consumption, and frequent cache invalidations of query results perform horribly and do not scale at all. Even Hibernate itself discourages its users from using it. Here is the quote from &lt;a href="http://docs.jboss.org/hibernate/core/3.6/reference/en-US/html_single/#performance-querycache"&gt;Hibernate documenation&lt;/a&gt;:&lt;br /&gt;&lt;blockquote&gt;... most queries do not benefit from caching of their results. So by default, individual queries are not cached even after enabling query caching ...&lt;br /&gt;&lt;/blockquote&gt;&lt;span style="font-weight:bold;"&gt;So, how does querying of cached data help? It helps by entirely removing the need for &lt;span style="font-style:italic;"&gt;Query Result Cache&lt;/span&gt; altogether.&lt;/span&gt; SQL queries on your indexed cached data are executed in memory and perform very fast, so there is no more need to cache query results. Just run your SQL query on your cached data and get the results whenever you need them. However, it is important to note that without rich SQL support for cache queries, they will not be able to replace database queries within your project. In the example below, where Person relates to Company, if your cache does not support SQL joins, then you would not be able to find all people working for the same company, which may be quite limiting. Hense, it is extremely important to evaluate how rich the SQL support on a certain cache product before making a decision to query cached data.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;In GridGain 3.0 the support for cache queries is virtually without any limitations.&lt;/b&gt; If you know SQL, you can run queries against cached data, including support for any type of joins, where clause keywords, order by, group by, etc... In addition to SQL queries, GridGain also supports text queries using Lucene or H2 TEXT underlying indexing. You can also run predicate-based FULL SCAN queries, which will iterate over all cache elements on remote nodes and will include only the ones that passed the predicate filter.&lt;br /&gt;&lt;br /&gt;As an examples take a look at some of the &lt;a href="http://www.gridgain.com"&gt;GridGain 3.0&lt;/a&gt; query examples below. Note the JDBC PreparedStatement syntax for passing arguments and the SQL join performed between Person and Organization classes. Also note how you can cherry-pick the set of nodes on which you would like to execute your query.&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;// Create query which selects salaries based on range for all employees&lt;br /&gt;// that work for a certain company.&lt;br /&gt;GridCacheQuery&amp;lt;Long, Person&amp;gt; qry = cache.createQuery(SQL, Person.class,&lt;br /&gt; "from Person, Organization where Person.orgId = Organization.id " +&lt;br /&gt;  "and Organization.name = ? and Person.salary &amp;gt; ? and Person.salary &amp;lt;= ?");  &lt;br /&gt;&lt;br /&gt;// Query all nodes to find all cached GridGain employees &lt;br /&gt;// with salaries less than 1000. &lt;br /&gt;qry.queryArguments("GridGain", 0, 1000).execute(grid);  &lt;br /&gt;&lt;br /&gt;// Query only remote nodes to find all remotely cached GridGain employees &lt;br /&gt;// with salaries greater than 1000 and less than 2000. &lt;br /&gt;qry.queryArguments("GridGain", 1000, 2000).execute(grid.remoteProjection()); &lt;br /&gt;&lt;br /&gt;// Query local node only to find all locally cached GridGain employees &lt;br /&gt;// with salaries greater than 2000. &lt;br /&gt;qry.queryArguments("GridGain", 2000, Integer.MAX_VALUE).&lt;br /&gt;    execute(grid.localNode());&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Here is an examples of a text query which will scan all resumes for word "master":&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;// Will query fields annotated with @GridCacheQueryLuceneField annotation.&lt;br /&gt;GridCacheQuery&amp;lt;Long, Person&amp;gt; mastersQry = &lt;br /&gt;    cache.createQuery(LUCENE, Person.class, "Master");&lt;br /&gt;&lt;br /&gt;// Query all cache nodes.&lt;br /&gt;mastersQry.execute(grid));&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-4548000346683772286?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/4548000346683772286/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=4548000346683772286" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4548000346683772286?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4548000346683772286?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/BlhKaMBtd_0/querying-cached-data-paradigm-shift.html" title="Querying Cached Data - Paradigm Shift" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>1</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/03/querying-cached-data-paradigm-shift.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0AAQ30-fyp7ImA9WhZSEE0.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-1621882832319902635</id><published>2011-03-16T14:25:00.000-07:00</published><updated>2011-03-24T14:22:22.357-07:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-03-24T14:22:22.357-07:00</app:edited><title>GridGain Presents at TriJug</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.trijug.org/meetinginfo.jsp?date=2011-03"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 210px; height: 90px;" src="http://www.gridgain.com/images/trijug_logo.jpg" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I will be speaking about GridGain and its Scala usage at &lt;a href="http://www.trijug.org/meetinginfo.jsp?date=2011-03"&gt;TriJUG on March 21st&lt;/a&gt;, Raleigh, North Carolina. Topic is about “Cloud Computing with Scala and GridGain”. As always – plenty of live Scala coding. World’s shortest MapReduce app in 5 minutes in Scala as well as Data Grid access using Scala.&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Hope to see you there!&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-1621882832319902635?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/1621882832319902635/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=1621882832319902635" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/1621882832319902635?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/1621882832319902635?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/xVix5xjOjtg/gridgain-presents-at-trijug.html" title="GridGain Presents at TriJug" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>1</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/03/gridgain-presents-at-trijug.html</feedburner:origLink></entry><entry gd:etag="W/&quot;AkUGQX88fCp7ImA9Wx9aGEs.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-4001992376006143191</id><published>2011-03-11T10:21:00.000-08:00</published><updated>2011-03-11T10:30:20.174-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-03-11T10:30:20.174-08:00</app:edited><title>GridGain User Group Started</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.meetup.com/GridGain-Bay-Area-Meetup-Group/"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 66px; height: 45px;" src="http://www.gridgain.com/images/meetup_logo.png" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;GridGain user group&lt;/span&gt; started - &lt;a href="http://www.meetup.com/GridGain-Bay-Area-Meetup-Group/"&gt;Join us!&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-4001992376006143191?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/4001992376006143191/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=4001992376006143191" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4001992376006143191?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4001992376006143191?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/TBk7B9h52tc/gridgain-user-group-started.html" title="GridGain User Group Started" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/03/gridgain-user-group-started.html</feedburner:origLink></entry><entry gd:etag="W/&quot;AkMCQn08eyp7ImA9Wx9bGUs.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-2288696303329332650</id><published>2011-03-01T00:25:00.000-08:00</published><updated>2011-03-01T00:34:23.373-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-03-01T00:34:23.373-08:00</app:edited><title>GridGain at CodeMotion, Rome, Italy, March 5th</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/-MPzgRgUj0gw/TWyuTmmqyMI/AAAAAAAAABo/kSxuGb-YKjY/s1600/codemotion_logo.gif"&gt;&lt;a href="http://www.codemotion.it/en"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 200px; height: 74px;" src="http://3.bp.blogspot.com/-MPzgRgUj0gw/TWyuTmmqyMI/AAAAAAAAABo/kSxuGb-YKjY/s200/codemotion_logo.gif" border="0" alt="" id="BLOGGER_PHOTO_ID_5579025690208684226" /&gt;&lt;/a&gt;&lt;/a&gt;I will be presenting at &lt;a href="http://www.codemotion.it/en"&gt;CodeMotion Conference&lt;/a&gt; on March 5th on subject "Distributed Programming with GridGain and Scala". As usual, expect very little theory and lots of cool live coding examples around &lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; Data Grid and Compute Grid features.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Hope to see you there!&lt;/div&gt;&lt;p&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-2288696303329332650?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/2288696303329332650/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=2288696303329332650" title="3 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/2288696303329332650?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/2288696303329332650?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/Tk03zwxD2NE/gridgain-at-codemotion-rome-italy-march.html" title="GridGain at CodeMotion, Rome, Italy, March 5th" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/-MPzgRgUj0gw/TWyuTmmqyMI/AAAAAAAAABo/kSxuGb-YKjY/s72-c/codemotion_logo.gif" height="72" width="72" /><thr:total>3</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/03/gridgain-at-codemotion-rome-italy-march.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUIFSHw8cCp7ImA9Wx9aGEs.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-4229339937488018599</id><published>2011-02-14T13:25:00.000-08:00</published><updated>2011-03-11T10:18:39.278-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-03-11T10:18:39.278-08:00</app:edited><title>Compute Grids - What To Expect?</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/-EPxD4aLDjfk/TVmxFw2bFWI/AAAAAAAAAA8/hXurOUAu-Fs/s1600/robot-icon.png"&gt;&lt;img style="float: left; margin: 0pt 10px 10px 0pt; cursor: pointer; width: 96px; height: 96px;" src="http://2.bp.blogspot.com/-EPxD4aLDjfk/TVmxFw2bFWI/AAAAAAAAAA8/hXurOUAu-Fs/s200/robot-icon.png" alt="" id="BLOGGER_PHOTO_ID_5573680726418330978" border="0" /&gt;&lt;/a&gt;Recently I have been seeing a few new products  branding themselves as &lt;i&gt;compute grids&lt;/i&gt; while in reality they have very little to do with compute grids. While &lt;i&gt;data grids&lt;/i&gt; are provided by quite a few vendors and people generally know what to expect from them, &lt;i&gt;compute grids&lt;/i&gt; are not as common, and people may end up thinking that a compute grid is a simple &lt;a href="http://en.wikipedia.org/wiki/Remote_procedure_call"&gt;RPC&lt;/a&gt;-like function execution on a remote node. As you may have guessed, I will show that to be untrue.&lt;br /&gt;&lt;br /&gt;Let's take &lt;a href="http://letitcrash.posterous.com/compute-grid-with-cloudy-akka"&gt;Cloudy Akka&lt;/a&gt; for example. While it is a wonderful product with great ideas borrowed from Erlang, it's not really a compute grid. What it provides is a convenient way to execute functions remotely, but it does not provide all the underlying plumbing that we have come to expect from compute grids.&lt;br /&gt;&lt;br /&gt;Having worked on &lt;a href="http://www.gridgain.com/"&gt;GridGain&lt;/a&gt; compute grid myself for over 5 years already (and then on data grid), and having studied quite a few others, here are some features that are minimally required in any product in my opinion, before it can claim itself as a &lt;i&gt;compute grid&lt;/i&gt;.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Auto Discovery&lt;/span&gt; - all nodes in the grid should auto-discover each other, i. e. user should never have to manually add nodes to a topology.&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;MapReduce&lt;/span&gt; - support for splitting execution into multiple sub-jobs and then aggregating the results is just a MUST. Otherwise you are offloading most of the dirty work onto your users, which is not fair.&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Auto Failure Detection&lt;/span&gt; - compute grid must be smart enough to automatically detect node  crashes and proportionally distribute all the load among remaining nodes.&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Fault Tolerance&lt;/span&gt; - all failed grid jobs must be automatically failed-over to other nodes, which are better suited for executing these jobs.&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Load Balancing&lt;/span&gt; - compute grid should automatically distribute load equally among nodes, usually utilizing many different policies for load balancing. GridGain even has support for &lt;span style="font-style: italic;"&gt;work-stealing&lt;/span&gt;, where less-loaded nodes can steal jobs from overloaded nodes.&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Job Collision Resolution&lt;/span&gt; - this gives users control over how many jobs can run in parallel, while other jobs should wait in waiting queues, ordered by multiple available collision resolution strategies.&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Auto Deployment&lt;/span&gt; - compute grid users should never be forced to manually deploy their libraries on all available grid nodes, this is just way too inconvenient and error-prone. The approach I like the best (available in GridGain) is auto-deployment, where code just automatically penetrates throughout the grid without any explicit action from users.&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;Nested Jobs And Continuations&lt;/span&gt; - compute grid jobs should be able to invoke other compute grid jobs when executing remotely. This is a very powerful feature, especially when grid jobs are recursive. &lt;span style="font-style: italic;"&gt;Continuations&lt;/span&gt; should allow to suspend a job and release its resources while it's waiting for a result of another job within the grid.&lt;/li&gt;&lt;/ul&gt;I could probably continue, but I will stop here. I think it is clear that &lt;span style="font-style: italic;"&gt;compute grid&lt;/span&gt; products are way more advanced than &lt;span style="font-style: italic;"&gt;RPC&lt;/span&gt; frameworks. Just as a comparison, here are the GridGain examples implemented in GridGain Scalar which also do all the other cool stuff compute grids do in the background:&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;scalar {&lt;br /&gt;    // 1. Execute (unicast) a simple job on some remote node.&lt;br /&gt;    grid ucastRun (() =&gt; println("&gt; GridGain ROCKS &lt;"))&lt;br /&gt;&lt;br /&gt;    // 2. Execute (broadcast) a simple job on all remote nodes.&lt;br /&gt;    grid bcastRun (() =&gt; println("&gt; GridGain ROCKS &lt;"))      &lt;br /&gt;&lt;br /&gt;    // 3. Use MapReduce to split a phrase into multiple words and     &lt;br /&gt;    //    print each word on remote nodes.     &lt;br /&gt;    grid splitRun &lt;br /&gt;        (for (w &lt;- "GridGain ROCKS".split(" ")) yield () =&gt; println(w))&lt;br /&gt;&lt;br /&gt;    // 4. Use MapReduce to count number characters by spreading&lt;br /&gt;    //    workload to the grid and reducing on local node.&lt;br /&gt;    val cnt = grid splitReduce &lt;br /&gt;        (for (w &lt;- "GridGain REALLY ROCKS!".split(" "))&lt;br /&gt;            yield () =&gt; w.length, // Map step.&lt;br /&gt;            (s: Seq[Int]) =&gt; s.sum) // Reduce step.&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Here is the similar example written in Java. It's a bit more verbose, but nevertheless, still pretty simple.&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;    // 1. Execute (unicast) a simple job on some remote node.&lt;br /&gt;    grid.run(UNICAST, new GridRunnable() {&lt;br /&gt;        @Override public void run() {&lt;br /&gt;            System.out.println("&gt; GridGain ROCKS &lt;");&lt;br /&gt;        }&lt;br /&gt;    });&lt;br /&gt;&lt;br /&gt;    // 2. Execute (broadcast) a simple job on all remote nodes.&lt;br /&gt;    grid.run(BROADCAST, new GridAbsClosure() {&lt;br /&gt;        @Override public void apply() {&lt;br /&gt;            System.out.println("&gt; GridGain ROCKS &lt;");&lt;br /&gt;        }&lt;br /&gt;    });&lt;br /&gt;&lt;br /&gt;    // 3. Use MapReduce to split a phrase into multiple words and     &lt;br /&gt;    //    print each word on remote nodes.     &lt;br /&gt;    grid.run(SPREAD, F.yield("&gt; GridGain ROCKS &lt;".split(" "), &lt;br /&gt;        new GridInClosure&amp;lt;String&amp;gt;() {&lt;br /&gt;            @Override public void apply(String word) {&lt;br /&gt;                System.out.println(word);&lt;br /&gt;            }&lt;br /&gt;    }));&lt;br /&gt;&lt;br /&gt;    // 4. Use MapReduce to count number characters by spreading&lt;br /&gt;    //    workload to the grid and reducing on local node.&lt;br /&gt;    int cnt = grid.reduce(&lt;br /&gt;        BALANCE,&lt;br /&gt;        new GridClosure&amp;lt;String, Integer&amp;gt;() { // Create executable logic.&lt;br /&gt;            @Override public Integer apply(String word) {&lt;br /&gt;                return word.length();&lt;br /&gt;            }&lt;br /&gt;        },&lt;br /&gt;        Arrays.asList("GridGain REALLY ROCKS!".split(" ")), // List of words.&lt;br /&gt;        F.sumIntReducer() // Reducer which adds up all the values given to it.&lt;br /&gt;    );&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;GridGain Scalar is available within GridGain release and can be downloaded &lt;a href="http://www.gridgain.com/downloads.html"&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;p&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-4229339937488018599?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/4229339937488018599/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=4229339937488018599" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4229339937488018599?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/4229339937488018599?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/GSVKuSd47bI/compute-grids-what-to-expect.html" title="Compute Grids - What To Expect?" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-EPxD4aLDjfk/TVmxFw2bFWI/AAAAAAAAAA8/hXurOUAu-Fs/s72-c/robot-icon.png" height="72" width="72" /><thr:total>2</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/02/compute-grids-what-to-expect.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkIGQHk5eyp7ImA9Wx9VGEs.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-3482085993450468823</id><published>2011-02-04T14:53:00.000-08:00</published><updated>2011-02-04T15:02:01.723-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-02-04T15:02:01.723-08:00</app:edited><title /><content type="html">Simon Forge at &lt;a href="http://ptaknoel.com/"&gt;Ptak, Noel &amp; Associates&lt;/a&gt; wrote a pretty nice article about &lt;a href="http://ptaknoel.com/research-analysis/market-observations/an-open-source-success-story-in-cloud-computing-land/"&gt;"GridGain - An Open Source Success Story in Cloud Computing Land"&lt;/a&gt;. &lt;br /&gt;&lt;br /&gt;Have a look at it - it's not very technical, but contains quite useful market analysis.&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-3482085993450468823?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/3482085993450468823/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=3482085993450468823" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/3482085993450468823?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/3482085993450468823?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/5f3S94xzFlc/simon-forge-at-ptak-noel-associates.html" title="" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/02/simon-forge-at-ptak-noel-associates.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkIGRH47eip7ImA9Wx9VFE8.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-6811723539699275763</id><published>2011-01-28T09:58:00.000-08:00</published><updated>2011-01-30T13:55:25.002-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-01-30T13:55:25.002-08:00</app:edited><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="SQL" /><title>Taste Of SQL For In-Memory Cache Queries</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_P_dIbdDnwhI/TUMPVLFvzAI/AAAAAAAAAAw/tYYbXDa7ThU/s1600/book-cd-vide-icon.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 96px; height: 96px;" src="http://1.bp.blogspot.com/_P_dIbdDnwhI/TUMPVLFvzAI/AAAAAAAAAAw/tYYbXDa7ThU/s200/book-cd-vide-icon.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5567310420788628482" /&gt;&lt;/a&gt;I plan to blog in more detail about support of native SQL in &lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; data grid in a few days, but here is just a taste on how complex of an SQL statement you can execute against GridGain distributed in-memory cache. Note that you are not querying a database - you are querying objects cached in memory.&lt;br /&gt;&lt;br /&gt;The query below utilizes &lt;a href="http://www.h2database.com/"&gt;H2 database&lt;/a&gt; SQL over JDBC syntax to query a collection of QueueItems at specified positions of a dynamic priority-based queue stored in distributed GridGain cache. As we know, querying an element at a certain position of a result set is not trivial in any SQL, and nested &lt;span style="font-style:italic;"&gt;'select'&lt;/span&gt; statements with &lt;span style="font-style:italic;"&gt;'rownum'&lt;/span&gt; field usually need to be used. On top of that we need to pass a collection of item positions to a query, which is also a fairly advanced feature.&lt;br /&gt;&lt;pre class="java" name="code"&gt;&lt;br /&gt;String sql = &lt;br /&gt;    "select * from (" +&lt;br /&gt;        "select *, rownum as r from (" +&lt;br /&gt;            "select * from QueueItem where qid=? " + &lt;br /&gt;                "order by priority desc, seq asc" +&lt;br /&gt;        ")" +&lt;br /&gt;    ") where r in (select * from table(x int=?))"&lt;br /&gt;&lt;br /&gt;GridCacheQuery itemsQry = cache.createQuery(SQL, QueueItem.class, sql);&lt;br /&gt;&lt;br /&gt;// Specify positions of queue items we want to get.&lt;br /&gt;Collection&amp;lt;Integer&amp;gt; positions = Collections.asList(10, 12, 14);&lt;br /&gt;&lt;br /&gt;// Query items at specified positions from queue with ID 123.&lt;br /&gt;GridCacheQueryFuture fut = itemsQry.queryArguments(123, positions).execute();&lt;br /&gt;&lt;br /&gt;System.out.println("Queried queue items at specified positions: " + fut.get());&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Pretty powerful in my view especially when you also get smart routing, pagination, custom transformers, reducers, visit-only support, text queries, and a lot more... &lt;br /&gt;&lt;br /&gt;More information on GridGain queries can be found &lt;a href="http://www.gridgainsystems.com/wiki/display/GG15UG/Chapter+6#Chapter6-6.7CacheQueries"&gt;here&lt;/a&gt; or &lt;a href="http://www.gridgain.com/javadoc30C/org/gridgain/grid/cache/query/GridCacheQuery.html"&gt;here&lt;/a&gt;.&lt;p&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-6811723539699275763?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/6811723539699275763/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=6811723539699275763" title="4 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/6811723539699275763?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/6811723539699275763?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/CAiCw3ozc7w/taste-of-sql-for-in-memory-cache.html" title="Taste Of SQL For In-Memory Cache Queries" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/_P_dIbdDnwhI/TUMPVLFvzAI/AAAAAAAAAAw/tYYbXDa7ThU/s72-c/book-cd-vide-icon.png" height="72" width="72" /><thr:total>4</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/01/taste-of-sql-for-in-memory-cache.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D08FQHo6fip7ImA9Wx9VEEU.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-6950764059608694707</id><published>2011-01-26T15:18:00.000-08:00</published><updated>2011-01-26T15:50:11.416-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-01-26T15:50:11.416-08:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="cloud" /><category scheme="http://www.blogger.com/atom/ns#" term="cache" /><category scheme="http://www.blogger.com/atom/ns#" term="grid" /><category scheme="http://www.blogger.com/atom/ns#" term="data grid" /><category scheme="http://www.blogger.com/atom/ns#" term="compute grid" /><title>Which Grid Product To Use?</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_P_dIbdDnwhI/TUCwDCwGLlI/AAAAAAAAAAo/HzRaeq1pJ7s/s1600/shelves-icon.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 96px; height: 96px;" src="http://1.bp.blogspot.com/_P_dIbdDnwhI/TUCwDCwGLlI/AAAAAAAAAAo/HzRaeq1pJ7s/s200/shelves-icon.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5566642705754631762" /&gt;&lt;/a&gt;&lt;blockquote&gt;- Why use &lt;a href="http://www.gridgain.com/"&gt;GridGain&lt;/a&gt; if there is &lt;span style="font-style: italic;"&gt;Infinispan&lt;/span&gt;?&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;- Why use &lt;span style="font-style: italic;"&gt;Infinispan&lt;/span&gt; if there is &lt;span style="font-style: italic;"&gt;Hazelcast&lt;/span&gt;?&lt;br /&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;- Why use &lt;span style="font-style: italic;"&gt;Hazelcast&lt;/span&gt; if there is &lt;span style="font-style: italic;"&gt;Map over RMI&lt;/span&gt;?&lt;br /&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;&amp;nbsp;- Why use &lt;span style="font-style: italic;"&gt;Map over RMI&lt;/span&gt; if you can do it yourself?&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I think you see the pattern... As you climb up this ladder you get more and more value from your grid product.&lt;p&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-6950764059608694707?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/6950764059608694707/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=6950764059608694707" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/6950764059608694707?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/6950764059608694707?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/xkjMIOGMXFU/which-grid-product-to-use.html" title="Which Grid Product To Use?" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/_P_dIbdDnwhI/TUCwDCwGLlI/AAAAAAAAAAo/HzRaeq1pJ7s/s72-c/shelves-icon.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/01/which-grid-product-to-use.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkAFQnc_fyp7ImA9Wx9WE0k.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-1655034614753909509</id><published>2011-01-14T00:28:00.001-08:00</published><updated>2011-01-18T01:58:33.947-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-01-18T01:58:33.947-08:00</app:edited><title>Collocation - First Rule Of Distributed Programming</title><content type="html">&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_P_dIbdDnwhI/TTAjy-sEUXI/AAAAAAAAAAg/z53RmMj921I/s1600/collocation1.png"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 96px; height: 96px;" src="http://2.bp.blogspot.com/_P_dIbdDnwhI/TTAjy-sEUXI/AAAAAAAAAAg/z53RmMj921I/s200/collocation1.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5561984898530824562" /&gt;&lt;/a&gt;I am pleased to announce that we just recently released &lt;a href="http://www.gridgain.com/"&gt;GridGain&lt;/a&gt; 3.0.4. The last couple of releases have been focused, among other things, around convenient and effective &lt;span style="font-weight:bold;"&gt;collocation of computations and data&lt;/span&gt;, and also &lt;span style="font-weight:bold;"&gt;grouping of data&lt;/span&gt; that is usually accessed together on the same nodes. Sending computations exactly to the nodes where the accessed data is residing is one of the key components in achieving better scalability. Without collocation, nodes fetch various data from other nodes for brief periods of time, just to perform often a quick computation and discard it almost immediately thereafter. This creates unnecessary data traffic, a.k.a. &lt;span style="font-style:italic;"&gt;data noise&lt;/span&gt;, and can at times bring a server to its knees.&lt;br /&gt;&lt;br /&gt;In my &lt;a href="http://gridgain.blogspot.com/2011/01/say-hello-to-gridgain-data-grid.html"&gt;previous blog post&lt;/a&gt; I showed how to collocate computations and data using direct API via &lt;i&gt;GridCache.mapKeyToNode(..)&lt;/i&gt; method. We have also added analogous methods on &lt;i&gt;Grid&lt;/i&gt; API to provide capability of finding data affinity on the nodes that do not cache any data themselves. In our latest 3.0.4 release we have also added a very convenient way to provide collocation via &lt;span style="font-style: italic;"&gt;@GridCacheAffinityMapped&lt;/span&gt; annotation.&lt;br /&gt;&lt;br /&gt;Say you have 2 types of objects, &lt;span style="font-style: italic;"&gt;Person&lt;/span&gt; and &lt;span style="font-style: italic;"&gt;Company&lt;/span&gt;. Multiple persons can work for the same company. This means that you generally may wish to access &lt;span style="font-style: italic;"&gt;Person&lt;/span&gt; objects together with the &lt;span style="font-style: italic;"&gt;Company&lt;/span&gt; for which they work. To do that in a scalable fashion, you may wish to ensure that all people working for the same company are cached on the same node. This way you can send computations to that node and access multiple people from the same company locally. Here is how it can be done in GridGain.&lt;br /&gt;&lt;pre class="java" name="code"&gt;public class PersonKey {&lt;br /&gt;  // Person ID used to identify a person.&lt;br /&gt;  private String personId;&lt;br /&gt;&lt;br /&gt;  // Company ID which will be used for data affinity.&lt;br /&gt;  @GridCacheAffinityMapped&lt;br /&gt;  private String companyId;&lt;br /&gt;  ...&lt;br /&gt;}&lt;br /&gt;...&lt;br /&gt;// Instantiate person keys with same company ID.&lt;br /&gt;Object personKey1 = new PersonKey("myPersonId1", "myCompanyId");&lt;br /&gt;Object personKey2 = new PersonKey("myPersonId2", "myCompanyId");&lt;br /&gt;&lt;br /&gt;// Both, the company and the person objects will be cached on the same node.&lt;br /&gt;cache.put("myCompanyId", new Company(..));&lt;br /&gt;cache.put(personKey1, new Person(..));&lt;br /&gt;cache.put(personKey2, new Person(..));&lt;/pre&gt;&lt;br /&gt;Now, if you want to perform a computation which involves multiple people working for the same company, all you have to do is send a grid job to the node where those people are cached. Here is how you would send a computation to the node which caches all people for the company with ID &lt;span style="font-style: italic;"&gt;"myCompanyId"&lt;/span&gt;.&lt;br /&gt;&lt;pre class="java" name="code"&gt;G.grid().run(GridClosureCallMode.BALANCE, new Runnable() {&lt;br /&gt;  // This annotation specifies that computation should be routed&lt;br /&gt;  // precisely to the node where all objects with affinity key&lt;br /&gt;  // of 'myCompanyId' are cached.&lt;br /&gt;  @GridCacheAffinityMapped&lt;br /&gt;  private String companyId = "myCompanyId";&lt;br /&gt;&lt;br /&gt;  @Override public void run() {&lt;br /&gt;      // Some computation logic here.&lt;br /&gt;      ...&lt;br /&gt;  }&lt;br /&gt;};&lt;/pre&gt;&lt;br /&gt;Now, when you properly collocate all your data within your data grid and then route your computations to the nodes where your data is cached, all cache operations become &lt;span style="font-weight: bold;"&gt;LOCAL&lt;/span&gt;, hence achieving best performance and scalability without any &lt;span style="font-style:italic;"&gt;data noise&lt;/span&gt;. Kind of goes inline with the &lt;span style="font-style:italic;"&gt;first rule of distributed programming&lt;/span&gt;, which is &lt;span style="font-weight: bold;"&gt;DO NOT DISTRIBUTE&lt;/span&gt;.&lt;br /&gt;&lt;p&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-1655034614753909509?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/1655034614753909509/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=1655034614753909509" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/1655034614753909509?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/1655034614753909509?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/zaMeVNvT9so/collocation-first-rule-of-distributed.html" title="Collocation - First Rule Of Distributed Programming" /><author><name>Dmitriy Setrakyan</name><uri>http://www.blogger.com/profile/01141522474656442760</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://3.bp.blogspot.com/-zwDgFtZV3JE/TlgqqlQG-4I/AAAAAAAAACQ/sNMg3tg-bSI/s220/dsetrakyan.png" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/_P_dIbdDnwhI/TTAjy-sEUXI/AAAAAAAAAAg/z53RmMj921I/s72-c/collocation1.png" height="72" width="72" /><thr:total>1</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/01/collocation-first-rule-of-distributed.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0QBSX87eCp7ImA9Wx9XEkQ.&quot;"><id>tag:blogger.com,1999:blog-1680085285488970412.post-3975199690233376300</id><published>2011-01-05T19:33:00.000-08:00</published><updated>2011-01-05T23:35:58.100-08:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2011-01-05T23:35:58.100-08:00</app:edited><title>Say Hello To GridGain Data Grid</title><content type="html">I have been thinking how a HelloWorld example should look for data grid. After checking some other products I have noticed that the most popular approach for a HelloWolrd app on a data grid is creating an example which has two counter parts: client and server. The client part usually prints out the operation on cache, and the remote server would usually print out the same operation whenever the data ends up on that server. This way users can see that the value stored in cache actually does get distributed to remote nodes.&lt;br /&gt;
&lt;br /&gt;
After looking at such examples it occurred to me that this client/server approach can be implemented a lot simpler in &lt;a href="http://www.gridgain.com"&gt;GridGain&lt;/a&gt; using &lt;b&gt;zero deployment&lt;/b&gt; and basic &lt;b&gt;event subscription&lt;/b&gt;. All we need to do is make sure that cache operations get printed out on remote nodes so we can visualize what's going on. However, for that we don't need to create a separate server app - we can do it all from our client example code.&lt;br /&gt;
&lt;br /&gt;
So, let's make sure that events are printed out. For that we will execute a closure on all grid nodes which will subscribe to cache events and print them. This closure can be executed directly from example code and will be &lt;b&gt;automatically deployed&lt;/b&gt; on remote nodes. Here is how the code will look like:&lt;br /&gt;
&lt;pre class="java" name="code"&gt;// Execute this runnable on all grid nodes, local and remote.
G.grid().run(BROADCAST, new Runnable() {
    @Override public void run() {
        // Event listener which will print out cache events, so we 
        // can visualize what happens on remote nodes.
        GridLocalEventListener lsnr = new GridLocalEventListener() {
            @Override public void onEvent(GridEvent e) {
                System.out.println("Event '" + e.type() + "' for key: " +
                    ((GridCacheEvent)e).key());
            }
        };

        // GridNodeLocal is a ConcurrentMap attached to every grid node.
        Object prev = grid.nodeLocal().putIfAbsent("lsnr", lsnr);

        // Make sure that we only subscribe one time regardless
        // of how many times we run the example.
        if (prev == null)
            grid.addLocalEventListener(lsnr,
                EVT_CACHE_OBJECT_PUT, 
                EVT_CACHE_OBJECT_READ, 
                EVT_CACHE_OBJECT_REMOVED);
     }
});&lt;/pre&gt;Note how easy it is in GridGain to execute any kind of code on all grid nodes (or any subset of nodes) without actually having to deploy anything. Now lets play with some basic cache operations and see what happens:&lt;br /&gt;
&lt;pre class="java" name="code"&gt;// Create strongly typed cache projection to avoid casting.
final GridCacheProjection&amp;lt;Integer, String&amp;gt; cache = 
    G.grid().cache().projection(Integer.class, String.class);

// Store some values in cache.
for (int i = 0; i &amp;lt; 10; i++)
    cache.put(i, "value-" + i);

// Note that size may differ depending on whether cache
// is distributed or partitioned.
System.out.println("Cache size: " + cache.size());

// Visit every cache element stored on local node.
// Note that 'CI1' is a just a type alias for 'GridInClosure' type.
cache.forEach(new CI1&amp;lt;GridCacheEntry&amp;lt;Integer, String&amp;gt;&amp;gt;() {
    @Override public void apply(GridCacheEntry&amp;lt;Integer, String&amp;gt; e) {
        // Peek at locally cached values.
        System.out.println("Visited locally cached entry: " + e.peek());
    }
});

// Collocate computations and data.
for (int i = 0; i &amp;lt; 10; i++) {
    final int key = i;

    // Find primary node for a key.
    final UUID nodeId = cache.mapKeyToNode(key);

    // Execute your computations on nodes where the data is cached to avoid a 
    // potentially heavy operation of bringing data to the local node. 
    // This is called Collocation of Computations and Data.
    G.grid().node(nodeId).run(UNICAST, new Runnable() {
        @Override public void run() {
            System.out.println("Collocating computations and data " + 
                "on node: " + nodeId);

            // Usually you would do something more complex than this :)
            System.out.println("Cached value: " + cache.peek(key));
        }
    });
}

// The 'get' operation will bring values from remote nodes
// even if they are not cached on local node. Generally,
// you would want to avoid it, if possible, as it may 
// create unnecessary data traffic.
for (int i = 0; i &amp;lt; 10; i++)
    System.out.println("Cached value: " + cache.get(i));&lt;/pre&gt;The example above is just a small sample of what you can do with GridGain data grid. Note that if the cache is configured to be &lt;i&gt;replicated&lt;/i&gt; (which is default), then data will be replicated to all nodes and every node will get the same copy. If cache is &lt;i&gt;partitioned&lt;/i&gt;, then only a designated primary node (and also backup nodes, if any) will get to cache a specific key-value pair.&lt;br /&gt;
&lt;br /&gt;
Also note how easily we brought our computations to the nodes where the data is cached, as opposed to bringing the data to the computations. Performing computations without any unnecessary data movement (a.k.a. data noise) is one of the most important elements in achieving better scalability. &lt;br /&gt;
&lt;br /&gt;
To run this example, startup a few stand alone GridGain nodes by executing &lt;i&gt;GRIDGAIN_HOME/bin/ggstart.{sh|bat}&lt;/i&gt; script and watch what happens.&lt;br /&gt;
&lt;br /&gt;
Enjoy!&lt;p&gt;&lt;div class="blogger-post-footer"&gt;&lt;a href="http://www.gridgain.com"&gt;GridGain - Cloud Computing With Zero Deployment&lt;/a&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1680085285488970412-3975199690233376300?l=gridgain.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel="replies" type="application/atom+xml" href="http://gridgain.blogspot.com/feeds/3975199690233376300/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=1680085285488970412&amp;postID=3975199690233376300" title="1 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/3975199690233376300?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/1680085285488970412/posts/default/3975199690233376300?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/gridify/~3/kdALJQp0Cnk/say-hello-to-gridgain-data-grid.html" title="Say Hello To GridGain Data Grid" /><author><name>dsetrakyan</name><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="28" height="32" src="http://www.gridgain.com/images/dsetrakyan.png" /></author><thr:total>1</thr:total><feedburner:origLink>http://gridgain.blogspot.com/2011/01/say-hello-to-gridgain-data-grid.html</feedburner:origLink></entry></feed>

