学位論文要旨



No 128452
著者(漢字) ニーストロム ペルソン ヨーハン トマス
著者(英字)
著者(カナ) ニーストロム ペルソン ヨーハン トマス
標題(和) 進化可能なコンポーネント統合のためのJavaプログラミング言語拡張
標題(洋) EXTENDING THE JAVA PROGRAMMING LANGUAGE FOR EVOLVABLE COMPONENT INTEGRATION
報告番号 128452
報告番号 甲28452
学位授与日 2012.03.22
学位種別 課程博士
学位種類 博士(情報理工学)
学位記番号 博情第363号
研究科 情報理工学系研究科
専攻 コンピュータ科学専攻
論文審査委員 主査: 東京大学 教授 萩谷,昌己
 東京大学 教授 千葉,滋
 東京大学 准教授 増原,英彦
 東京大学 講師 蓮尾,一郎
 国立情報学研究所 教授 胡,振江
内容要旨 要旨を表示する

ABSTRACT

In the last few decades, software systems have become less and less atomic, andincreasingly built according to the component-based software development paradigm:applications and libraries are increasingly created by combining existing libraries, componentsand modules. Object-oriented programming languages have been especially importantin enabling this development through their essential feature of encapsulation:separation of interface and implementation. Another enabling technology has been theexplosive spread of the Internet, which facilitates simple and rapid acquisition of softwarecomponents. As a consequence, now, more than ever, different parts of software systemsare maintained and developed by different people and organisations, making integrationand reintegration of software components a very challenging problem in practice.One of the most popular and widespread object-oriented programming languagestoday is the Java language, which through features such as platform independence, dynamicclass loading, interfaces, absence of pointer arithmetic, and bytecode verification,has simplified component-based development greatly. However, we argue that Java encapsulation,in the form supported by its interfaces, has several shortcomings with respectto the need for integration. API clients depend on the concrete forms of interfaces, whichare collections of fields and methods that are identified by names and type signatures.But these interfaces do not capture essential information about how classes are to be used,such as usage protocols (sequential constraints), the meaning and results of invoking amethod, or useful ways for different classes to be used together. Such constraints must becommunicated as human-readable documentation, which means that the compiler cannotby itself perform tasks such as integrating components and checking the validity of anintegration following an upgrade. In addition, many trivial interface changes, such asthe ones that may be caused by common refactorings, do not lead to complex semanticchanges, but they may still lead to compilation errors, necessitating a tedious manualupgrade process. These problems stem from the fact that client components dependon exact syntactic forms of interfaces they are making use of. In short, Java interfacesand integration dependencies are too rigid and capture both insufficient and excessiveinformation with respect to the integration concern.We propose a Java extension, Poplar, which enriches interfaces with a semantic labelsystem, which describes functional properties of variables, as well as an effect system.This additional information enables us to describe integration requests declaratively usingintegration queries. Queries are satisfied by integration solutions, which are fragmentsof Java code. Such solutions can be found by a variety of search algorithms; we evaluatethe use of the well-known partial order planning algorithm with certain heuristics forthis purpose. A solution is guaranteed to have at least the useful effects requestedby the programmer, and no destructive effects that are not permitted. In this way,we generate integration links (solutions) from descriptions of intent, instead of makingprogrammers write integration code manually. When components are upgraded, theintegration links can be verified and accepted as still valid, or regenerated to conformto the new components, if possible. The design of Poplar is such that verification andreintegration can be carried out in a modular fashion. We argue that Poplar providesa sound must-analysis for the establishment of labels, and a sound may-analysis for thedeletion of labels. We provide a formalisation of Poplar, which is based on MiddleweightJava (MJ).We describe an implementation of a Poplar integration checker and generator,called Jardine, which compiles Poplar code to pure Java. We evaluate the practicalapplicability of Jardine through a case study, showing that significant flexibility in bothsyntactic and semantic evolution can be achieved.

論文要旨

この数十年来,ソフトウェアはそれ単独で作成されることは減っており、コンポーネントベース開発パラダイムに基づいて構築されることが増えている.つまり,アプリケーションやライブラリが,既存のライブラリやコンポーネントやモジュールを組み合せて作成されるのである。オブジェクト指向プログラミング言語は,このような開発方式を可能にするために特に重要な役割を果たしてきた.カプセル化,すなわちインターフェイスと実装を分離することをその本質的な機能として持っているからである.この他に,インターネットの爆発的成長により、ソフトウェアコンポーネントが簡単かつ迅速に入手できるようになったこともコンポーネントベース開発を促進させている。その結果現在では,かつてなかったほど,1 つのソフトウェアシステムの別々の箇所が,別々の人や組織によって開発・保守されるようになってきており,ソフトウェアコンポーネントの統合や再統合が現実的に非常に大きな問題となっている。

