例子要运行起来,需要修改一些pom.xml内容:
2:spring版本需要修改,修改之处在properties下:
1:JBoss的仓库地址已经失效,需要注释掉,如下方式
<!--repository>
<id>JBoss repository</id>
<url>http://repository.jboss.com/maven2</url>
</repository-->
2:spring版本需要修改,修改之处在properties下:
<properties>
<spring.version>3.0.6.RELEASE</spring.version>
......
</properties>
3:添加slf4j的依赖,参考http://forum.springsource.org/showthread.php?90682-iBatis-JPetStore-sample-does-not-work
首先修改properties,添加slf4j版本
<properties>
......
<org.slf4j-version>1.5.10</org.slf4j-version>
</properties>
然后修改dependencies,添加依赖
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${org.slf4j-version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
<version>${org.slf4j-version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>${org.slf4j-version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.16</version>
<scope>runtime</scope>
</dependency>
4:启动hsqldb,readme.txt里边讲了怎么启动,不启动的话会报错