Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at ht
Stack Overflow for Teams is now called Stack Internal. Bring the best of human thought and AI automation together at your work. Try for free Learn more
新しい Java SE API リファレンスの入手先について 2012年3月25日 at 10:30 午後 3件のコメント 2012 年 03 月 25 日、sun.com のドメインが利用不可になりました。これに併せ、java.sun.com で提供されていた Java SE API 日本語ドキュメントもオンライン経由で参照する事ができなくなりました。今後、日本語の Java SE API レファレンスはオンライン経由では参照できなくなりますので、アーカイブを御入手の上、ローカル環境でご参照ください。お手数をお掛けし申し訳ございませんが、どうぞ宜しくお願いします。 Java API の日本語ドキュメントはコチラから入手が可能です。 ドキュメントの再配布ポリシーはコチラをご参照ください。 新しい日本語 API ドキュメントのオンライン参照先URL (2012/4/11 訂正、追記) htt
The process of establishing a connection from one host to another is quite complex and involves multiple packet exchanges between two endpoints, which can be quite time consuming. The overhead of connection handshaking can be significant, especially for small HTTP messages. One can achieve a much higher data throughput if open connections can be re-used to execute multiple requests. HTTP/1.1 state
YourKit Java Profiler features Award-winning Java profiler CPU and memory Java profiling has never been easier and smarter at the same time. YourKit has developed a revolutionary way to profile Java applications at both development and production stages, bringing unparalleled benefits to Java developers. Ready for your tasks Profile all types of Java applications and servers, on multiple platforms
http://kimoto.hatenablog.com/entry/2012/03/05/103052 を読んでたら Ruby の retry-handler が激しく便利そうなので Java で実装してみた。 ソース→ https://github.com/yoshiori/retry-handler どんなものか簡単に説明すると 特定の処理を実行したいんだけど、途中で何らかのエラーが発生した場合はリトライさせたい時に使えます。 具体的にはこんな感じで書くと、処理の途中でエラーが発生しても指定した回数はリトライしてくれます。 Proc.retry(3,new Runnable() { @Override public void run() { //なんか処理 } }); 特定のエラーの時だけリトライしたい時はそれも指定できます。 例えば IOException とそのサブクラスのエラー
OutOfMemoryErrorが発生してもスレッドを異空間に葬るだけでJava VMはそのまま動き続ける場合があるけど、当然ながら状態に一貫性のない状態で動いている可能性があるわけで基本的にはとっとと死んで欲しいわけである。一般的に言うところの「不定」状態。OOMEはErrorであってふつうの例外ではなく、致命的なJava VMエラーを示すものである。OOME発生後にプロセス再起動しないでそのままどうこうしようというのは絶対に避けた方が良い。 例えばJDBCのコネクションオープンしてDBからデータを読み込んでるときにOOMEが起きた場合、JDBCコネクションは大抵オープンしっぱなしで回収はされなかったりする。OOMEではfinallyブロックが呼ばれる保証はない。JDBCコネクションリークくらいならまだ良い方だが、これは全てに当てはまる。A-B-Cといったセットになっている処理は例外など
みなさん、はじめまして。 Amebaの基盤改善チームでアプリケーションエンジニアをしている森です。 仕事ではAmebaの会員登録システムを担当しています。 唐突ですが、今回このブログではJSR-303 Bean Validationについて導入方法を解説します。 このテーマを選んだ理由はSeasar(SAStruts)のようなアノテーションで行うバリデーションがSpring MVCで出来ないかなぁと思った事です。幸いSpring3.0からJSR-303 Bean Validationが標準サポートされた事でアノテーションの利用が簡単になりました。以下に詳しく見ていきます。 (JSR-303 Bean Validationの概要) ●JSR-303 Bean Validationの目的 Java仕様を策定しているJCP(Java Community Process)が、JavaBeanオブジ
Ctrl+Cで落とした時に「後始末」な処理(ファイルを閉じるとか,DBにロールバックをかけるとか)をしてから終了させたいとか思ったときの話. 方法は2通りで,ひとつはVMのシャットダウンにフックをかける方法,もうひとつはSIGINTを捕まえるという方法. ちなみに推奨されるのは前者(というか後者が推奨されない.理由は後述). まずは一つ目から.以下の様にして,シャットダウン時に走るスレッドを用意してRuntimeに渡す. public class ShutdownHookTest { public static void main(String[] args) { ShutdownHookTest main = new ShutdownHookTest(); main.exec(); } void exec() { Runtime.getRuntime().addShutdownHook(
Post author:Leo Gaggl Post published:October 18, 2011 Post category:documentation / work Post comments:38 Comments UPDATE: To install on 12.04 (Precise Pangolin) you need a different PPA. Since sun-java6-jdk has been removed from the default Ubuntu 11.10 (Oneiric Ocelot) repositories you need to add a PPA repository (unless you want to install by hand) sudo add-apt-repository ppa:ferramroberto/jav
Apache Ivyについては本ブログでも何回か用語自体は取り上げてきましたが、現状日本語での情報が限られるためか、AntそのものやMavenに比べるとユーザーが少ないように思われます。ここで基本的な使い方やMavenとの違いについて簡単に紹介させていただきたいと思います。 Apache Ivyとは 本家のホームページは以下の通りです。 Home | Apache Ivy ™ もともとはJayasoftという組織で開発されていたツールですが、バージョン2.0以降、Antの関連プロジェクトとしてApacheプロジェクトの元に加わっています。(Apacheというブランド名はツールを組織に導入する際に結構重要ですね。) 上記のホームページでは「アジャイルな依存性管理ツール」として紹介されていますが、Mavenの機能の中からビルド機能やプロジェクト管理機能を無くして、ライブラリーの依存関係の管理に
自分のローカルにあるjp.programmersパッケージになっているサンプルコードとかのプロジェクトをcom.redhat.jbossパッケージとかにリネームしてお客様に渡したいなー、というケースがあったのでシェルスクリプト書いた。 #!/bin/sh # Usage: ./repackage.sh org.example com.example.foo FROM_PACKAGE=$1 TO_PACKAGE=$2 find . -type f -not -name '.*' | xargs perl -i~ -pe "s/\Q$1/$2/g" FROM_PACKAGE_DIR=`echo $FROM_PACKAGE | tr . /` TO_PACKAGE_DIR=`echo $TO_PACKAGE | tr . /` mkdir -p src/main/java/$TO_PACKAGE
HawtDispatch: The libdispatch style API for Java and ScalaHawtDispatch is a small ( less than 100k ) thread pooling and NIO handling framework API modeled after the libdispatch API that Apple created to power the Grand Central Dispatch (GCD) technology in OS X. It allows you to more easily develop multi-threaded applications which can more easily scale to take advantage of all the processing cores
For over 30 years, Java has evolved as a secure, enterprise-grade platform powering innovation. Oracle’s stewardship continues to advance Java as the language of choice to address modern application development and the future of AI-powered business. Watch the JavaOne 2026 keynotes and select sessions
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く