今日のソフトウエア開発において,Javaは最も重要なプログラミング言語あるいは開発環境といってもいいでしょう。そこで,ITproではJavaの最新技術についての連載を掲載しています。著者はJavaプログラマ向け情報ページ「Java in the Box」で有名な櫻庭祐一氏です。
参照: http://stackoverflow.com/questions/2348399/why-does-java-net-urls-hashcode-resolve-the-host-to-an-ip 公式ドキュメントによると: public boolean equals(Object obj) … 2 つの URL オブジェクトが等しいのは、同じプロトコルを持ち、同じホストを参照し、ホスト上のポート番号が同じで、ファイルとファイルのフラグメントが同じ場合です。 2 つのホストが等価と見なされるのは、両方のホスト名が同じ IP アドレスに解決されるか、どちらかのホスト名を解決できない場合は、大文字小文字に関係なくホスト名が等しいか、両方のホスト名が null に等しい場合です。 ホスト比較には名前解決が必要なので、この操作はブロック操作です。 java.net.URL#equals
Javaトラブルでは『情報がなくて、再現もなかなかしません』といった状況に陥ることがある。このような状況を回避するために、以下の3つの代表的なトラブルを例に、アプリケーションサーバを再起動する前に何を取得すれば良いのかをまとめてみる。 アプリケーションから応答がない アプリケーションが遅い ヒープメモリが足りない(OutOfMemoryErrorの発生) アプリケーションから応答がない 取得する情報 スレッドダンプ データ取得方法 スレッドダンプとは、コマンド実行時点でのJavaスレッド実行状態を出力したものである。応答がない場合、何らかの要因によりどこかで処理が止まっていることが想定される。スレッドダンプは『どこで止まっているのか?』を切り分けるのに大切な情報である。 取得方法はJDKのバージョンによって色々ある。 kill -3 <pid> (少なくとも1.4.2にはある〜JDK7でも
Thanks to Spring’s new MVC Annotations (@Controller, @RequestMapping, @RequestParam etc.) unit testing a Spring controller is now easier than ever before. Still, I had a hard time figuring out how to do this since most of your controller methods will not take a ServletRequest as input. Instead they use a form-backing / command object, a BindingResult and maybe a ModelMap. In a web environment Spri
わんくまでは珍しいJavaを中心とした日記です 目次 ホーム 連絡をする RSS Login Blog 利用状況 投稿数 - 218 記事 - 0 コメント - 14580 トラックバック - 28 書庫 2008年7月 (1) 2008年2月 (2) 2008年1月 (10) 2007年12月 (9) 2007年11月 (5) 2007年10月 (27) 2007年9月 (25) 2007年8月 (27) 2007年7月 (29) 2007年6月 (15) 2007年5月 (23) 2007年4月 (37) 2007年3月 (8) 日記カテゴリ Java (rss) JavaScript (rss) SQL (rss) WEB (rss) その他 (rss) いろいろリンク The Herringroe Projects(Javaで色々) わんくまトップ 古い方のブログ Spring/S
The page you are trying to reach does not exist, or has been moved. Please use the menus or the search box to find what you are looking for.
この記事は、http://d.hatena.ne.jp/higayasuo/20090612/1244772658 の「Ctrl+1とCtrl+Spaceうんぬん」の話にインスパイアされて書いた。Eclipse可愛いよ。Eclipse。 記事長いから、さくっと読み飛ばして、アニメーションgifがあるところから読んでも十分訳にたつと思う。 あと、新人さんとかに写経させるのもいいかも。というか、半分ぐらいうちの新人に勉強のためと思って書いたから。で、実際に写経させて役にたった。 Java は Eclipse などの IDE も含めて言語というか、環境というか…だと僕は思ってる。Commons, Maven なども含めたい(まぁ、そのあたりは、CPANも含めてperlだろ。とか、これは否定する人だらけだろうけど、Rails=rubyということを言う人もいるよね)。 少なくとも僕は、Eclipse
Tweet getRequestDispatcher foward Strutsをはじめ、上記のようにリクエストのフォワーディングをおこなうことは少なくないのではないでしょうか?URLReWriteのような形で特定のURLパターンにマッチした場合にアドレスを変換したり、*.html のアドレスでアクセスされた場合に内部的には、*.jsp や、*.do などの動的な処理に転送したい場合などが考えられる。 また、サイトにアクセス制御がかけられている場合は、認証されていない場合にログイン画面に転送するなどにも利用される。 Struts2での問題 ここで今まで利用してきた Struts1では、上記のような処理を、通常、web.xml で設定された、フィルターの機能を利用しておこなっていた方も多いのでしょうか?これは非常に簡単なコーディングにてリクエストの転送を問題なくおこなえていました。 web.
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く