开发者

Is the Lucene 2.9 TokenStream API faster than the old one?

I have been looking at upgrading from 2.4 to 2.9 and noticed all the contrived code that handles attributes. Just wondering if anyone has any opinions if this will change given its a .9 and things will change when 3.0 is out.

I am confused how creating att开发者_JAVA技巧ributes by reflection and stashing attributes in a map can be as performant as just having the fields for each of the attribute types.

Is it worth upgrading today to 2.9 or just wait for 3.0 when things are finalized. For me its not essential to upgrade today.


"When things are finalized" isn't really an accurate summary of Lucene 3.0 vs 2.9. The 2.9 release contains all the same updates and API changes as 3.0.

All the new features were added to 2.4, the release was numbered 2.9 (to make it clear that it was a 'special' release), and 3.0 just comes along and removes two of the things which were 'holding things back': namely, it will remove all the deprecated methods and classes (many of which have been hanging around for a LONG time), and the requirement for Java 1.4 compatibility will be dropped (so Java 1.5-level classes, generics, etc will be introduced as appropriate).

Basically, rather than doing a huge leap in both API breakage and features in a single release (meaning people who wanted the features had to change all their old deprecated calls), the features were added first, so people can take advantage of the changes, and then concentrate on removing the use of the deprecated APIs, knowing that 3.0 will basically be a drop-in replacement -- just cleaned up, with no new real features.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