H2数据库
H2项目依赖
编译依赖
<!-- START COMPILE DEPENDENCIES !-->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>${servlet.version}</version>
</dependency>
<dependency>
<groupId>org.apache.lucene</groupId>
<artifactId>lucene-core</artifactId>
<version>${lucene.version}</version>
</dependency>
<dependency>
<groupId>org.apache.lucene</groupId>
<artifactId>lucene-analyzers-common</artifactId>
<version>${lucene.version}</version>
</dependency>
<dependency>
<groupId>org.apache.lucene</groupId>
<artifactId>lucene-queryparser</artifactId>
<version>${lucene.version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${slf4j.version}</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.core</artifactId>
<version>${osgi.version}</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.enterprise</artifactId>
<version>${osgi.version}</version>
</dependency>
<dependency>
<groupId>org.locationtech.jts</groupId>
<artifactId>jts-core</artifactId>
<version>${jts.version}</version>
</dependency>
<!-- END COMPILE DEPENDENCIES !-->
lucene主要在org.h2.fulltext.FullTextLucene类中。
javax.servlet主要被org.h2.server.web.DBStarter和同包下的WebServlet所引用,主要用于在tcp模式启动数据库以及通过console访问管理数据库
osgi主要被DbDriverActivator和OsgiDataSourceFactory所依赖。
DbDriverActivator实现了Osgi的BundleActivator接口,实现了start和stop方法,定义了启动和停止本bundle要做的事情。
OsgiDataSourceFactory实现了DataSourceFactory接口。实现包括创建dataSource等。