<?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/2.3.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>
<channel>
	<title>Comments on: Old News: Java Checked vs. Unchecked Exceptions</title>
	<link>http://blog.bumblemachine.com/archives/6</link>
	<description>Technical explorations through eternal distraction</description>
	<pubDate>Fri, 30 Jul 2010 10:34:06 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.3.1</generator>
		<item>
		<title>By: kriggio</title>
		<link>http://blog.bumblemachine.com/archives/6#comment-6</link>
		<dc:creator>kriggio</dc:creator>
		<pubDate>Thu, 31 May 2007 19:10:49 +0000</pubDate>
		<guid>http://blog.bumblemachine.com/archives/6#comment-6</guid>
		<description>In response to the link Josh provided, Closures != Checked Exceptions, nor are they a suitable substitute. Egads, this would be a disaster.</description>
		<content:encoded><![CDATA[<p>In response to the link Josh provided, Closures != Checked Exceptions, nor are they a suitable substitute. Egads, this would be a disaster.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Josh DeWald</title>
		<link>http://blog.bumblemachine.com/archives/6#comment-5</link>
		<dc:creator>Josh DeWald</dc:creator>
		<pubDate>Thu, 31 May 2007 16:56:12 +0000</pubDate>
		<guid>http://blog.bumblemachine.com/archives/6#comment-5</guid>
		<description>Thought you might find this of note:

http://weblogs.java.net/blog/editors/archives/2007/05/reflection.html</description>
		<content:encoded><![CDATA[<p>Thought you might find this of note:</p>
<p><a href="http://weblogs.java.net/blog/editors/archives/2007/05/reflection.html" rel="nofollow">http://weblogs.java.net/blog/editors/archives/2007/05/reflection.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: quellish</title>
		<link>http://blog.bumblemachine.com/archives/6#comment-4</link>
		<dc:creator>quellish</dc:creator>
		<pubDate>Sat, 26 May 2007 07:28:34 +0000</pubDate>
		<guid>http://blog.bumblemachine.com/archives/6#comment-4</guid>
		<description>Exceptions were a good idea!
On paper. In reality, they are probably the most misused part of the Java language I've seen, and the biggest failure of java as a programming culture. Exceptions didn't really work past the early revisions of java - as applications became more complex, error handling and exceptions became MUCH more complex. And no one really said "Hey, this wasn't the greatest idea in practice, we need to rethink this" and deprecate exceptions.
Nope.
Now we have layers on top of, or in parallel to, exceptions that largely make the problems worse.

In a real world app, you're often better off reinventing the wheel and rolling your own error event handling.

But hey, people also put objects in databases. *shakes head* .




Arent we as engineers supposed to be making things simpler, not more complex?</description>
		<content:encoded><![CDATA[<p>Exceptions were a good idea!<br />
On paper. In reality, they are probably the most misused part of the Java language I&#8217;ve seen, and the biggest failure of java as a programming culture. Exceptions didn&#8217;t really work past the early revisions of java - as applications became more complex, error handling and exceptions became MUCH more complex. And no one really said &#8220;Hey, this wasn&#8217;t the greatest idea in practice, we need to rethink this&#8221; and deprecate exceptions.<br />
Nope.<br />
Now we have layers on top of, or in parallel to, exceptions that largely make the problems worse.</p>
<p>In a real world app, you&#8217;re often better off reinventing the wheel and rolling your own error event handling.</p>
<p>But hey, people also put objects in databases. *shakes head* .</p>
<p>Arent we as engineers supposed to be making things simpler, not more complex?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Josh DeWald</title>
		<link>http://blog.bumblemachine.com/archives/6#comment-3</link>
		<dc:creator>Josh DeWald</dc:creator>
		<pubDate>Thu, 24 May 2007 10:25:27 +0000</pubDate>
		<guid>http://blog.bumblemachine.com/archives/6#comment-3</guid>
		<description>I think we're all just lazy in practice. I always intend to go back and "elegantly" handle the exception but my initial coding foray is always the "happy path" which leaves no room for exception handling. But then naturally the code gets deployed with a bunch of "printStackTrace()" messages (I *never* swallow and exception at least). It really gets bad if the method in question is a void, the caller has *no* idea that things failed. So at the *least* I will return false in those methods when I catch the exception. I think there are times when this is the correct response (if you're the end of the line, and the caller of you isn't expecting any exceptions, just true/false). But it's not when there's a complex chain of method calls and one of them selfishly takes the Exception and does nothing with it, providing no information to upstream callers.

So I guess my point is that I agree with you Ken, but as with many developers, I find myself not elegantly doing the error checking and processing for non-trivial callstacks (especially relevant for GUI code). And I can't claim to not have read a lot of articles similar to yours about the importance of them.</description>
		<content:encoded><![CDATA[<p>I think we&#8217;re all just lazy in practice. I always intend to go back and &#8220;elegantly&#8221; handle the exception but my initial coding foray is always the &#8220;happy path&#8221; which leaves no room for exception handling. But then naturally the code gets deployed with a bunch of &#8220;printStackTrace()&#8221; messages (I *never* swallow and exception at least). It really gets bad if the method in question is a void, the caller has *no* idea that things failed. So at the *least* I will return false in those methods when I catch the exception. I think there are times when this is the correct response (if you&#8217;re the end of the line, and the caller of you isn&#8217;t expecting any exceptions, just true/false). But it&#8217;s not when there&#8217;s a complex chain of method calls and one of them selfishly takes the Exception and does nothing with it, providing no information to upstream callers.</p>
<p>So I guess my point is that I agree with you Ken, but as with many developers, I find myself not elegantly doing the error checking and processing for non-trivial callstacks (especially relevant for GUI code). And I can&#8217;t claim to not have read a lot of articles similar to yours about the importance of them.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Repete</title>
		<link>http://blog.bumblemachine.com/archives/6#comment-2</link>
		<dc:creator>Repete</dc:creator>
		<pubDate>Thu, 24 May 2007 06:26:43 +0000</pubDate>
		<guid>http://blog.bumblemachine.com/archives/6#comment-2</guid>
		<description>I'd have to say checked exceptions, in practice, cause more problems than they are worth.  The "worst case scenario" you show there is precisely why I don't like checked exceptions.  That code is more common than it should be and sometimes results in quiet failures.  Also, another problem with that code is it will swallow runtime exceptions too, hence breaking the whole idea of runtime exceptions all because a developer is lazy.  Once again this is in practice so you can blame the developer there I'll give you that.  If Java must have checked exceptions I would suggest making a checked exception superclass so developers can still be lazy without "clobbering" the idea of runtime exceptions; but that is still a compromise.  I don't see harm in removing checked exceptions because RuntimeExceptions can still be handled so all we are really losing is the "... eloquently documented..." exceptions.  This documentation of exceptions causes a lot of extra code to be written and, in my experience, largely not handle the exception in any meaningful way other than directing a user to a "pretty failure" screen.</description>
		<content:encoded><![CDATA[<p>I&#8217;d have to say checked exceptions, in practice, cause more problems than they are worth.  The &#8220;worst case scenario&#8221; you show there is precisely why I don&#8217;t like checked exceptions.  That code is more common than it should be and sometimes results in quiet failures.  Also, another problem with that code is it will swallow runtime exceptions too, hence breaking the whole idea of runtime exceptions all because a developer is lazy.  Once again this is in practice so you can blame the developer there I&#8217;ll give you that.  If Java must have checked exceptions I would suggest making a checked exception superclass so developers can still be lazy without &#8220;clobbering&#8221; the idea of runtime exceptions; but that is still a compromise.  I don&#8217;t see harm in removing checked exceptions because RuntimeExceptions can still be handled so all we are really losing is the &#8220;&#8230; eloquently documented&#8230;&#8221; exceptions.  This documentation of exceptions causes a lot of extra code to be written and, in my experience, largely not handle the exception in any meaningful way other than directing a user to a &#8220;pretty failure&#8221; screen.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
