<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Ebeworld's Weblog &#187; Java</title>
	<atom:link href="http://ebeworld.wordpress.com/category/interview-questions/java/feed/" rel="self" type="application/rss+xml" />
	<link>http://ebeworld.wordpress.com</link>
	<description>Trying to create</description>
	<lastBuildDate>Wed, 09 Dec 2009 19:33:44 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<cloud domain='ebeworld.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://www.gravatar.com/blavatar/cbd4023a12f78275f1676e6f81eb8a20?s=96&#038;d=http://s.wordpress.com/i/buttonw-com.png</url>
		<title>Ebeworld's Weblog &#187; Java</title>
		<link>http://ebeworld.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://ebeworld.wordpress.com/osd.xml" title="Ebeworld&#8217;s Weblog" />
		<item>
		<title>Performance: C++ vs Java</title>
		<link>http://ebeworld.wordpress.com/2008/11/01/performance-c-vs-java/</link>
		<comments>http://ebeworld.wordpress.com/2008/11/01/performance-c-vs-java/#comments</comments>
		<pubDate>Sat, 01 Nov 2008 20:27:55 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=83</guid>
		<description><![CDATA[Java byte code runs after JVM optimize it, therefore in some cases, if user is doing the repetitive tasks again and again, Java code might be faster than C++ code.For example.
1. creating new object and deleting it for substantial times. In this case JVM use previously not yet garbage collected objects, such as 1st generation, [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=83&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Java byte code runs after JVM optimize it, therefore in some cases, if user is doing the repetitive tasks again and again, Java code might be faster than C++ code.For example.</p>
<p>1. creating new object and deleting it for substantial times. In this case JVM use previously not yet garbage collected objects, such as 1st generation, 2nd generation candidates.</p>
<p>2. Repetative function calling. <a href="http://kano.net/javabench/">http://kano.net/javabench/</a> has quite good examples.</p>
<p>3. Experienced C++/Java  programmers write codes for human readability. For example</p>
<p>Person* manager=new Person();</p>
<p>//..Do something with managerand finish</p>
<p>delete(manager);</p>
<p>Person* worker=new Manager();</p>
<p>//..Do something with worker and finish</p>
<p>delete(worker);</p>
<p>Here C++ would allocate 2wice. But JVM would walk though byte code and figure out there are in fact only one is needed and use it again. Because of readability C++/Java developers wouldn&#8217;t dare to use one object for worker and manager, but Java code with same readability would be optimized and might run faster than its C++ code.</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/83/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/83/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/83/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/83/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/83/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/83/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/83/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/83/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/83/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/83/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=83&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/11/01/performance-c-vs-java/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>Some questions</title>
		<link>http://ebeworld.wordpress.com/2008/10/19/some-questions/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/19/some-questions/#comments</comments>
		<pubDate>Sun, 19 Oct 2008 05:44:19 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=76</guid>
		<description><![CDATA[1. What is the iterative software development method?
2. What is agile software development method?
3. What is RUP? What are the its parts?
4. What is the TDD, test driven development method?
       <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=76&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>1. What is the iterative software development method?</p>
<p>2. What is agile software development method?</p>
<p>3. What is RUP? What are the its parts?</p>
<p>4. What is the TDD, test driven development method?</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/76/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=76&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/19/some-questions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>Load testing tools</title>
		<link>http://ebeworld.wordpress.com/2008/10/19/load-testing-tools/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/19/load-testing-tools/#comments</comments>
		<pubDate>Sun, 19 Oct 2008 03:41:03 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=73</guid>
		<description><![CDATA[Rational Robot, JMeter, LoadRunner are a few of them
       <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=73&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Rational Robot, JMeter, LoadRunner are a few of them</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/73/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/73/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/73/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=73&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/19/load-testing-tools/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>JSP life cycle</title>
		<link>http://ebeworld.wordpress.com/2008/10/15/jsp-life-cycle/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/15/jsp-life-cycle/#comments</comments>
		<pubDate>Wed, 15 Oct 2008 15:07:09 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=70</guid>
		<description><![CDATA[Explain the life cycle methods of a JSP?

Pre-translated:Before the JSP file has been translated and compiled into the Servlet.
Translated: The JSP file has been translated and compiled as a Servlet.
Initialized: Prior to handling the requests in the service method the container calls the jspInit() to initialize the Servlet. Called only once per Servlet instance.
Servicing: Services [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=70&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><div><span style="font-size:xx-small;font-family:Arial;"><span style="font-size:xx-small;font-family:Arial;">Explain the life cycle methods of a JSP?<br />
</span></span><span style="font-size:xx-small;font-family:Arial;"><span style="font-size:xx-small;font-family:Arial;"></p>
<div><strong><span style="font-size:xx-small;font-family:Arial,Bold;"><span style="font-size:xx-small;font-family:Arial,Bold;"><strong><span style="font-size:xx-small;font-family:Arial,Bold;"><span style="font-size:xx-small;font-family:Arial,Bold;">Pre-translated:</span></span></strong></span></span><strong><span style="font-size:x-small;font-family:Arial,Bold;"><span style="font-size:x-small;font-family:Arial,Bold;"><span style="font-size:xx-small;font-family:Arial;"><span style="font-size:xx-small;font-family:Arial;">Before the JSP file has been translated and compiled into the Servlet.<br />
</span></span><strong><span style="font-size:xx-small;font-family:Arial,Bold;"><span style="font-size:xx-small;font-family:Arial,Bold;">Translated: </span></span></strong><span style="font-size:xx-small;font-family:Arial;"><span style="font-size:xx-small;font-family:Arial;">The JSP file has been translated and compiled as a Servlet.<br />
</span></span><strong><span style="font-size:xx-small;font-family:Arial,Bold;"><span style="font-size:xx-small;font-family:Arial,Bold;">Initialized: </span></span></strong><span style="font-size:xx-small;font-family:Arial;"><span style="font-size:xx-small;font-family:Arial;">Prior to handling the requests in the service method the container calls the jspInit() to initialize the Servlet. Called only once per Servlet instance.<br />
</span></span><strong><span style="font-size:xx-small;font-family:Arial,Bold;"><span style="font-size:xx-small;font-family:Arial,Bold;">Servicing</span></span></strong><span style="font-size:xx-small;font-family:Arial;"><span style="font-size:xx-small;font-family:Arial;">: Services the client requests. Container calls this method for each request.<br />
</span></span><strong><span style="font-size:xx-small;font-family:Arial,Bold;"><span style="font-size:xx-small;font-family:Arial,Bold;">Out of service</span></span></strong><span style="font-size:xx-small;font-family:Arial;"><span style="font-size:xx-small;font-family:Arial;">: The Servlet instance is out of service. The container calls the jspDestroy() method.</span></span></span></span></strong></strong> </p>
<p> </p></div>
<p></span></span></div>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/70/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=70&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/15/jsp-life-cycle/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>Signed applet</title>
		<link>http://ebeworld.wordpress.com/2008/10/14/signed-applet/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/14/signed-applet/#comments</comments>
		<pubDate>Tue, 14 Oct 2008 15:06:38 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[signed applet]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=31</guid>
		<description><![CDATA[A signed applet can become a trusted applet, which can work outside the sandbox.
       <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=31&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>A signed applet can become a trusted applet, which can work outside the sandbox.</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/31/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/31/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/31/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=31&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/14/signed-applet/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>Very common questions</title>
		<link>http://ebeworld.wordpress.com/2008/10/14/very-common-questions/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/14/very-common-questions/#comments</comments>
		<pubDate>Tue, 14 Oct 2008 09:45:35 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=29</guid>
		<description><![CDATA[Tell me about yourself or about some of the recent projects you have worked with? What do you consider yourÂ most significant achievement? Why do you think you are qualified for this position? Why should we hire you andÂ what kind of contributions will you make?
Â 
ô€‚ƒ Design concepts and design patterns: How you understand [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=29&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Tell me about yourself or about some of the recent projects you have worked with? What do you consider yourÂ most significant achievement? Why do you think you are qualified for this position? Why should we hire you andÂ what kind of contributions will you make?</p>
<p>Â </p>
<p>ô€‚ƒ Design concepts and design patterns: How you understand and applied them.</p>
<p>ô€‚ƒ Performance and memory issues: How you identified and fixed them.</p>
<p>ô€‚ƒ Exception handling and best practices: How you understand and applied them.</p>
<p>ô€‚ƒ Multi-threading and concurrent access: How you identified and fixed them.</p>
<p>Â </p>
<p>Why are you leaving your current position?</p>
<p>ô€‚ƒ Do not criticize your previous employer or coworkers or sound too opportunistic.</p>
<p>ô€‚ƒ It is fine to mention a major problem like a buy out, budget constraints, merger or liquidation.</p>
<p>ô€‚ƒ You may also say that your chance to make a contribution is very low due to company wide changes orÂ looking for a more challenging senior or designer role.</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/29/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/29/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/29/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=29&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/14/very-common-questions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>memory leaks</title>
		<link>http://ebeworld.wordpress.com/2008/10/14/memory-leaks/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/14/memory-leaks/#comments</comments>
		<pubDate>Tue, 14 Oct 2008 09:33:09 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[java memory leaks]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=27</guid>
		<description><![CDATA[In Java, typically memory leak occurs when an object of a longer lifecycle has a reference to objects of a short life cycle.This prevents the objects with short life cycle being garbage collected. The developer must remember to remove the referencesÂ to the short-lived objects from the long-lived objects. Objects with the same life cycle [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=27&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>In Java, typically memory leak occurs when an object of a longer lifecycle has a reference to objects of a short life cycle.This prevents the objects with short life cycle being garbage collected. The developer must remember to remove the referencesÂ to the short-lived objects from the long-lived objects. Objects with the same life cycle do not cause any issues because theÂ garbage collector is smart enough to deal with the circular references</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/27/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/27/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/27/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/27/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/27/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/27/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/27/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/27/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/27/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/27/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=27&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/14/memory-leaks/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>How would you improve performance of a Java application?</title>
		<link>http://ebeworld.wordpress.com/2008/10/14/how-would-you-improve-performance-of-a-java-application/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/14/how-would-you-improve-performance-of-a-java-application/#comments</comments>
		<pubDate>Tue, 14 Oct 2008 09:09:41 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=25</guid>
		<description><![CDATA[Pool valuable system resources like threads, database connections, socket connections etc. Emphasise onÂ reuse of threads from a pool of threads. Creating new threads and discarding them after use can adverselyÂ affect performance. Also consider using multi-threading in your single-threaded applications where possible toÂ enhance performance. Optimze the pool sizes based on system and application [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=25&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Pool valuable system resources like threads, database connections, socket connections etc. Emphasise onÂ reuse of threads from a pool of threads. Creating new threads and discarding them after use can adverselyÂ affect performance. Also consider using multi-threading in your single-threaded applications where possible toÂ enhance performance. Optimze the pool sizes based on system and application specifications andÂ requirements.</p>
<p>ô€‚ƒ Optimize your I/O operations: use buffering (Refer Q21 in Java section) when writing to and reading fromÂ files and/or streams. Avoid writers/readers if you are dealing with only ASCII characters. You can use treamsÂ instead, which are faster. Avoid premature flushing of buffers. Also make use of the performance andÂ scalability enhancing features such as non-blocking and asynchronous I/O, mapping of file to memory etcÂ offered by the NIO (New I/O).</p>
<p>ô€‚ƒ Minimize network overheads by retrieving several related items simultaneously in one remote invocation ifÂ possible. Remote method invocations involve a network round-trip, marshalling and unmarshalling ofÂ parameters, which can cause huge performance problems if the remote interface is poorly designed.</p>
<p>ô€‚ƒ Establish whether you have a potential memory problem and manage your objects efficiently: removeÂ references to the short-lived objects from long-lived objects like Java collections etcÂ to minimise any potential memory leaks. Also reuse objects where possible. It is cheaper to recycleÂ objects than creating new objects each time. Avoid creating extra objects unnecessarily. For example useÂ mutable StringBuffer/StringBuilder classes instead of immutable String objects in computation expensiveÂ loops as discussed in Q17 in Java section. Automatic garbage collection is one of the most highly toutedÂ conveniences of Java. However, it comes at a price. Creating and destroying objects occupies a significantÂ chunk of the JVM&#8217;s time. Wherever possible, you should look for ways to minimise the number of objectsÂ created in your code:</p>
<p>ô€‚ƒ If repeating code within a loop, avoid creating new objects for each iteration. Create objects beforeÂ entering the loop (i.e. outside the loop) and reuse them if possible.Â </p>
<p>ô€‚ƒ For complex objects that are used frequently, consider creating a pool of recyclable objects rather thanÂ always instantiating new objects. This adds additional burden on the programmer to manage the pool,Â but in select cases can represent an order of magnitude performance gain.</p>
<p>ô€‚ƒ Use lazy initialization when you want to distribute the load of creating large amounts of objects. Use lazyÂ initialization only when there is merit in the design.</p>
<p>ô€‚ƒ Where applicable apply the following performance tips in your code:</p>
<p>ô€‚ƒ Use ArrayLists, HashMap etc as opposed to Vector, Hashtable etc where possible. This is because theÂ methods in ArrayList, HashMap etc are not synchronized (Refer Q13 in Java Section). Even better is toÂ use just arrays where possible.</p>
<p>ô€‚ƒ Set the initial capacity of a collection (e.g. ArrayList, HashMap etc) and StringBuffer/StringBuilderÂ appropriately. This is because these classes must grow periodically to accommodate new elements.</p>
<p>So, if you have a very large ArrayList or a StringBuffer, and you know the size in advance then you can</p>
<p>speed things up by setting the initial size appropriately. (Refer Q15, Q17 in Java Section).</p>
<p>Minimise the use of casting or runtime type checking like instanceof in frequently executed methods</p>
<p>or in loops. The “casting” and “instanceof” checks for a class marked as final will be faster. Using</p>
<p>“instanceof” construct is not only ugly but also unmaintainable. Look at using visitor pattern (Refer</p>
<p>Q11 in How would you go about…? section) to avoid “instanceof” construct.</p>
<p>ô€‚ƒ Do not compute constants inside a large loop. Compute them outside the loop. For applets compute it</p>
<p>in the init() method.</p>
<p>ô€‚ƒ Exception creation can be expensive because it has to create the full stack trace. The stack trace is</p>
<p>obviously useful if you are planning to log or display the exception to the user. But if you are using your</p>
<p>exception to just control the flow, which is not recommended, then throw an exception, which is precreated.</p>
<p>An efficient way to do this is to declare a public static final Exception in your exception class</p>
<p>itself.</p>
<p>ô€‚ƒ Avoid using System.out.println and use logging frameworks like Log4J etc, which uses I/O buffers</p>
<p>(Refer Q21 in Java section).</p>
<p>ô€‚ƒ Minimise calls to Date, Calendar, etc related classes.</p>
<p>ô€‚ƒ Minimise JNI calls in your code.</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/25/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=25&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/14/how-would-you-improve-performance-of-a-java-application/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>Benefit of using Swing over AWT</title>
		<link>http://ebeworld.wordpress.com/2008/10/14/benefit-of-using-swing-over-awt/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/14/benefit-of-using-swing-over-awt/#comments</comments>
		<pubDate>Tue, 14 Oct 2008 08:53:09 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[TopCoder]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Swing]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=23</guid>
		<description><![CDATA[What is the difference between AWT and Swing? LF DC
Â Swing provides a richer set of components than AWT. They are 100% Java-based. There are a few otherÂ advantages to Swing over AWT:
• Swing provides both additional components like JTable, JTree etc and added functionality to AWT-replacementÂ components.
• Swing components can change their appearance based [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=23&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>What is the difference between AWT and Swing? LF DC</p>
<p>Â Swing provides a richer set of components than AWT. They are 100% Java-based. There are a few otherÂ advantages to Swing over AWT:</p>
<p>• Swing provides both additional components like JTable, JTree etc and added functionality to AWT-replacementÂ components.</p>
<p>• Swing components can change their appearance based on the current “look and feel” library that’s being used.</p>
<p>• Swing components follow the Model-View-Controller (MVC) paradigm, and thus can provide a much more</p>
<p>flexible UI.</p>
<p>• Swing provides “extras” for components, such as: icons on many components, decorative borders for</p>
<p>components, tool tips for components etc.</p>
<p>• Swing components are lightweight (less resource intensive than AWT).</p>
<p>Swing provides built-in double buffering (which means an off-screen buffer [image] is used during drawing</p>
<p>and then the resulting bits are copied onto the screen. The resulting image is smoother, less flicker and quickerÂ than drawing directly on the screen).</p>
<p>• Swing provides paint debugging support for when you build your own component i.e.-slow motion rendering.</p>
<p>Swing also has a few disadvantages:</p>
<p>• If you’re not very careful when programming, it can be slower than AWT (all components are drawn).</p>
<p>• Swing components that look like native components might not behave exactly like native components.</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/23/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/23/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/23/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=23&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/14/benefit-of-using-swing-over-awt/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
		<item>
		<title>Swing Layouts</title>
		<link>http://ebeworld.wordpress.com/2008/10/14/swing-layouts/</link>
		<comments>http://ebeworld.wordpress.com/2008/10/14/swing-layouts/#comments</comments>
		<pubDate>Tue, 14 Oct 2008 08:49:08 +0000</pubDate>
		<dc:creator>ebeworld</dc:creator>
				<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[swing layouts]]></category>

		<guid isPermaLink="false">http://ebeworld.wordpress.com/?p=21</guid>
		<description><![CDATA[Explain layout managers?
Layout managers are used for arranging GUI components in windows. The standard layout managers are:
• FlowLayout: Default layout for Applet and Panel. Lays out components from left to right, starting new rows ifÂ necessary.
• BorderLayout: Default layout for Frame and Dialog. Lays out components in north, south, east, west and
center. All extra space [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=21&subd=ebeworld&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class='snap_preview'><br /><p>Explain layout managers?</p>
<p>Layout managers are used for arranging GUI components in windows. The standard layout managers are:</p>
<p>• FlowLayout: Default layout for Applet and Panel. Lays out components from left to right, starting new rows ifÂ necessary.</p>
<p>• BorderLayout: Default layout for Frame and Dialog. Lays out components in north, south, east, west and</p>
<p>center. All extra space is placed on the center.</p>
<p>• CardLayout: stack of same size components arranged inside each other. Only one is visible at any time. UsedÂ in TABs.</p>
<p>• GridLayout: Makes a bunch of components equal in size and displays them in the requested number of rows</p>
<p>and columns.</p>
<p>• GridBagLayout: Most complicated but the most flexible. It aligns components by placing them within a grid ofÂ cells, allowing some components to span more than one cell. The rows in the grid aren’t necessarily all theÂ same height, similarly, grid columns can have different widths as well.</p>
<p>BoxLayout: is a full-featured version of FlowLayout. It stacks the components on top of each other or places Â them in a row.</p>
  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/ebeworld.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/ebeworld.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/ebeworld.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/ebeworld.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/ebeworld.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/ebeworld.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/ebeworld.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/ebeworld.wordpress.com/21/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/ebeworld.wordpress.com/21/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/ebeworld.wordpress.com/21/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=ebeworld.wordpress.com&blog=5157598&post=21&subd=ebeworld&ref=&feed=1" /></div>]]></content:encoded>
			<wfw:commentRss>http://ebeworld.wordpress.com/2008/10/14/swing-layouts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/e5ebaca1d1c2b06cc18b8d977bb1c37d?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">ebeworld</media:title>
		</media:content>
	</item>
	</channel>
</rss>