<?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/"
	>

<channel>
	<title>Olen Onnellinen 2 &#187; JSP</title>
	<atom:link href="http://blog.magellanic.net/archives/tag/jsp/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.magellanic.net</link>
	<description>さまようITエンジニアの日記です。システム開発から資格試験、ゲーム、ライトノベルまで何でもありの雑記。</description>
	<lastBuildDate>Thu, 05 Jan 2012 04:29:22 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>いまさらJSPではまる</title>
		<link>http://blog.magellanic.net/archives/139</link>
		<comments>http://blog.magellanic.net/archives/139#comments</comments>
		<pubDate>Sat, 22 Nov 2008 13:14:38 +0000</pubDate>
		<dc:creator>koshian</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[JSP]]></category>

		<guid isPermaLink="false">http://blog.magellanic.net/?p=139</guid>
		<description><![CDATA[こんばんは、こしあんです。 久しぶりにJSPのコードを書きました。 で、軽くはまりました。 成長していないどころか、退化してます。 JSPが例外をthrowした場合、そのJSPのpageディレクティブのerrorPage [...]]]></description>
			<content:encoded><![CDATA[				<p>こんばんは、こしあんです。</p>
				<p>久しぶりにJSPのコードを書きました。<br />
				で、軽くはまりました。</p>
				<p>成長していないどころか、退化してます。</p>
				<p>JSPが例外をthrowした場合、そのJSPのpageディレクティブのerrorPage属性で指定したページに飛ばされます。<br />
				そしてその送信されたページ（pageディレクティブのisErrorPage属性をtrueにする）では暗黙オブジェクトの&#8221;exception&#8221;が使えます。<br />
				なので、このページではexceptionのトレースをログにでも出力して、画面にはごめんなさい表示をするのが妥当な処理かと思います。</p>
				<p>どこにはまったのかというと、エラーページJSPでexceptionの処理をしていないため、エラーの原因がわからなかったのです。<br />
				元のJSPのcatch(Exception e)ブロックにも引っかかっておらず、？？？となりました。</p>
				<p>もうお気づきの方もいるかと思いますが、Errorが投げられていたのでした。<br />
				やっぱり、Errorはcatchすべきではないし、エラーページの暗黙オブジェクト&#8221;exception&#8221;はThrowableなのでエラーページでロギングなのかなー。</p>
				<p>おっと、Errorの原因だったOutOfMemoryですが、VMに-Xmx256mとでもすれば回避できます。Eclipseのプロセスじゃなくて、Tomcatのプロセスにね！</p>
				<p>【参考】<br />
				<a href='http://d.hatena.ne.jp/nikkei225f/20080325'>TIPS &#8211; Struts 2+Spring 2+Tiles+Acegi+iBatis+GWT+JUnit 4+JMockit でフルスタックJAVAフレームワーク</a><br />
				<a href='http://www.atmarkit.co.jp/fjava/rensai/jsp2_04/jsp2_04_1.html'>連載：作りながら理解する「JSPコーディング・テクニック」第4回</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.magellanic.net/archives/139/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

