<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-1197843169524706388</id><updated>2026-04-30T04:09:14.078-04:00</updated><category term="WSO2"/><category term="ESB"/><category term="HTTP"/><category term="architecture"/><category term="java"/><category term="SOA"/><category term="Web Services"/><category term="Google Chrome"/><category term="HTTPCore"/><category term="IO"/><category term="Java NIO"/><category term="Linux"/><category term="Networking"/><category term="POST"/><category term="REST"/><category term="Regex"/><category term="SOAP"/><category term="Sentence"/><category term="Synapse"/><category term="Thread"/><category term="UDP"/><category term="Ubuntu"/><category term="Word"/><category term="chunk"/><category term="client"/><category term="command"/><category term="concurrent"/><category term="curl"/><category term="data mining"/><category term="datanode"/><category term="forward"/><category term="hadoop"/><category term="jsp"/><category term="k-means"/><category term="kmeans"/><category term="move"/><category term="mysql"/><category term="perl"/><category term="permission"/><category term="sample"/><category term="script"/><category term="streaming"/><category term="svn"/><category term="transport"/><category term="बुक्स"/><category term="सॉफ्टवेर enginnering"/><title type='text'>Life of a Software Engineer</title><subtitle type='html'>Developing software is fun..</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>101</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-8826510308000201584</id><published>2014-04-18T16:55:00.001-04:00</published><updated>2014-05-07T10:06:38.498-04:00</updated><title type='text'>Apache Storm Message Broker Spouts</title><content type='html'>I was working with &lt;a href=&quot;http://storm.incubator.apache.org/&quot; target=&quot;_blank&quot;&gt;Apache Storm&lt;/a&gt; for sometime now. I wanted to get the messages from different message brokers and and process them inside Storm. The brokers I&#39;m interested are RabbitMQ, JMS Based brokers like ActiveMQ, Appollo, Kestrel and Kafka. The existing spouts were lacking some of the functionality I was searching for.. The&amp;nbsp;most important things for me was total control of the message and ability to read from multiple queues from a single spout. &amp;nbsp;So I thought of writing these spouts for various brokers and I have written RabbitMQ and JMS spouts. The source code can be found in github&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;a href=&quot;https://github.com/supunkamburugamuva/storm-broker-connectors&quot;&gt;https://github.com/supunkamburugamuva/storm-broker-connectors&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
The software is under Apache License Version 2. So you are free to use it anyway you like.&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/8826510308000201584/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/8826510308000201584' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/8826510308000201584'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/8826510308000201584'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2014/04/apache-storm-rabbitmq-spout.html' title='Apache Storm Message Broker Spouts'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-4550094966440976402</id><published>2013-04-03T10:19:00.000-04:00</published><updated>2013-04-03T10:19:13.673-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="datanode"/><category scheme="http://www.blogger.com/atom/ns#" term="hadoop"/><category scheme="http://www.blogger.com/atom/ns#" term="permission"/><title type='text'>Starting Hadoop, setting Datanode directory file permissions</title><content type='html'>I was trying to start Apache Hadoop in my Ubuntu machine with the data node and name node on the same machine. I&#39;ve changed the hdfs-site.xml as following.&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&quot;https://gist.github.com/supunkamburugamuva/5301554.js&quot;&gt;&lt;/script&gt;
&lt;div class=&quot;gistLoad&quot; data-id=&quot;5301554&quot; id=&quot;gist-GistID&quot;&gt;Loading ....&lt;/div&gt;
Then when the datanode starts it said the permission of the data directory is incorrect.&lt;br /&gt;
&lt;br /&gt;
WARN org.apache.hadoop.hdfs.server.datanode.DataNode: Invalid directory in dfs.data.dir: Incorrect permission for /home/supun/dev/apache/hadoop-data/data, expected: rwxr-xr-x, while actual: rwxrwxr-x&lt;br /&gt;
&lt;br /&gt;
So I had to change the permission of the data dir as following and it worked.&amp;nbsp;
&lt;br /&gt;
&lt;br /&gt;
chmod 755 hadoop-data/data
&lt;script src=&quot;https://raw.github.com/moski/gist-Blogger/master/public/gistLoader.js&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/4550094966440976402/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/4550094966440976402' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/4550094966440976402'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/4550094966440976402'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2013/04/starting-hadoop-setting-datanode.html' title='Starting Hadoop, setting Datanode directory file permissions'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-1003241167690257126</id><published>2013-03-25T14:23:00.001-04:00</published><updated>2013-03-25T14:25:57.911-04:00</updated><title type='text'>Graphene supercapacitors, can be the biggest invention in 21st century</title><content type='html'>It seems finally humanity has found a way to create more efficient batteries.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;iframe allowfullscreen=&#39;allowfullscreen&#39; webkitallowfullscreen=&#39;webkitallowfullscreen&#39; mozallowfullscreen=&#39;mozallowfullscreen&#39; width=&#39;320&#39; height=&#39;266&#39; src=&#39;https://www.youtube.com/embed/RVUf7-tTLXo?feature=player_embedded&#39; frameborder=&#39;0&#39;&gt;&lt;/iframe&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
There is a long way to go. But the future seems promising. This can be one of the biggest&amp;nbsp;inventions&amp;nbsp;that changed the human history. Looking forward to a day where we can charge our cars within minutes, cell phones and other devices instantly.</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/1003241167690257126/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/1003241167690257126' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/1003241167690257126'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/1003241167690257126'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2013/03/graphene-supercapacitors-can-be-biggest.html' title='Graphene supercapacitors, can be the biggest invention in 21st century'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-8092400321409878408</id><published>2013-03-25T11:22:00.002-04:00</published><updated>2013-03-25T11:46:17.232-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="mysql"/><category scheme="http://www.blogger.com/atom/ns#" term="perl"/><title type='text'>Scripting with perl</title><content type='html'>&lt;a href=&quot;http://chathuriwimalasena.blogspot.com/2013/03/scripting-with-perl.html&quot; target=&quot;_blank&quot;&gt;Here is a tutorial&lt;/a&gt; about some basics of perl that can be very handy.. The tutorial talks about how to connect to a database, reading a config file, replace a string in a file etc.</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/8092400321409878408/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/8092400321409878408' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/8092400321409878408'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/8092400321409878408'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2013/03/scripting-with-perl.html' title='Scripting with perl'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-5337677957001404088</id><published>2013-03-08T12:00:00.000-05:00</published><updated>2013-03-15T16:13:08.771-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="java"/><category scheme="http://www.blogger.com/atom/ns#" term="Regex"/><category scheme="http://www.blogger.com/atom/ns#" term="Sentence"/><category scheme="http://www.blogger.com/atom/ns#" term="Word"/><title type='text'>Java Regular expression for getting sentences with a given word</title><content type='html'>Here is a simple regular expression for finding a sentence with a given word.&lt;br /&gt;
&lt;br /&gt;

&lt;script src=&quot;https://raw.github.com/moski/gist-Blogger/master/public/gistLoader.js&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
&lt;div class=&quot;gistLoad&quot; data-id=&quot;5117945&quot; id=&quot;gist-GistID&quot;&gt;Loading ....&lt;/div&gt;

