[ Main Page ]

XML database

kokkenの仕事で、色々なnative XML server/libraryを使ったので、それらの特徴について記しておきます。 国立国語研究所で 作成された日本語話し言葉コーパス(CSJ)で構築されたXMLの構造は、深い上にデータ量も多いため、扱うライブラリがrobustな 作りになっていないと処理時間がかかるうえに作業中に落ちます。今回はXMLの検索として XQueryを使用したのですが、このXQueryを扱えるプログラムのうち、 自分が使っみてよかったと感じたものは、最初からあったTamino XML serverとeXistとQizx/Openです。

Tamino XML server

仕事についた時すでに使用が決まっていたものです。version4.1.4.1のLinux版はvesion3と違ってglibcのversionを 選び、RedHatLinux7.2のglibc環境以外ではまともに動かないという問題はありましたが、商用のdatabase serverである程度 安価なものの中では一番良く安定しており、tuningもそれなりに効いているものです。XPathでの検索のほうがずっと得意です。
Taminoを作っているSoftwareAGという会社はだいぶXMLに特化しているようです。最近、StarOffice(日本ではStarSuite)の ロゴsplashにPowered by Software AGとあることに気づきました。そういえば、StarOfficeの保存ファイルは、 XMLのzip圧縮ですね。

Screen Shot

eXist

今回はTaminoがあったので使う必要はなかったのですが、XQueryをサポートするdatabase serverとしてはよくできている ように感じました。

Qizx/Open

今回のツール作成では、Taminoサーバが存在しない状態でも検索ができるようにという条件があったので、XQueryを高速に実行できる Javaのライブラリが必要でした。W3Cのページにはライブラリ等が色々 載っていますが、preceding,preceding-sibling,following,following-sibling軸を扱えて高速なライブラリは今のところ これしかないようです。他のライブラリは軸のサポートが不完全なので、今回の仕事では使いませんでした。ただ、どちらかというと 学習用という位置づけです。

その他のライブラリ/サーバ

最近、NeoCore XML Management systemというのを雑誌で見かけたので、 ちょと試してみたのですが、Linux版はFedora Coreでないとinstallerすら動かないようです。仕方ないので、windows版を 試してみましたが、ちょっと軸のサポートが不親切なようです。
普通の使用では、XMLserverといってもRDBSと同じようなflatな検索しかかけないので、今回のような幾分特殊な用途に使う libraryやserverを選定するのはかなり大変でした。ただ、検索言語としてXQueryを選んだのがが正解だったかどうかには 疑問が残ります。

I only discovered this myself quite recently. When Yahoo bought Viaweb, they
asked me what I wanted to do. I had never liked the business side very much,
and said that I just wanted to hack. When I got to Yahoo, I found that what
hacking meant to them was implementing software, not designing it. Programmers
were seen as technicians who translated the visions (if that is the word) of
product managers into code.

This seems to be the default plan in big companies. They do it because it
decreases the standard deviation of the outcome. Only a small percentage of
hackers can actually design software, and it's hard for the people running a
company to pick these out. So instead of entrusting the future of the software
to one brilliant hacker, most companies set things up so that it is designed
by committee, and the hackers merely implement the design.

If you want to make money at some point, remember this, because this is one of
the reasons startups win. Big companies want to decrease the standard
deviation of design outcomes because they want to avoid disasters. But when
you damp oscillations, you lose the high points as well as the low. This is
not a problem for big companies, because they don't win by making great
products. Big companies win by sucking less than other big companies.

    -- Paul Graham
    -- Hackers and Painters ( http://www.paulgraham.com/hp.html )

> > On a slightly different note: my machine crashed the other day when
> > using it with kernel 2.6.0. Can anyone help?
> 
> I do not wish to tolerate any reports of problems when using  kernel
> 2.6.0, because I can't tell if it's a bug that was fixed by then, or
> if it's an actual issue with the kernel.

My Commodore 64 is suffering from slowness and insufficiency of memory;
and its display device is grievously short of pixels.  Can anyone help?	

	Shlomi Fish, Muli Ben Yehuda and Omer Zak on
	discussions@hamakor.org.il.

    -- Omer Zak
    -- Post to the Hamakor Discussions Mailing List ( http://mirror.hamakor.org.il/archives/discussions/05-2005/1497.html )


Powered by UNIX fortune(6)
[ Main Page ]