今日最も人気があり広く使用されるオブジェクト指向プログラミング言語の一つはJava言語である.その特徴である,プラットフォーム非依存性、動的なクラスの読み込み、インターフェイスの仕組み、ポインタ算術がないこと、そしてバイトコード検証などによって,コンポーネントベース開発は飛躍的に容易となった。しかしながら我々は,統合時において必要な機能という点から見て,Java のカプセル化方式がいくつかの短所があると考えている.それは,カプセル化方式がインターフェイスの仕組みによってサポートされていることに由来する.具体的に述べると,インターフェイスは名前を持つフィールドと,引数と返り値の型を指定されたメソッドによって構成されるのだが、クラスがどのように使用されるべきかという重要な情報を表現することができない.このような情報には,利用時のプロトコル(実行順序に関する制約),メソッド起動の意味や結果,複数のクラスを共に使う場合の使用法などが含まれる.これらの制約は,人間が読む文書として伝達されねばならず,従ってコンパイラが自分でコンポーネントを統合したり,アップグレードに伴う統合の妥当性をチェックしたりすることは不可能である.さらに,よくあるリファクタリングによって生じるような些細なインターフェイスの変更のなかには,複雑な意味論の変更を伴っていないにもかかわらず,コンパイルエラーを引き起こすものが多数あり,このような場合には退屈な手作業での修正が必要となる。これらの問題が生じる理由は,クライアントコンポーネントが,利用するインタフェースの正確な文法的な形式に依存していることにある.つまり、Java のインターフェイスと統合との関係は厳格でありすぎ、その結果統合時の関心事を表現する情報が不十分となったり過剰となったりするのである.

我々はPoplar というJava の拡張を提案する。Poplar では,意味論的なラベルシステムを導入することで,インタフェースをより機能豊富なものとしている.ラベルシステムにより,変数の機能的な性質とエフェクトシステムを記述することができる.この追加された情報によって、「統合クエリ」を利用して宣言的に統合の要求を表現することが可能となる。統合クエリは,さまざまな探索アルゴリズムによって解くことができるが,我々は,よく知られた半順序プラニングアルゴリズムに,この目的のためのあるヒューリスティックを導入したものを評価している.クエリに対する解は,プログラマの要求する有用な作用を持つことと,許可されていない有害な作用を持たないことが保証される.このようにして,プログラマに手作業で統合のためのコードを書かせるのではなく,意図の記述である統合クエリの解を求めることでコードを生成することができる.コンポーネントがアップグレードされたとき,統合のためのリンクは検証にかけることができ,依然として正しいものとして受け入れられるか,または,可能なら新しいコンポーネントに適合するように再作成される.Poplar は,検証と再統合がモジュラーに行われるように設計されている.

我々はPoplar がラベルの設置のため健全なmust-analysis と, ラベルの除去のための健全なmay-analysis を行う. Poplar の形式化をMiddleweight Java(MJ) に基いて行う. その実装として, 統合検査器及び生成器であるJardine について説明し, Poplar を用いて記述されたソフトウェアを純粋なJava プログラムへ変換することを示す. いくつかの事例研究により,Jardine の実際的な適用可能性を評価し, 構文と意味論の両面における柔軟性が実現できることを示す.__

審査要旨 要旨を表示する

本論文は、進化可能なコンポ―ネント統合を可能とするJavaの拡張を提案している。拡張はPoplarと呼ばれる。

本論文は7章から成り立っている。

第1章では、本論文の背景、本研究に至った動機、そして、本論文の貢献が述べられている。

第2章では、Poplarのデザインについて詳しく述べられている。Javaにおけるコンポーネント・ベースのプログラミングやリファクタリングについて述べられた後、Javaのコンポーネントの進化が分析されている。そして、ラベル付き変数に対するクエリをもとに、AIプラニングの技術を応用して、コンポーネントを統合する仕組みが導入されている。この仕組みにより、コンポーネントの進化の後にも、正しくコンポーネントを統合できることが示されている。

第3章では、Poplarの言語仕様が、非形式的ではあるが、詳細に述べられている。この章を読むことにより、実際にPoplarを利用することが可能になると考えられる。次の第4章では、第3章の言語仕様がMiddleweight Javaの拡張として形式化され、特に、型付けの規則が厳密に与えられている。

第5章では、Poplarコンパイラのデザインと実装について述べられている。Jardineと呼ばれる処理系は、クエリに対してAIプラニングを適用し、コンポーネントを統合することによって、Poplarのコードを純粋なJavaコードに変換する。

第6章ではPoplarの評価が与えられている。まず、JFreeChartと呼ばれるコンポーネント・ライブラリを用いた比較的巨大なアプリケーションがケーススタディとして述べられている。JFreeChartコンポーネントの統合はクエリによって行われ、JFreeChartをリファクタリングした後も、コンポーネントの統合が正しく行われることが示されている。次に、Fowlerのテキストに掲載されているリファクタリングの分類に基づき、各種のリファクタリングに対して、Poplarのアプローチが、有効かどうかが検証され、この結果に基づき、Poplarのアプリ―チの評価が与えられている。すなわち、Poplarは広範な種類のリファクタリングに対応可能であり、Poplarのもとでは、コンポーネントの進化を極めて容易に行うことができる。

第7章では、関連研究との比較とともに、本研究の総括が行われている。

結論として、本論文はソフトウェア・コンポーネントに対する新たなアプローチを提案し、その応用可能性をケーススタディによって示している。よって本論文は博士(情報理工学)の学位請求論文として合格と認められる。

UTokyo Repositoryリンク