</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/5337677957001404088/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/5337677957001404088' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/5337677957001404088'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/5337677957001404088'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2013/03/regular-expression-for-matching.html' title='Java Regular expression for getting sentences with a given word'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-2929156839680378464</id><published>2013-02-07T16:02:00.001-05:00</published><updated>2013-03-15T16:13:37.798-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="IO"/><category scheme="http://www.blogger.com/atom/ns#" term="Networking"/><category scheme="http://www.blogger.com/atom/ns#" term="Thread"/><title type='text'>A Myth about Threads</title><content type='html'>&lt;br /&gt;
We were given an assignment in one of our classes to write a port scanner. This was a great assignment and we&#39;ve learn&#39;t a lot from it. The assignment was pretty huge with lot of&amp;nbsp;functions. For those of you who don&#39;t know what a port scanner is, a port scanner is a piece of software that can be used to determine the status of network ports in a given machine.&amp;nbsp;A port scanner can also be used to determine what are the software running on open ports etc.&amp;nbsp;Ports are specific to &lt;a href=&quot;http://en.wikipedia.org/wiki/Transmission_Control_Protocol&quot; target=&quot;_blank&quot;&gt;TCP&lt;/a&gt; and &lt;a href=&quot;http://en.wikipedia.org/wiki/User_Datagram_Protocol&quot; target=&quot;_blank&quot;&gt;UDP&lt;/a&gt; and a port scanners functionality is border than TCP and UDP and can be used to determine the protocols that are running in machines etc. &amp;nbsp;A good place to look at for more details is&amp;nbsp;&lt;a href=&quot;http://en.wikipedia.org/wiki/Port_scanner&quot; target=&quot;_blank&quot;&gt;here&lt;/a&gt;. For making our discussion simple lets assume we are only going to scan TCP ports. &lt;br /&gt;
&lt;br /&gt;
One of the key things about a port scanner is the ability to scan ports in&amp;nbsp;parallel. Usually there are 2 to the power 16 ports in a given machine. But usually we want to scan a subset of these ports and even this subset can be huge. So if we scan each port one by one it will take a lot of time. To avoid this we have to send requests in parallel to the range of ports that we scan.&lt;br /&gt;
&lt;br /&gt;
A port scanning request for the most part is an IP packet with a TCP or UDP payload. In the TCP case we don&#39;t want to create a full TCP connection in order to determine weather the port is open. We can simply send a TCP SYN packet and if we get a response with SYN&amp;nbsp;+ ACK&amp;nbsp;&amp;nbsp;we can conclude that the port is open. There are many other techniques for determining the status of a port and non of them require us to create a connection. To send these TCP SYN packets we need to use RAW Sockets and we cannot use regular stream sockets.&lt;br /&gt;
&lt;br /&gt;
The important summery of the above is that we create a TCP SYN packet for each port that we are going to scan and send them in parallel to the destination IP using a &lt;a href=&quot;http://linux.die.net/man/7/raw&quot; target=&quot;_blank&quot;&gt;RAW Socket&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
Since these are RAW sockets there is no TCP &lt;a href=&quot;http://en.wikipedia.org/wiki/Transmission_Control_Protocol#Flow_control&quot; target=&quot;_blank&quot;&gt;Flow Control&lt;/a&gt; or TCP&amp;nbsp;&lt;a href=&quot;http://en.wikipedia.org/wiki/Transmission_Control_Protocol#Congestion_control&quot; target=&quot;_blank&quot;&gt;Congestion&amp;nbsp;control&lt;/a&gt;. Once we call the &lt;b&gt;send &lt;/b&gt;with the IP packet, the kernel will send the packet as fast as it can. First it will copy the buffer to the kernel space and hand over this to the IO&amp;nbsp;Subsystem&amp;nbsp;to send. The important thing is the call to send the packet is non blocking on IO as we are not waiting for the success or failure of this packets to be delivered to the destination or out of the host machine. But since send involves a system call it can be bit slow compared to other method calls. Also note that these are very small packets, with byte sizes no more that 50 bytes for the IP packet and there is no data in the TCP packet.&lt;br /&gt;
&lt;br /&gt;
The assignment asked us to create threads for making the sending process parallel. The expectation is that as the number of threads increases the sending speed will increase. But is this really true? &lt;b&gt;Will threads increase the sending performance linearly?&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
If we run the program on a multi-core machine definitely the increase of threads should increase the sending rate until the number of threads is somewhat greater than the available processors. But will this increase the performance if we increase the number of threads to 100 and available processes is 8? My gut feeling is it &lt;b&gt;NO&lt;/b&gt;. But people tend to think that increasing the number of threads will increase the rate of sending. But since the operations are CPU bound increasing the number of threads beyond the number of available cores is not going to give any performance. On the contrary increasing the threads should decrease the performance of the system.&lt;br /&gt;
&lt;br /&gt;
This is a conclusion I came from theoretical&amp;nbsp;knowledge and past experiences.&amp;nbsp;No performance test was done. may be I should do a performance test or may be I should not :) Lets see what others have to say.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/2929156839680378464/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/2929156839680378464' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/2929156839680378464'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/2929156839680378464'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2013/02/myths-about-threads.html' title='A Myth about Threads'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-6964260983837518862</id><published>2012-08-31T16:04:00.000-04:00</published><updated>2013-03-15T16:12:40.637-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="HTTP"/><category scheme="http://www.blogger.com/atom/ns#" term="REST"/><category scheme="http://www.blogger.com/atom/ns#" term="SOAP"/><category scheme="http://www.blogger.com/atom/ns#" term="Web Services"/><title type='text'>REST vs SOAP Adoption - A Perspective</title><content type='html'>I worked for three year in a company called &lt;a href=&quot;http://wso2.com/&quot; target=&quot;_blank&quot;&gt;WSO2&lt;/a&gt;, building &lt;a href=&quot;http://en.wikipedia.org/wiki/SOAP&quot; target=&quot;_blank&quot;&gt;Web Services&lt;/a&gt; based&amp;nbsp;middle-ware&amp;nbsp;systems.&amp;nbsp;Five years ago we believed Web Services is going to take over the world by becoming the de-facto standard in communication. Web Services is such a nice and well thought technology. It has a metadata model, a rich set of tooling, a built in security model; which are essential parts of enterprise&amp;nbsp;grade communication. Also WS is backed by industry giants like Microsoft, IBM, Oracle etc. No matter what this&amp;nbsp;background&amp;nbsp;is WS lacks&amp;nbsp;&lt;b&gt;mass adoption&lt;/b&gt;. It seems only the big companies with lot of money and resources invest on Web Service adoption. For sometime I was bothered by this strange situation. Why such a robust and well thought out messaging paradigm backed by industry giants lacks the adoption?&lt;br /&gt;
&lt;br /&gt;
On the other hand &lt;a href=&quot;http://en.wikipedia.org/wiki/Representational_state_transfer&quot; target=&quot;_blank&quot;&gt;REST&lt;/a&gt; doesn&#39;t have any of the nice things about Web Services. It doesn&#39;t have a well thought metadata model, comprehensive tooling support or a standard security model.&amp;nbsp;But against all odds REST seems to be gaining traction and becoming the cool thing in communication. Everyone wants to build a cool REST Api.&lt;br /&gt;
&lt;br /&gt;
So what is wrong with SOAP and what is so appealing about REST?&lt;br /&gt;
&lt;br /&gt;
In my perspective this all lies in the developer mind set. Developers love when the sky is the limit for their programming. They want to create unique designs that no one else has done. They want to explore the unknown.&lt;br /&gt;
&lt;br /&gt;
REST as a framework gives the developers exactly that. The freedom to innovate. Developers love that. As a framework REST introduces very few rules. Most of them are not even rules. Rather they are soft guidelines. So building a proper powerful REST API is an Art and a challenging task. In my opinion this makes it cool.&lt;br /&gt;
&lt;br /&gt;
This is completely opposite to SOAP. SOAP gives the developer all the rules. First thing about SOAP is you get a SOAP envelope where you have to put your data according to some rules.&amp;nbsp;So from start to end the system is pretty well defined. There are standards for doing even the simplest things. Top of all this SOAP is very complex to understand. So in my opinion SOAP doesn&#39;t give user the nuts and bolts to innovate. Instead it gives a half baked solution that user has to obey. I guess not all developers like to bog down by rules and they don&#39;t like to learn that kind of rules as well.&lt;br /&gt;
&lt;br /&gt;
There are many aspects to REST vs SOAP than what I have mentioned above. Someone can argue SOAP is better than REST. But I just wanted to express my perspective on what is happening in the world.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/6964260983837518862/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/6964260983837518862' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/6964260983837518862'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/6964260983837518862'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2012/08/rest-vs-soap-adoption-perspective.html' title='REST vs SOAP Adoption - A Perspective'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-1166044177043430919</id><published>2012-07-31T10:52:00.000-04:00</published><updated>2012-07-31T10:54:37.533-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Google Chrome"/><category scheme="http://www.blogger.com/atom/ns#" term="Linux"/><category scheme="http://www.blogger.com/atom/ns#" term="Ubuntu"/><title type='text'>Install Google Chrome on Ubuntu 11</title><content type='html'>Download the &lt;a href=&quot;https://www.google.com/intl/en/chrome/browser/&quot; target=&quot;_blank&quot;&gt;Google Chrome&lt;/a&gt; from the internet.&lt;br /&gt;
&lt;br /&gt;
Go to the download folder and execute the command&lt;br /&gt;
&lt;br /&gt;
sudo dpkg -i google-chrome.deb&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
sudo dpkg -i google-chrome-stable_current_i386.deb&lt;br /&gt;
&lt;br /&gt;
If it fails due to un-satisfied dependencies&lt;br /&gt;
&lt;br /&gt;
Use the following command&lt;br /&gt;
&lt;br /&gt;
sudo apt-get -f install&lt;br /&gt;
&lt;br /&gt;
This will download the dependencies and install Google-Chrome.&lt;br /&gt;
&lt;br /&gt;
Enjoy!&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/1166044177043430919/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/1166044177043430919' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/1166044177043430919'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/1166044177043430919'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2012/07/install-google-chrome-on-ubuntu-11.html' title='Install Google Chrome on Ubuntu 11'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-5261806335190393111</id><published>2012-05-18T16:49:00.001-04:00</published><updated>2012-05-18T16:49:46.447-04:00</updated><title type='text'>Counting the code lines in a Java program</title><content type='html'>To count the code lines in a java program use the command&lt;br /&gt;
&lt;br /&gt;
find . -name &quot;*.java&quot; -not -iwholename &#39;*target*&#39; -not -iwholename &quot;*.svn*&quot; | xargs wc -l&lt;br /&gt;
&lt;br /&gt;
This will search for .java files and ignore the files in target and .svn directories.&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/5261806335190393111/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/5261806335190393111' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/5261806335190393111'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/5261806335190393111'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2012/05/counting-code-lines-in-java-program.html' title='Counting the code lines in a Java program'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-8860321231771148365</id><published>2012-03-27T11:18:00.002-04:00</published><updated>2012-03-27T11:18:43.615-04:00</updated><title type='text'>Password protect a file in Linux</title><content type='html'>We can use the &lt;a href=&quot;http://www.gnupg.org/&quot; target=&quot;_blank&quot;&gt;gpg&lt;/a&gt; utility to password protect a file in Unix based systems. The command&lt;br /&gt;
&lt;br /&gt;
gpg -c filename&lt;br /&gt;
&lt;br /&gt;
will ask for a password and create a new file with the extention .gpg. Now the new file is a password protected file.&lt;br /&gt;
&lt;br /&gt;
To decrypt the file, just use&lt;br /&gt;
&lt;br /&gt;
gpg &quot;protectedfilename&quot;&lt;br /&gt;
&lt;br /&gt;
It will ask for the password and decrypt the file.</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/8860321231771148365/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/8860321231771148365' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/8860321231771148365'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/8860321231771148365'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2012/03/password-protect-file-in-linux.html' title='Password protect a file in Linux'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-3477943330569825287</id><published>2012-03-21T22:28:00.002-04:00</published><updated>2012-03-21T22:29:27.436-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="client"/><category scheme="http://www.blogger.com/atom/ns#" term="HTTP"/><category scheme="http://www.blogger.com/atom/ns#" term="HTTPCore"/><category scheme="http://www.blogger.com/atom/ns#" term="Java NIO"/><category scheme="http://www.blogger.com/atom/ns#" term="streaming"/><title type='text'>Streaming HTTP Client using Apache HTTPCore-NIO</title><content type='html'>Recently I&#39;m working on a sensor project where we need to transfer large amount of sensor data. These data includes&amp;nbsp;Video&amp;nbsp;streams, &lt;a href=&quot;http://www.xbox.com/en-US/kinect&quot; target=&quot;_blank&quot;&gt;Kinetic&lt;/a&gt; data etc. Due to the high volume of data it is&amp;nbsp;necessary&amp;nbsp;to have a client that can transfer data using a constant amount of memory.&lt;br /&gt;
&lt;br /&gt;
Java NIO technology is a best fit for writing such a client because it gives the total control over how the data is handled. Also we have used the &lt;a href=&quot;http://www.w3.org/Protocols/rfc2616/rfc2616.html&quot; target=&quot;_blank&quot;&gt;HTTP&lt;/a&gt; as the wire protocol for transferring the data. HTTP with chunked transfer encoding can be used to stream data. For this project we are using &lt;a href=&quot;http://hc.apache.org/httpcomponents-core-ga/httpcore-nio/index.html&quot;&gt;Apache HTTP Core NIO&lt;/a&gt; for writing the client. Apache HTTP Core NIO is a set of libraries for writing efficient HTTP clients and servers. The code for the client can be found in &lt;a href=&quot;https://github.com/&quot; target=&quot;_blank&quot;&gt;github&lt;/a&gt; at the location&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;https://github.com/iotcloud/IoTCloud/blob/master/modules/streaming-server/src/main/java/cgl/iotcloud/streaming/http/client/core/HttpCoreClient.java&quot;&gt;https://github.com/iotcloud/IoTCloud/blob/master/modules/streaming-server/src/main/java/cgl/iotcloud/streaming/http/client/core/HttpCoreClient.java&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
The send method of the written client takes the data as a input stream. The nice thing about this implementation is that the input stream is backed by a constant memory buffer. So when the buffer is full the write to the input stream is blocked until more space is available. All this is achieved with the Java NIO technology and I&#39;m not going to go in to the technical details. Still we haven&#39;t done lot of testing on the client but we are hoping to do so soon.</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/3477943330569825287/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/3477943330569825287' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/3477943330569825287'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/3477943330569825287'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2012/03/streaming-http-client-using-apache.html' title='Streaming HTTP Client using Apache HTTPCore-NIO'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-3346117348404215155</id><published>2012-03-21T09:41:00.000-04:00</published><updated>2012-03-21T14:57:34.160-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="command"/><category scheme="http://www.blogger.com/atom/ns#" term="move"/><category scheme="http://www.blogger.com/atom/ns#" term="script"/><category scheme="http://www.blogger.com/atom/ns#" term="svn"/><title type='text'>Command for SVN Move directories selectively based on a search criteria</title><content type='html'>I wanted to search and move particular directories in a svn project by replacing part of there name. Here is the command I&#39;ve used.&lt;br /&gt;
&lt;br /&gt;
find . -depth -type d -name &quot;*to_change_directory*&quot; -print | while read ; do svn mv $REPLY `echo $REPLY | sed s/to_change_directory/changed_directory/` ; done&lt;br /&gt;
&lt;br /&gt;
Here I&#39;m moving the directories by replacing the part &quot;to_change_directory&quot; to &quot;changed_directory&quot;. For example&lt;br /&gt;
&lt;br /&gt;
TESTto_change_directoryTEST will be moved to TESTchanged_directoryTEST.&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/3346117348404215155/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/3346117348404215155' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/3346117348404215155'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/3346117348404215155'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2012/03/command-for-svn-move-directories.html' title='Command for SVN Move directories selectively based on a search criteria'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-5334250590526147181</id><published>2012-03-16T12:21:00.002-04:00</published><updated>2012-03-21T22:36:04.819-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="chunk"/><category scheme="http://www.blogger.com/atom/ns#" term="curl"/><category scheme="http://www.blogger.com/atom/ns#" term="HTTP"/><category scheme="http://www.blogger.com/atom/ns#" term="POST"/><title type='text'>POST file using Curl with chunked encoding</title><content type='html'>Curl is a very useful tool for communicating with HTTP servers. Here is a command for sending a large file with chunked transfer encoding.&lt;br /&gt;
&lt;br /&gt;
curl -v -X POST &amp;nbsp;--header &quot;Transfer-Encoding: chunked&quot; -d @Test.txt &quot;http://localhost:5000/&quot;&lt;br /&gt;
&lt;br /&gt;
Note: we have to set the header&amp;nbsp;Transfer-Encoding: chunked.</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/5334250590526147181/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/5334250590526147181' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/5334250590526147181'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/5334250590526147181'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2012/03/post-file-using-curl-with-chunked.html' title='POST file using Curl with chunked encoding'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-738282933952878911</id><published>2012-03-05T18:49:00.001-05:00</published><updated>2012-03-28T10:13:04.536-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="data mining"/><category scheme="http://www.blogger.com/atom/ns#" term="java"/><category scheme="http://www.blogger.com/atom/ns#" term="k-means"/><category scheme="http://www.blogger.com/atom/ns#" term="kmeans"/><category scheme="http://www.blogger.com/atom/ns#" term="sample"/><title type='text'>K-Means algorithm implementation in Java</title><content type='html'>We have given a homework assignment in Data-Mining class to implement the &lt;a href=&quot;http://en.wikipedia.org/wiki/K-means_clustering&quot;&gt;k-means algorithm&lt;/a&gt;  and it was a pretty exciting and fun home work assignment to work on.  We could get our hands dirty with a real data set and a real data mining  algorithm. So I thought of putting the work in &lt;a href=&quot;https://github.com/supunkamburugamuva/Kmeans&quot;&gt;github&lt;/a&gt; so that everyone can use the algorithm.&lt;br /&gt;
&lt;br /&gt;
K-Means is a simple yet very powerful algorithm for clustering data. It  is a predictive algorithm for determine the clusters. There is a whole  lot of research done around K-Means because it provides a fast and  reliable solutions for most practical applications. The idea is to put  the data points in to a cluster with the smallest distance from the  clusters mean to the data point. We do this iteratively until we hit  some threshold. These threshold can be very simple like constant number  of iterations or it can be very complex based on the variance and the  quality of the data in clusters. &lt;br /&gt;
&lt;br /&gt;
The algorithm I have developed is pretty generic one and we&#39;ve used the &lt;a href=&quot;http://archive.ics.uci.edu/ml/datasets/Breast+Cancer+Wisconsin+%28Diagnostic%29&quot;&gt;Wisconsin breast cancer data&lt;/a&gt; as the sample data for clustering.Bulk of the Code is pretty generic and can be used for clustering other data sets as well.&lt;br /&gt;
&lt;br /&gt;
One of the best things about the k-means is that there are so many  parameters to tune it. This means depending on the nature of the data  set user has to do some investigations to pick the correct set of  parameters. In the given implementation I have made the following  parameters configurable. I have included the default implementation of  these configurations but user can extend the code to integrate their own  as well.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt; Number of Centroids&lt;/b&gt; - This is the number of centroids to be used, and is the k of the algorithm&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt; Centroid Initialization&lt;/b&gt; - User has the choice of two method. &lt;br /&gt;
&lt;br /&gt;
&lt;ol&gt;
&lt;li&gt;Data is put in to k partitions randomly and the mean of these partitions are taken as the initial centroids&lt;/li&gt;
&lt;li&gt;k data points are selected randomly and used as the centroids&lt;/li&gt;
&lt;/ol&gt;
&lt;b&gt;Splitting&lt;/b&gt; -&amp;nbsp;If a partition becomes empty we are going to split another partition  in to two so that we can maintain the k number of partitions. User has  the choice of selecting two different splitting methods.&lt;br /&gt;
&lt;ol&gt;
&lt;li&gt;Get the largest partition and split it in to two equal parts randomly&lt;/li&gt;
&lt;li&gt;Get the partition with the largest variance and get the data point that is at a maximum distance from the mean of that partition&lt;/li&gt;
&lt;/ol&gt;
&lt;b&gt;Distance algorithm&lt;/b&gt; -&amp;nbsp;The default implementation has 3 built in algorithms for calculating the distances.&lt;br /&gt;
&lt;ol&gt;
&lt;li&gt;Euclidean distance&lt;/li&gt;
&lt;li&gt;Euclidean squared distance&lt;/li&gt;
&lt;li&gt;Manhattan distance&lt;br /&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;b&gt;Stopping threshold&lt;/b&gt; -&amp;nbsp;Here also user has two choices&lt;br /&gt;
&lt;ol&gt;
&lt;li&gt;Algorithm can be stopped at a constant number of iterations&lt;/li&gt;
&lt;li&gt;Or algorithm is stopped when we get the same set of centroids  repeatedly. Here to compare the two centroids a comparison error can be  specified&lt;/li&gt;
&lt;/ol&gt;
At the end of clustering we calculated the PPV value of the clusters.  Also we did a 10 fold cross validation of the data as well.&lt;br /&gt;
&lt;br /&gt;
The source code can be found in github and the url is https://github.com/supunkamburugamuva/Kmeans. The source is distributed  under Apache License Version 2 and you are welcome to contribute and use  the code without any restrictions.</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/738282933952878911/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/738282933952878911' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/738282933952878911'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/738282933952878911'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2012/03/we-have-given-homework-assignment-in.html' title='K-Means algorithm implementation in Java'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-5586473643575165174</id><published>2011-09-25T23:47:00.001-04:00</published><updated>2011-09-26T22:39:44.619-04:00</updated><title type='text'>Is the innovation in movie industry diminishing?</title><content type='html'>&lt;div xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;Here are the top 10 box office movies of the year 2011 so far.&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; background-color: white; color: black; font-family: sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: 19px; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;table class=&quot;wikitable sortable&quot; id=&quot;sortable_table_id_0&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: #f9f9f9; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-collapse: collapse; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; color: black; font-size: 13px; margin-bottom: auto; margin-left: auto; margin-right: auto; margin-top: auto;&quot;&gt;&lt;tbody&gt;
&lt;tr&gt;&lt;th style=&quot;background-attachment: initial; background-clip: initial; background-color: #f2f2f2; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em; text-align: center;&quot;&gt;Rank&lt;a class=&quot;sortheader&quot; href=&quot;http://en.wikipedia.org/wiki/2011_in_film#&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; margin-bottom: 0px; margin-left: 0.3em; margin-right: 0.3em; margin-top: 0px; text-decoration: none;&quot;&gt;&lt;span class=&quot;sortarrow&quot;&gt;&lt;img alt=&quot;↓&quot; src=&quot;http://bits.wikimedia.org/skins-1.17/common/images/sort_none.gif&quot; style=&quot;border-bottom-style: none; border-color: initial; border-left-style: none; border-right-style: none; border-top-style: none; border-width: initial; vertical-align: middle;&quot; /&gt;&lt;/span&gt;&lt;/a&gt;&lt;/th&gt;&lt;th style=&quot;background-attachment: initial; background-clip: initial; background-color: #f2f2f2; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em; text-align: center;&quot;&gt;Title&lt;a class=&quot;sortheader&quot; href=&quot;http://en.wikipedia.org/wiki/2011_in_film#&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; margin-bottom: 0px; margin-left: 0.3em; margin-right: 0.3em; margin-top: 0px; text-decoration: none;&quot;&gt;&lt;span class=&quot;sortarrow&quot;&gt;&lt;img alt=&quot;↓&quot; src=&quot;http://bits.wikimedia.org/skins-1.17/common/images/sort_none.gif&quot; style=&quot;border-bottom-style: none; border-color: initial; border-left-style: none; border-right-style: none; border-top-style: none; border-width: initial; vertical-align: middle;&quot; /&gt;&lt;/span&gt;&lt;/a&gt;&lt;/th&gt;&lt;th style=&quot;background-attachment: initial; background-clip: initial; background-color: #f2f2f2; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em; text-align: center;&quot;&gt;Studio&lt;a class=&quot;sortheader&quot; href=&quot;http://en.wikipedia.org/wiki/2011_in_film#&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; margin-bottom: 0px; margin-left: 0.3em; margin-right: 0.3em; margin-top: 0px; text-decoration: none;&quot;&gt;&lt;span class=&quot;sortarrow&quot;&gt;&lt;img alt=&quot;↓&quot; src=&quot;http://bits.wikimedia.org/skins-1.17/common/images/sort_none.gif&quot; style=&quot;border-bottom-style: none; border-color: initial; border-left-style: none; border-right-style: none; border-top-style: none; border-width: initial; vertical-align: middle;&quot; /&gt;&lt;/span&gt;&lt;/a&gt;&lt;/th&gt;&lt;th style=&quot;background-attachment: initial; background-clip: initial; background-color: #f2f2f2; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em; text-align: center;&quot;&gt;Worldwide&lt;a class=&quot;sortheader&quot; href=&quot;http://en.wikipedia.org/wiki/2011_in_film#&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; margin-bottom: 0px; margin-left: 0.3em; margin-right: 0.3em; margin-top: 0px; text-decoration: none;&quot;&gt;&lt;span class=&quot;sortarrow&quot;&gt;&lt;img alt=&quot;↓&quot; src=&quot;http://bits.wikimedia.org/skins-1.17/common/images/sort_none.gif&quot; style=&quot;border-bottom-style: none; border-color: initial; border-left-style: none; border-right-style: none; border-top-style: none; border-width: initial; vertical-align: middle;&quot; /&gt;&lt;/span&gt;&lt;/a&gt;&lt;/th&gt;&lt;th style=&quot;background-attachment: initial; background-clip: initial; background-color: #f2f2f2; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em; text-align: center;&quot;&gt;US and Canada&lt;a class=&quot;sortheader&quot; href=&quot;http://en.wikipedia.org/wiki/2011_in_film#&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; margin-bottom: 0px; margin-left: 0.3em; margin-right: 0.3em; margin-top: 0px; text-decoration: none;&quot;&gt;&lt;span class=&quot;sortarrow&quot;&gt;&lt;img alt=&quot;↓&quot; src=&quot;http://bits.wikimedia.org/skins-1.17/common/images/sort_none.gif&quot; style=&quot;border-bottom-style: none; border-color: initial; border-left-style: none; border-right-style: none; border-top-style: none; border-width: initial; vertical-align: middle;&quot; /&gt;&lt;/span&gt;&lt;/a&gt;&lt;/th&gt;&lt;th style=&quot;background-attachment: initial; background-clip: initial; background-color: #f2f2f2; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em; text-align: center;&quot;&gt;UK&lt;a class=&quot;sortheader&quot; href=&quot;http://en.wikipedia.org/wiki/2011_in_film#&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; margin-bottom: 0px; margin-left: 0.3em; margin-right: 0.3em; margin-top: 0px; text-decoration: none;&quot;&gt;&lt;span class=&quot;sortarrow&quot;&gt;&lt;img alt=&quot;↓&quot; src=&quot;http://bits.wikimedia.org/skins-1.17/common/images/sort_none.gif&quot; style=&quot;border-bottom-style: none; border-color: initial; border-left-style: none; border-right-style: none; border-top-style: none; border-width: initial; vertical-align: middle;&quot; /&gt;&lt;/span&gt;&lt;/a&gt;&lt;/th&gt;&lt;th style=&quot;background-attachment: initial; background-clip: initial; background-color: #f2f2f2; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em; text-align: center;&quot;&gt;Australia&lt;a class=&quot;sortheader&quot; href=&quot;http://en.wikipedia.org/wiki/2011_in_film#&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; margin-bottom: 0px; margin-left: 0.3em; margin-right: 0.3em; margin-top: 0px; text-decoration: none;&quot;&gt;&lt;span class=&quot;sortarrow&quot;&gt;&lt;img alt=&quot;↓&quot; src=&quot;http://bits.wikimedia.org/skins-1.17/common/images/sort_none.gif&quot; style=&quot;border-bottom-style: none; border-color: initial; border-left-style: none; border-right-style: none; border-top-style: none; border-width: initial; vertical-align: middle;&quot; /&gt;&lt;/span&gt;&lt;/a&gt;&lt;/th&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;1&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Harry_Potter_and_the_Deathly_Hallows_%E2%80%93_Part_2&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Harry Potter and the Deathly Hallows – Part 2&quot;&gt;Harry Potter and the Deathly Hallows – Part 2&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Warner_Bros.&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Warner Bros.&quot;&gt;Warner Bros.&lt;/a&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$1,325,066,054&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$378,366,054&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$114,820,753&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$54,319,291&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;2&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Transformers:_Dark_of_the_Moon&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Transformers: Dark of the Moon&quot;&gt;Transformers: Dark of the Moon&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Paramount_Pictures&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Paramount Pictures&quot;&gt;Paramount Pictures&lt;/a&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$1,117,601,953&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$351,458,166&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$45,470,012&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$38,820,321&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;3&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Pirates_of_the_Caribbean:_On_Stranger_Tides&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Pirates of the Caribbean: On Stranger Tides&quot;&gt;Pirates of the Caribbean: On Stranger Tides&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Walt_Disney_Pictures&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Walt Disney Pictures&quot;&gt;Walt Disney Pictures&lt;/a&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$1,039,529,902&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$241,011,325&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$54,187,325&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$29,006,640&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;4&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Kung_Fu_Panda_2&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Kung Fu Panda 2&quot;&gt;Kung Fu Panda 2&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/DreamWorks_Animation&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;DreamWorks Animation&quot;&gt;DreamWorks Animation&lt;/a&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$659,146,003&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$165,146,003&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$27,062,099&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$20,219,645&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;5&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Fast_Five&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Fast Five&quot;&gt;Fast Five&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Universal_Studios&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Universal Studios&quot;&gt;Universal Pictures&lt;/a&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$609,484,033&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$209,837,675&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$30,243,825&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$26,794,607&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;6&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/The_Hangover_Part_II&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;The Hangover Part II&quot;&gt;The Hangover Part II&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;Warner Bros.&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$581,464,305&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$254,464,305&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$53,496,869&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$35,371,018&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;7&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Cars_2&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Cars 2&quot;&gt;Cars 2&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;Walt Disney Pictures /&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Pixar&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Pixar&quot;&gt;Pixar&lt;/a&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$550,079,088&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$189,679,088&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$24,894,721&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$20,811,602&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;8&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Rio_%28film%29&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Rio (film)&quot;&gt;Rio&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/20th_Century_Fox&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;20th Century Fox&quot;&gt;20th Century Fox&lt;/a&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$483,886,518&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$143,619,809&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$21,536,048&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$17,230,382&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;9&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/The_Smurfs_%28film%29&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;The Smurfs (film)&quot;&gt;The Smurfs&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Columbia_Pictures&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Columbia Pictures&quot;&gt;Columbia Pictures&lt;/a&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$483,360,857&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$137,759,100&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$24,454,426&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$3,634,929&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;10&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;&lt;i&gt;&lt;a href=&quot;http://en.wikipedia.org/wiki/Thor_%28film%29&quot; style=&quot;background-attachment: initial; background-clip: initial; background-color: initial; background-image: none; background-origin: initial; background-position: initial initial; background-repeat: initial initial; color: #0645ad; text-decoration: none;&quot; title=&quot;Thor (film)&quot;&gt;Thor&lt;/a&gt;&lt;/i&gt;&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;Paramount Pictures&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$448,512,824&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$181,030,624&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$22,521,717&lt;/td&gt;&lt;td style=&quot;border-bottom-color: rgb(170, 170, 170); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(170, 170, 170); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(170, 170, 170); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(170, 170, 170); border-top-style: solid; border-top-width: 1px; padding-bottom: 0.2em; padding-left: 0.2em; padding-right: 0.2em; padding-top: 0.2em;&quot;&gt;$20,135,378&lt;/td&gt;&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;
Out of the 10, first seven movies are attempts to create the same glory as they did with the very successful first movie of the sequel. But the ratings of all these seven movies are pretty low and their success is mainly due to the fact that they are part of sequel with a very successful first movie. &lt;br /&gt;
&lt;br /&gt;
Here are the ratings given to these movies by yahoo users. The critics ratings are worst than that. &lt;br /&gt;
&lt;br /&gt;
1. Harry potter&amp;nbsp;&amp;nbsp; A-&lt;br /&gt;
2. Transformers&amp;nbsp; B&lt;br /&gt;
3. Pirates&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; B&lt;br /&gt;
4. Panda&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; A-&lt;br /&gt;
5. Fast Five&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; A-&lt;br /&gt;
6. Hangover&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; B-&lt;br /&gt;
7. Cars 2&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; B+&lt;br /&gt;
&lt;br /&gt;
Some of the movies like Transformers and Pirates are very lame attempts  to create a movie out of thin air and they are more like putting  together some random scenes.&lt;br /&gt;
&lt;br /&gt;
So what does this mean? Aren&#39;t there any ideas left that can be turned in to a great movie? Or we have seen so many movies that any new idea is just a new way of looking at an old idea. &lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/5586473643575165174/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/5586473643575165174' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/5586473643575165174'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/5586473643575165174'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2011/09/is-innovation-in-movie-industry.html' title='Is the innovation in movie industry diminishing?'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-1260457144995486112</id><published>2011-09-09T00:12:00.001-04:00</published><updated>2011-09-09T00:12:50.141-04:00</updated><title type='text'>After a long time</title><content type='html'>&lt;div xmlns=&#39;http://www.w3.org/1999/xhtml&#39;&gt;It is being a long time since I&#39;ve posted my last blog entry. It was a busy time with a lot happening. To make it short I&#39;ve started my higher studies in Indiana University Bloomington as a Compute Science Graduate student under Prof. Geoffrey Fox. I did resign from WSO2. I had a great time at WSO2 and would like to thank all the friends and specially Dr. Sanjiva Weerawarana&lt;span class=&#39;tl&#39;/&gt; for the great time I had in WSO2. &lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/1260457144995486112/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/1260457144995486112' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/1260457144995486112'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/1260457144995486112'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2011/09/after-long-time.html' title='After a long time'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-8575461166518034606</id><published>2010-09-23T12:05:00.001-04:00</published><updated>2010-09-23T12:07:20.462-04:00</updated><title type='text'>Approaching the Tipping point of Web Services</title><content type='html'>&lt;div xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;&lt;style type=&quot;text/css&quot;&gt;
   
