Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
H
h2database
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
Administrator
h2database
Commits
69574cee
提交
69574cee
authored
1月 30, 2016
作者:
Mat Booth
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Move to latest version of lucene 3 and fix usages of deprecated
APIs.
上级
55e9b945
显示空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
28 行增加
和
29 行删除
+28
-29
MANIFEST.MF
h2/src/main/META-INF/MANIFEST.MF
+8
-8
FullTextLucene.java
h2/src/main/org/h2/fulltext/FullTextLucene.java
+9
-10
Build.java
h2/src/tools/org/h2/build/Build.java
+11
-11
没有找到文件。
h2/src/main/META-INF/MANIFEST.MF
浏览文件 @
69574cee
...
...
@@ -23,14 +23,14 @@ Import-Package: javax.management,
javax.sql,
javax.tools;resolution:=optional,
javax.transaction.xa;resolution:=optional,
org.apache.lucene.analysis;version="[3.
0.0,3.1
.0)";resolution:=optional,
org.apache.lucene.analysis.standard;version="[3.
0.0,3.1
.0)";resolution:=optional,
org.apache.lucene.document;version="[3.
0.0,3.1
.0)";resolution:=optional,
org.apache.lucene.index;version="[3.
0.0,3.1
.0)";resolution:=optional,
org.apache.lucene.queryParser;version="[3.
0.0,3.1
.0)";resolution:=optional,
org.apache.lucene.search;version="[3.
0.0,3.1
.0)";resolution:=optional,
org.apache.lucene.store;version="[3.
0.0,3.1
.0)";resolution:=optional,
org.apache.lucene.util;version="[3.
0.0,3.1
.0)";resolution:=optional,
org.apache.lucene.analysis;version="[3.
6.2,4.0
.0)";resolution:=optional,
org.apache.lucene.analysis.standard;version="[3.
6.2,4.0
.0)";resolution:=optional,
org.apache.lucene.document;version="[3.
6.2,4.0
.0)";resolution:=optional,
org.apache.lucene.index;version="[3.
6.2,4.0
.0)";resolution:=optional,
org.apache.lucene.queryParser;version="[3.
6.2,4.0
.0)";resolution:=optional,
org.apache.lucene.search;version="[3.
6.2,4.0
.0)";resolution:=optional,
org.apache.lucene.store;version="[3.
6.2,4.0
.0)";resolution:=optional,
org.apache.lucene.util;version="[3.
6.2,4.0
.0)";resolution:=optional,
com.vividsolutions.jts.geom;version="1.14.0";resolution:=optional,
com.vividsolutions.jts.io;version="1.14.0";resolution:=optional,
org.h2;version="[${version},1.5.0)",
...
...
h2/src/main/org/h2/fulltext/FullTextLucene.java
浏览文件 @
69574cee
...
...
@@ -20,11 +20,11 @@ import org.apache.lucene.document.DateTools;
import
org.apache.lucene.document.Document
;
import
org.apache.lucene.document.Field
;
import
org.apache.lucene.index.IndexReader
;
import
org.apache.lucene.index.IndexWriterConfig
;
import
org.apache.lucene.index.Term
;
import
org.apache.lucene.queryParser.QueryParser
;
import
org.apache.lucene.search.IndexSearcher
;
import
org.apache.lucene.search.Query
;
import
org.apache.lucene.search.Searcher
;
import
org.h2.api.Trigger
;
import
org.h2.command.Parser
;
import
org.h2.engine.Session
;
...
...
@@ -304,12 +304,12 @@ public class FullTextLucene extends FullText {
try
{
Directory
indexDir
=
path
.
startsWith
(
IN_MEMORY_PREFIX
)
?
new
RAMDirectory
()
:
FSDirectory
.
open
(
new
File
(
path
));
boolean
recreate
=
!
IndexReader
.
indexExists
(
indexDir
);
Analyzer
analyzer
=
new
StandardAnalyzer
(
Version
.
LUCENE_30
);
IndexWriter
writer
=
new
IndexWriter
(
indexDir
,
analyzer
,
recreate
,
IndexWriter
.
MaxFieldLength
.
UNLIMITED
);
IndexWriterConfig
conf
=
new
IndexWriterConfig
(
Version
.
LUCENE_30
,
analyzer
);
conf
.
setOpenMode
(
IndexWriterConfig
.
OpenMode
.
CREATE_OR_APPEND
);
IndexWriter
writer
=
new
IndexWriter
(
indexDir
,
conf
);
//see http://wiki.apache.org/lucene-java/NearRealtimeSearch
IndexReader
reader
=
writer
.
getReader
(
);
IndexReader
reader
=
IndexReader
.
open
(
writer
,
true
);
access
=
new
IndexAccess
();
access
.
writer
=
writer
;
access
.
reader
=
reader
;
...
...
@@ -426,7 +426,7 @@ public class FullTextLucene extends FullText {
try
{
IndexAccess
access
=
getIndexAccess
(
conn
);
// take a reference as the searcher may change
Searcher
searcher
=
access
.
searcher
;
Index
Searcher
searcher
=
access
.
searcher
;
// reuse the same analyzer; it's thread-safe;
// also allows subclasses to control the analyzer used.
Analyzer
analyzer
=
access
.
writer
.
getAnalyzer
();
...
...
@@ -606,9 +606,8 @@ public class FullTextLucene extends FullText {
// recreate Searcher with the IndexWriter's reader.
indexAccess
.
searcher
.
close
();
indexAccess
.
reader
.
close
();
IndexReader
reader
=
indexAccess
.
writer
.
getReader
();
indexAccess
.
reader
=
reader
;
indexAccess
.
searcher
=
new
IndexSearcher
(
reader
);
indexAccess
.
reader
=
IndexReader
.
open
(
indexAccess
.
writer
,
true
);
indexAccess
.
searcher
=
new
IndexSearcher
(
indexAccess
.
reader
);
}
catch
(
IOException
e
)
{
throw
convertException
(
e
);
}
...
...
@@ -715,7 +714,7 @@ public class FullTextLucene extends FullText {
/**
* The index searcher.
*/
Searcher
searcher
;
Index
Searcher
searcher
;
}
}
h2/src/tools/org/h2/build/Build.java
浏览文件 @
69574cee
...
...
@@ -121,7 +121,7 @@ public class Build extends BuildBase {
File
.
pathSeparator
+
"ext/emma-2.0.5312.jar"
+
File
.
pathSeparator
+
"ext/postgresql-8.3-603.jdbc3.jar"
+
File
.
pathSeparator
+
"ext/servlet-api-3.0.1.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
0
.2.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
6
.2.jar"
+
File
.
pathSeparator
+
"ext/h2mig_pagestore_addon.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.core-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.enterprise-4.2.0.jar"
+
...
...
@@ -199,7 +199,7 @@ public class Build extends BuildBase {
download
();
String
classpath
=
"temp"
+
File
.
pathSeparator
+
"ext/servlet-api-3.0.1.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
0
.2.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
6
.2.jar"
+
File
.
pathSeparator
+
"ext/slf4j-api-1.6.0.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.core-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.enterprise-4.2.0.jar"
+
...
...
@@ -290,9 +290,9 @@ public class Build extends BuildBase {
downloadOrVerify
(
"ext/servlet-api-3.0.1.jar"
,
"javax/servlet"
,
"javax.servlet-api"
,
"3.0.1"
,
"6bf0ebb7efd993e222fc1112377b5e92a13b38dd"
,
offline
);
downloadOrVerify
(
"ext/lucene-core-3.
0
.2.jar"
,
"org/apache/lucene"
,
"lucene-core"
,
"3.
0
.2"
,
"
c2b48995ab855c1b9ea13867a0f976c994e0105d
"
,
offline
);
downloadOrVerify
(
"ext/lucene-core-3.
6
.2.jar"
,
"org/apache/lucene"
,
"lucene-core"
,
"3.
6
.2"
,
"
9ec77e2507f9cc01756964c71d91efd8154a8c47
"
,
offline
);
downloadOrVerify
(
"ext/slf4j-api-1.6.0.jar"
,
"org/slf4j"
,
"slf4j-api"
,
"1.6.0"
,
"b353147a7d51fcfcd818d8aa6784839783db0915"
,
offline
);
...
...
@@ -575,7 +575,7 @@ public class Build extends BuildBase {
javadoc
(
"-sourcepath"
,
"src/main"
,
"org.h2.jdbc"
,
"org.h2.jdbcx"
,
"org.h2.tools"
,
"org.h2.api"
,
"org.h2.engine"
,
"org.h2.fulltext"
,
"-classpath"
,
"ext/lucene-core-3.
0
.2.jar"
+
"ext/lucene-core-3.
6
.2.jar"
+
File
.
pathSeparator
+
"ext/jts-core-1.14.0.jar"
,
"-docletpath"
,
"bin"
+
File
.
pathSeparator
+
"temp"
,
"-doclet"
,
"org.h2.build.doclet.Doclet"
);
...
...
@@ -598,7 +598,7 @@ public class Build extends BuildBase {
"/../lib/tools.jar"
+
File
.
pathSeparator
+
"ext/slf4j-api-1.6.0.jar"
+
File
.
pathSeparator
+
"ext/servlet-api-3.0.1.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
0
.2.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
6
.2.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.core-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.enterprise-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/jts-core-1.14.0.jar"
,
...
...
@@ -614,7 +614,7 @@ public class Build extends BuildBase {
"/../lib/tools.jar"
+
File
.
pathSeparator
+
"ext/slf4j-api-1.6.0.jar"
+
File
.
pathSeparator
+
"ext/servlet-api-3.0.1.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
0
.2.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
6
.2.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.core-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.enterprise-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/jts-core-1.14.0.jar"
,
...
...
@@ -630,7 +630,7 @@ public class Build extends BuildBase {
System
.
getProperty
(
"java.home"
)
+
"/../lib/tools.jar"
+
File
.
pathSeparator
+
"ext/slf4j-api-1.6.0.jar"
+
File
.
pathSeparator
+
"ext/servlet-api-3.0.1.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
0
.2.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
6
.2.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.core-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.enterprise-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/jts-core-1.14.0.jar"
,
...
...
@@ -846,7 +846,7 @@ public class Build extends BuildBase {
java
(
"org.h2.build.doc.GenerateHelp"
,
null
);
javadoc
(
"-sourcepath"
,
"src/main"
,
"org.h2.tools"
,
"org.h2.jmx"
,
"-classpath"
,
"ext/lucene-core-3.
0
.2.jar"
+
"ext/lucene-core-3.
6
.2.jar"
+
File
.
pathSeparator
+
"ext/jts-core-1.14.0.jar"
,
"-docletpath"
,
"bin"
+
File
.
pathSeparator
+
"temp"
,
"-doclet"
,
"org.h2.build.doclet.ResourceDoclet"
);
...
...
@@ -893,7 +893,7 @@ public class Build extends BuildBase {
String
cp
=
"temp"
+
File
.
pathSeparator
+
"bin"
+
File
.
pathSeparator
+
"ext/postgresql-8.3-603.jdbc3.jar"
+
File
.
pathSeparator
+
"ext/servlet-api-3.0.1.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
0
.2.jar"
+
File
.
pathSeparator
+
"ext/lucene-core-3.
6
.2.jar"
+
File
.
pathSeparator
+
"ext/h2mig_pagestore_addon.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.core-4.2.0.jar"
+
File
.
pathSeparator
+
"ext/org.osgi.enterprise-4.2.0.jar"
+
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论