&lt;/style&gt;    &lt;br /&gt;
&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;Every technology that is meant to last has similar adoption patterns. Here is a graph describing the time vs users.&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipTPi16TCDQ0WE_fops4eIk4AwBcrzd5-mpLoRTFzb-hIdl95OrcRSl10c5cg6v33El0-tIlq-zw1ISHzEOGhYxKD96WfgISLqUhFTCR-4Bgg5HiKwcjU5pnR-4W_q1qCLP22A5ge2v0L8/s1600/tipping.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;241&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipTPi16TCDQ0WE_fops4eIk4AwBcrzd5-mpLoRTFzb-hIdl95OrcRSl10c5cg6v33El0-tIlq-zw1ISHzEOGhYxKD96WfgISLqUhFTCR-4Bgg5HiKwcjU5pnR-4W_q1qCLP22A5ge2v0L8/s320/tipping.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;At the initial stages only the early adopters  dare to use a fresh technology. Early adopters has advantages as well as disadvantages. &lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;Biggest disadvantage or risk comes for an early adopter because the implementations of the technology are not matured. A product implementing a fresh technology may seize to work in a critical moment. But early adopters do get lots of advantages as well. They get the best support and special attention from the vendors as well as they get to influence the implementation of the technology. Also early adopters has the competitive advantage over their competitors because of the adoption of advanced technologies. In these stages the usage of the products is a random and there is no increase of decrease to be seen in terms of users.&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;After the early adopters the technology is open to more general users. In these stages the usage of the technology or the products slowly increases.  This is where general users start to think about adopting the new technologies. But majority of the users still not comfortable to use the new products and they are waiting for their confidence to build up to the right level.&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;This means during this adoption period where gradual increase of usage happens there is a very large group of people building up, who are hoping to use the products but the attributes are not at the correct level for them. These are the normal users who uses a technology for every day usages. They just wait until the correct moment.&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;When we reach the state where normal people start using the technology we can see a sudden dramatic increase in a technology because of this large group of people who were waiting. This is what we call a “&lt;b&gt;Tipping Point&lt;/b&gt;”.&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;Web Services are now in the adoption stage where there is a gradual smooth increase. Web services was founded around six seven years ago. But the adoption was slow due to its complexity. Although it is complex web services provides the only solution agreed across all the key player for a very real problem. Problem is to connect the various computing resources. So web services as a technology is bound to be used by the majority.&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;Right now it is used mostly by the high tech companies with a long vision and a pile of money to spend. But I believe in a few years time we will reach the tipping point of web services. It will at least take another year and a half to reach that point. But we will hit that tipping point for sure.&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;Reaching the tipping point will be great from the technological point of view. But it will bring greater challenges to the companies creating web services middle ware as well. The biggest challenge will be the diverse use of web services. We will see people using it for all kinds of crazy things. Best way to succeed in this kind of a wide customer base is to have technologically sound products.  Companies with the most technically sound products will prosper and others will gradually fade away.&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;margin-bottom: 0in;&quot;&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;zemanta-pixie&quot;&gt;&lt;img alt=&quot;&quot; class=&quot;zemanta-pixie-img&quot; src=&quot;http://img.zemanta.com/pixy.gif?x-id=29da0b39-e86b-87ec-a065-82b2c21cf044&quot; /&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/8575461166518034606/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/8575461166518034606' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/8575461166518034606'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/8575461166518034606'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/09/approaching-tipping-point-of-web.html' title='Approaching the Tipping point of Web Services'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipTPi16TCDQ0WE_fops4eIk4AwBcrzd5-mpLoRTFzb-hIdl95OrcRSl10c5cg6v33El0-tIlq-zw1ISHzEOGhYxKD96WfgISLqUhFTCR-4Bgg5HiKwcjU5pnR-4W_q1qCLP22A5ge2v0L8/s72-c/tipping.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-6037508530143405113</id><published>2010-09-15T02:15:00.001-04:00</published><updated>2010-09-15T02:15:29.359-04:00</updated><title type='text'>Refactoring Java Singletons to regular classes</title><content type='html'>&lt;div xmlns=&#39;http://www.w3.org/1999/xhtml&#39;&gt;One of the really bad things about a Java singleton is when you use it, you never think about  the correct place to create it. Even if a class is implemented as a singleton there is always a logical place for a singleton. This is really important in getting your design right. But with singletons we tend to forget about this and design the things incorrectly.&lt;br/&gt;&lt;br/&gt;When the time comes to get rid of the singletons it becomes very hard due to the design constraints.&lt;br/&gt;&lt;br/&gt;&lt;div class=&#39;zemanta-pixie&#39;&gt;&lt;img src=&#39;http://img.zemanta.com/pixy.gif?x-id=91c6fe47-d13f-88b6-9f44-acd33120fdac&#39; alt=&#39;&#39; class=&#39;zemanta-pixie-img&#39;/&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/6037508530143405113/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/6037508530143405113' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/6037508530143405113'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/6037508530143405113'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/09/refactoring-java-singletons-to-regular.html' title='Refactoring Java Singletons to regular classes'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-1955097333440606935</id><published>2010-06-07T10:43:00.001-04:00</published><updated>2010-06-07T10:43:30.201-04:00</updated><title type='text'>Difference between service chaining and callouts in WSO2 ESB</title><content type='html'>&lt;div xmlns=&#39;http://www.w3.org/1999/xhtml&#39;&gt;In a typical integration there can be a single service exposed supported by two implementation services.  &lt;br/&gt;&lt;br/&gt;Client ---------&amp;gt; ESB ------&amp;gt; Service 1&lt;br/&gt;                                ------&amp;gt; Service 2&lt;br/&gt;Scenario 1:&lt;br/&gt;When the request comes to the ESB it should be validated by sending to the Service 1. If the request is valid it should be sent to service 2&lt;br/&gt;&lt;br/&gt;Scenario 2:&lt;br/&gt;Request only has few information. In order to access the service 2,  there is some information that need to be retrieved from service 1. After retrieving this information request must be transformed. In this case before sending the request to service 2, request must be enhanced with information from service 1.&lt;br/&gt;&lt;br/&gt;Obviously Scenario 1 fits Service chaining because it is chained invocation. You invoke service 1 then invoke service 2. This kind of invocation should be done using the &lt;a href=&#39;http://wso2.org/project/esb/java/3.0.0/docs/configuration_language.html#send&#39;&gt;send&lt;/a&gt; mediator instead of &lt;a href=&#39;http://wso2.org/project/esb/java/3.0.0/docs/configuration_language.html#callout&#39;&gt;callout&lt;/a&gt; mediator of &lt;a href=&#39;http://wso2.com/products/enterprise-service-bus/&#39;&gt;WSO2 ESB&lt;/a&gt;.&lt;br/&gt;&lt;br/&gt;Scenario 2 is bit different. Before proceeding with the request message we need to enhance it with information from service 1. So by looking at the problem we can see it requires a blocking call to the service 1 to get some information. This kind of invocation can be done using the &lt;a href=&#39;http://wso2.org/project/esb/java/3.0.0/docs/configuration_language.html#send&#39;&gt;send&lt;/a&gt; mediator. But my belief is it fits more with the &lt;a href=&#39;http://wso2.org/project/esb/java/3.0.0/docs/configuration_language.html#callout&#39;&gt;callout&lt;/a&gt; mediator which does blocking calls.&lt;br/&gt;&lt;br/&gt;For more info please refer the &lt;a href=&#39;http://wso2.org/project/esb/java/3.0.0/docs/configuration_language.html&#39;&gt;configuration langauge guide&lt;/a&gt; of WSO2 ESB.&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;div class=&#39;zemanta-pixie&#39;&gt;&lt;img src=&#39;http://img.zemanta.com/pixy.gif?x-id=bf6a2e8a-36dd-8fb8-a8f3-ea02d0d59c22&#39; alt=&#39;&#39; class=&#39;zemanta-pixie-img&#39;/&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/1955097333440606935/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/1955097333440606935' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/1955097333440606935'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/1955097333440606935'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/06/difference-between-service-chaining-and.html' title='Difference between service chaining and callouts in WSO2 ESB'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-6458061882893655835</id><published>2010-03-29T08:41:00.001-04:00</published><updated>2010-04-08T05:03:40.731-04:00</updated><title type='text'>Worshiped Sri Pada (Adam&amp;#39;s Peak)</title><content type='html'>&lt;div xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjspLmrZm6F12xE5I0s-UfBY9GpSHGH1TUQ3KoSMgvZxh39aq4JY1aJTYhxvGy2P5_fZy1xEzG1VAPpVbV4KBYnHUA1v32HrP9t5Qj9YKzckPjlAMWduaEqpJKXYBFJoHKzvv74OP8E4qLI/s1600-h/IMG_3604%5B8%5D.jpg&quot;&gt;&lt;img alt=&quot;IMG_3604&quot; border=&quot;0&quot; height=&quot;304&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj2YyLLY7Q3kesU8rPelK98tXVvecN1tAZKU-xK-sJgJHHkMKIydnrtIexAz3TQ_kPeZ-m5zOHXFJtWV23o9DXjm6_jHVRhEI2lPMQ4wPQNd33j3cCfzSFeTaf_hzvvw5FkljzOQMXdMWXP/?imgmax=800&quot; style=&quot;border-bottom: 0px; border-left: 0px; border-right: 0px; border-top: 0px; display: inline;&quot; title=&quot;IMG_3604&quot; width=&quot;640&quot; /&gt;&lt;/a&gt; &lt;/div&gt;&lt;div xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;&lt;/div&gt;&lt;div xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;We went to Sri Pada during the last week end (27th &amp;amp; 28th March). It was a family trip with my family and my mother&#39;s sister&#39;s family.    &lt;br /&gt;
&lt;br /&gt;
We went through the Hatton Road. The most beautiful road to Sri Pada is through Ratnapura Kuruwita. But it is the hardest as well. We didn&#39;t take that road because it could be very hard for my mother and aunt.     &lt;br /&gt;
&lt;br /&gt;
We started climbing around 8 p.m. Then it was raining very hard. We climbed very slowly. We often climbed 50 steps and took a rest for 15 mins.     &lt;br /&gt;
&lt;br /&gt;
Week end was very busy for Sri Pada&amp;nbsp;because&amp;nbsp;people were pouring in to visit this great mountain.     &lt;br /&gt;
&lt;br /&gt;
When we were at Mahagiridambe it was really crowded and there was a long line to the peak. It was a very hard journey through Mahagiridambe because we had to stand waiting in a line wasn&#39;t moving very fast.     &lt;br /&gt;
&lt;br /&gt;
We went to the peak around 5 p.m in the morning. We worshiped the Sri Pada pathula and stayed in the peak for around 30 mins. It wasn&#39;t cold as I thought it would be on the peak.     &lt;br /&gt;
&lt;br /&gt;
Then we started descending. Unfortunately the Eastern Sky was full with rainy clouds. We coudn&#39;t see the Ira Savaya.     &lt;br /&gt;
&lt;br /&gt;
Descending was harder than climbing. But we managed it around 11 a.m in the morning. After that we took a little break and came&amp;nbsp;straight&amp;nbsp;home.     &lt;br /&gt;
&lt;br /&gt;
Few friends and myself were lucky enough to clime Sri Pada in the off season last year. I must say climbing Sri Pada in off-season was ten times&amp;nbsp;beautiful,&amp;nbsp;peaceful and adventurous than the journey we took this year in the regular Sri Pada season.     &lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;zemanta-pixie&quot;&gt;&lt;img alt=&quot;&quot; class=&quot;zemanta-pixie-img&quot; src=&quot;http://img.zemanta.com/pixy.gif?x-id=4fff6a68-2ad6-83f9-8fc4-4e8e08025c76&quot; /&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/6458061882893655835/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/6458061882893655835' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/6458061882893655835'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/6458061882893655835'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/03/worshiped-sri-pada-adam-peak.html' title='Worshiped Sri Pada (Adam&amp;#39;s Peak)'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj2YyLLY7Q3kesU8rPelK98tXVvecN1tAZKU-xK-sJgJHHkMKIydnrtIexAz3TQ_kPeZ-m5zOHXFJtWV23o9DXjm6_jHVRhEI2lPMQ4wPQNd33j3cCfzSFeTaf_hzvvw5FkljzOQMXdMWXP/s72-c?imgmax=800" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-2549317210883715656</id><published>2010-03-19T04:43:00.001-04:00</published><updated>2010-03-19T04:43:56.535-04:00</updated><title type='text'>WSO2 ESB Reffering to Resources over a HTTP proxy connection</title><content type='html'>&lt;div xmlns=&#39;http://www.w3.org/1999/xhtml&#39;&gt;With the 3.0.0 upcoming release WSO2 ESB can retrieve resources through a HTTP proxy server. Usually these resources are WSDLs.&lt;br/&gt;&lt;br/&gt;A WSDL may be in a remote server and WSO2 ESB can refer that. But in order to reach the WSDL ESB may have to go through a Proxy Server. &lt;br/&gt;&lt;br/&gt;To configure the proxy settings user has to update the synapse.properties file in the webapps/ROOT/WEB-INF/classes directory. Here is the configuration for enabling the proxy. &lt;br/&gt;&lt;br/&gt;# address of the proxy server&lt;br/&gt;#synapse.http.proxy.host=&lt;br/&gt;# Proxy server port&lt;br/&gt;#synapse.http.proxy.port=&lt;br/&gt;# Proxy server user name, this is used for HTTP basic authentication&lt;br/&gt;#synapse.http.proxy.user=&lt;br/&gt;# Proxy server user password, this is used for HTTP basic authentication&lt;br/&gt;#synapse.http.proxy.password=&lt;br/&gt;# list of host address excluded from going through the proxy, list is comma separated&lt;br/&gt;#synapse.http.proxy.excluded.hosts=localhost, 127.0.0.1&lt;br/&gt;&lt;br/&gt;All the configurations are self explanatory. If user name and password is set ESB will use HTTP basic authentication.&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;div class=&#39;zemanta-pixie&#39;&gt;&lt;img src=&#39;http://img.zemanta.com/pixy.gif?x-id=5bbbcd73-ed61-8786-8ea9-11ac4b08e7ed&#39; alt=&#39;&#39; class=&#39;zemanta-pixie-img&#39;/&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/2549317210883715656/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/2549317210883715656' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/2549317210883715656'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/2549317210883715656'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/03/wso2-esb-reffering-to-resources-over.html' title='WSO2 ESB Reffering to Resources over a HTTP proxy connection'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-4136930427282115665</id><published>2010-03-19T01:42:00.001-04:00</published><updated>2010-03-19T02:16:43.755-04:00</updated><title type='text'>HTTP Basic Authentication over a proxy server with WSO2 ESB</title><content type='html'>&lt;div xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;ESB may be behind a firewall and it may want to talk to a server through a proxy server. A proxy server may require HTTP basic authentication. Here is the scenario I&#39;m talking about. This full scenario is only available with upcoming &lt;a href=&quot;http://wso2.org/downloads/esb&quot;&gt;WSO2 ESB&lt;/a&gt; 3.0.0 release.&lt;br /&gt;
&lt;br /&gt;
Client ----&amp;gt; ESB ----&amp;gt; HTTP Proxy Server -----&amp;gt; Service Provider&lt;br /&gt;
&lt;br /&gt;
There are several configurations that needs to be done in-order to configure ESB to handle this.&lt;br /&gt;
&lt;br /&gt;
First you need to tell ESB that is is behind a Proxy Server. To do this edit the axis2.xml file in the repository/conf directory.&lt;br /&gt;
&lt;br /&gt;
You need to edit the transportSender configuration of the http transport in axis2.xml. The configurations are self explanatory.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;transportSender name=&quot;http&quot; class=&quot;org.apache.synapse.transport.nhttp.HttpCoreNIOSender&quot;&amp;gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;parameter name=&quot;non-blocking&quot; locked=&quot;false&quot;&amp;gt;true&amp;lt;/parameter&amp;gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;parameter name=&quot;http.proxyHost&quot; locked=&quot;false&quot;&amp;gt;localhost&amp;lt;/parameter&amp;gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;parameter name=&quot;http.proxyPort&quot; locked=&quot;false&quot;&amp;gt;8080&amp;lt;/parameter&amp;gt;&lt;br /&gt;
&amp;nbsp;&amp;lt;/transportSender&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then you need to set the following two properties in the synapse configuration before doing the send through the proxy server.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syn:property name=&quot;Proxy-Authorization&quot; expression=&quot;fn:concat(&#39;Basic &#39;, base64Encode(&#39;userName:password&#39;))&quot; scope=&quot;transport&quot;/&amp;gt;&lt;br /&gt;
&amp;lt;syn:property name=&quot;POST_TO_URI&quot; value=&quot;true&quot; scope=&quot;axis2&quot;/&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The first property set the Proxy-Authorization HTTP transport header with the base64 encoded user name and password as expected by the HTTP basic authentication.&lt;br /&gt;
&lt;br /&gt;
Second property make the out-going url a complete URL understandable by the proxy server.&lt;br /&gt;
&lt;br /&gt;
For example in normal scenarios we send the outgoing request as following&lt;br /&gt;
POST /services/SimpleStockQuoteService HTTP/1.1  &lt;br /&gt;
&lt;br /&gt;
But for proxy server we need to send the actual URL:&lt;br /&gt;
POST http://localhost:9000/services/SimpleStockQuoteService HTTP/1.1 &lt;br /&gt;
&lt;br /&gt;
Here is a Simple sample Proxy service with these two properties&lt;br /&gt;
&lt;br /&gt;
&lt;pre&gt;&amp;lt;syn:proxy name=&quot;StockQuoteProxy&quot; startOnLoad=&quot;true&quot;&amp;gt;
    &amp;lt;syn:target&amp;gt;
        &amp;lt;syn:inSequence&amp;gt;
            &amp;lt;syn:property name=&quot;Proxy-Authorization&quot; expression=&quot;fn:concat(&#39;Basic &#39;, base64Encode(&#39;supun:test123&#39;))&quot; scope=&quot;transport&quot;/&amp;gt;
            &amp;lt;syn:property name=&quot;POST_TO_URI&quot; value=&quot;true&quot; scope=&quot;axis2&quot;/&amp;gt;
            &amp;lt;syn:send&amp;gt;
                &amp;lt;syn:endpoint name=&quot;endpoint_urn_uuid_379C485AD3CB65037F10216600509076498395882&quot;&amp;gt;
                    &amp;lt;syn:address uri=&quot;http://localhost:9000/services/SimpleStockQuoteService&quot;/&amp;gt;
                &amp;lt;/syn:endpoint&amp;gt;
            &amp;lt;/syn:send&amp;gt;
        &amp;lt;/syn:inSequence&amp;gt;
        &amp;lt;syn:outSequence&amp;gt;
            &amp;lt;syn:send/&amp;gt;
        &amp;lt;/syn:outSequence&amp;gt;
    &amp;lt;/syn:target&amp;gt;
    &amp;lt;syn:publishWSDL uri=&quot;file:repository/samples/resources/proxy/sample_proxy_1.wsdl&quot;/&amp;gt;
&amp;lt;/syn:proxy&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
&lt;div class=&quot;zemanta-pixie&quot;&gt;&lt;img alt=&quot;&quot; class=&quot;zemanta-pixie-img&quot; src=&quot;http://img.zemanta.com/pixy.gif?x-id=86759a0a-6b05-8633-9649-d9f2c7f957cf&quot; /&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/4136930427282115665/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/4136930427282115665' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/4136930427282115665'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/4136930427282115665'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/03/http-basic-authentication-over-proxy.html' title='HTTP Basic Authentication over a proxy server with WSO2 ESB'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-365811111216732764</id><published>2010-03-07T09:36:00.001-05:00</published><updated>2010-03-08T09:05:53.248-05:00</updated><title type='text'>My thoughts on WSO2 Carbon Registry Seperation</title><content type='html'>&lt;div xmlns=&quot;http://www.w3.org/1999/xhtml&quot;&gt;For the upcoming Carbon release (3.0.0) we are going to introduce a new registry separation model for all the carbon based applications. I feel there is something fundamentally wrong with this registry separation. But still I&#39;m not clear why I got that feeling. So I thought of writing down my thoughts. This is not a structured post. I&#39;m just writing down my thoughts. &lt;br /&gt;
&lt;br /&gt;
Under the new Registry model there are three registries.&lt;br /&gt;
&lt;br /&gt;
1. Local registry&lt;br /&gt;
2. Configuration registry&lt;br /&gt;
3. Governance registry&lt;br /&gt;
&lt;br /&gt;
First lets look at the problem we are trying to solve using these three registries.&lt;br /&gt;
&lt;br /&gt;
Every program needs configurations to run. These configurations can be coming from a file or can be coming from a UI. Also every program has a state. When we change some configurations or deploy a new component or enable something program state can be changed. A program usually saves its state transparently to the user. For example when we run a program like IntelliJ Idea or ecclipse we can specify some configurations like temp directory, using a configuration file . Some configurations like editing options are saved interanally by these applications and users doesn&#39;t know the format of the stored configuration information. &lt;br /&gt;
&lt;br /&gt;
There is another type of information that a program require. They are application specific configurations. For example an IntelliJ Idea project may be using a JSP Tag Library. IntelliJ Idea has to know the location of this tag library in order to property render the JSP tags. An ESB may require a XSLT file for message transformation. This file has to be stored somewhere accessible from the ESB. &lt;br /&gt;
&lt;br /&gt;
With a tool like intellij Idea configuration storage is always the file system. But with carbon configuraion storage is the WSO2 Governance Registry.&lt;br /&gt;
&lt;br /&gt;
Carbon is another program that has all sorts of configurations. Also a carbon program can run in multiple topologies like Standalone mode with a remote registry. Clustered mode with a remote registry etc. From the carbon perspective it shouldn&#39;t matter weather it is running against a remote registry or a embedded registry. Standalone mode and clustering mode are very important.&lt;br /&gt;
&lt;br /&gt;
There is a very very important concept when it comes to storage requirement of a program. There are only two types of storage requirements to a program.&lt;br /&gt;
&lt;ol&gt;&lt;li&gt;There is state information internal to a program that shouldn&#39;t be exposed to the user as it is. &lt;/li&gt;
&lt;li&gt;There are configurations specified by the user&lt;/li&gt;
&lt;/ol&gt;If we agree to the above fundamental principle there can be two configuration areas to a program.&lt;br /&gt;
&lt;ol&gt;&lt;li&gt;Internal storage space used to store the state information&lt;/li&gt;
&lt;li&gt;Storage space to put user specified configurations&lt;/li&gt;
&lt;/ol&gt;But Carbon introduces three configuration areas. But I think there should be only two configuration areas. A local registry that can be used to store internal stuff to carbon that shouldn&#39;t be exposed to the user and a general registry that can contain all sorts of user configurations.&lt;br /&gt;
&lt;br /&gt;
Different components behave differently in different topologies. One of the ideas behind carbon is when a application runs in standalone mode it should be able to run in clustering mode without any changes. That is one of the fundamental reasons behind registry separation. But clustering and standalone modes are vary different and trying to design a application to run a standalone app in cluster mode can be a bad design decision.&lt;br /&gt;
&lt;br /&gt;
Also carbon wants to start two clusters and share information among the two clusters using the registry. That is why we have the governance registry. But this is a feature that we could have simply achieve at the carbon level without&amp;nbsp;over complicating&amp;nbsp;the registry model.&lt;br /&gt;
&lt;br /&gt;
For me registry is just a storage. It is like a file system or a database. A database provide a generic programming model so does the registry. It is the application level programmers responsibility to use the database properly. Also it is the carbon&#39;s responsibility to use the registry correctly to suite its needs. Changing the registry model to suite carbon&#39;s need is not a good idea.&lt;br /&gt;
&lt;br /&gt;
I may be completely wrong. Every technical decision has its pros and cons.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;zemanta-pixie&quot;&gt;&lt;img alt=&quot;&quot; class=&quot;zemanta-pixie-img&quot; src=&quot;http://img.zemanta.com/pixy.gif?x-id=d86700e2-006f-8d79-99e9-c47625ca3ede&quot; /&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/365811111216732764/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/365811111216732764' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/365811111216732764'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/365811111216732764'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/03/my-thoughts-on-wso2-registry-seperation_07.html' title='My thoughts on WSO2 Carbon Registry Seperation'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-2579158875147430833</id><published>2010-03-06T23:01:00.001-05:00</published><updated>2010-03-06T23:01:06.438-05:00</updated><title type='text'>Amazon Prime, Amazing service</title><content type='html'>&lt;div xmlns=&#39;http://www.w3.org/1999/xhtml&#39;&gt;I&#39;ve subscribed to &lt;a href=&#39;http://www.amazon.com/gp/subs/primeclub/signup/main.html&#39;&gt;Amazon prime shipping&lt;/a&gt;. It is free for the first month. I did not want to subscribe to it any longer than the first month because I&#39;m not living in USA. But I forgot to cancel the prime membership after the first month. So Amazon continued with my prime membership and charged my credit card for the first year membership.&lt;br/&gt;&lt;br/&gt;Amazing thing is I could cancel the prime membership with the total refund. The only condition is I shouldn&#39;t have bought anything after I pay for the prime membership. Isn&#39;t it a wonderful service?&lt;br/&gt;&lt;br/&gt;I just did the cancellation and waiting for Amazon refund. Hope it will arrive as they said.&lt;br/&gt;&lt;br/&gt;&lt;div class=&#39;zemanta-pixie&#39;&gt;&lt;img src=&#39;http://img.zemanta.com/pixy.gif?x-id=9f38ea11-6bed-8a23-9b88-a4a546682610&#39; alt=&#39;&#39; class=&#39;zemanta-pixie-img&#39;/&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/2579158875147430833/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/2579158875147430833' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/2579158875147430833'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/2579158875147430833'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/03/amazon-prime-amazing-service.html' title='Amazon Prime, Amazing service'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-1197843169524706388.post-4613393278160892693</id><published>2010-02-28T12:49:00.000-05:00</published><updated>2010-02-28T12:49:59.318-05:00</updated><title type='text'>Writing a Load Balance algorithm for WSO2 ESB</title><content type='html'>Load balance algorithms are very interesting. They need to be fast and efficient. Otherwise we will spend most of our time trying to find the next route rather than doing the actual message sending.&lt;br /&gt;
&lt;br /&gt;
Also load balancing algorithms involve lots of synchronization operations as well. So they should be coded with care.&lt;br /&gt;
&lt;br /&gt;
The load balance algorithm I was interested in should have the&amp;nbsp;benefits&amp;nbsp;of Round Robin, Weighted and Least connection based algorithms. So it is a combination of all those three algorithms.&lt;br /&gt;
&lt;br /&gt;
Round Robin is a pretty&amp;nbsp;powerful&amp;nbsp;algorithm mainly due to its&amp;nbsp;simplicity. One assumption it made is all the servers are identical and has the exact same capacity. But in practice this may not be the case always.&lt;br /&gt;
&lt;br /&gt;
Static Weighted algorithms assume machines have different capacities and based on those they are configured statically. Combined with round robin algorithms these can be&amp;nbsp;pretty&amp;nbsp;useful in some scenarios. But both these algorithms neglects the run-time&amp;nbsp;behavior&amp;nbsp;of servers.&lt;br /&gt;
&lt;br /&gt;
Some times due to various reasons these servers can get slow or un-responsive. If we don&#39;t take these situations in to account, a Load balancer can effectively kill some of the already slow servers. This happens because the load balancer pumps the messages at the same rate even if the server gets slow.&lt;br /&gt;
&lt;br /&gt;
Least connection can be used to some what overcome this problem. Least connection algorithms take the current number of connections in to account. More active connections than usual indicates a server saturation. At this point if the load balancer can reduce the number of messages send to this server, it can save the server from being killed.&lt;br /&gt;
&lt;br /&gt;
So my goal was to write an algorithm that take all these three factors. I wrote the algorithm but still couldn&#39;t do enough testing. Also there are improvements in core ESB as well as the algorithm for this to work.&lt;br /&gt;
&lt;br /&gt;
More on these later...</content><link rel='replies' type='application/atom+xml' href='http://supunk.blogspot.com/feeds/4613393278160892693/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/1197843169524706388/4613393278160892693' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/4613393278160892693'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/1197843169524706388/posts/default/4613393278160892693'/><link rel='alternate' type='text/html' href='http://supunk.blogspot.com/2010/02/writing-load-balance-algorithm-for-wso2.html' title='Writing a Load Balance algorithm for WSO2 ESB'/><author><name>Anonymous</name><uri>http://www.blogger.com/profile/14361364937700874215</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry></feed>