我正在遵循这些练习来学习自由。
我在实验3-模块2.2自由和JPA (DB2)中遇到了问题。在设置了所有的JDBC和Data Source详细信息之后,我重新启动了服务器,但是没有看到提到dataSource和jdbd驱动程序的两行代码。
审计J2CA8004I :审计DB2Connection可以作为jdbc/DB2Connection使用。AUDIT J2CA8000I : jdbcDriver my JDBCDriver可用。
我如何知道jpa和jdb特性是否设置正确?
这是server.xml
<!-- Enable features -->
<featureManager onError="WARN">
<feature>jsp-2.2</feature>
<feature>jpa-2.0</feature>
<feature>jdbc-4.0</feature>
</featureManager>
<!-- To access this server from a remote client add a host attribute to the following element, e.g. host="*" -->
<httpEndpoint id="defaultHttpEndpoint"
httpPort="9080"
httpsPort="9443" />
<jdbcDriver id="myJDBCDriver">
<library name="DB2Lib">
<fileset dir="C:\wlp\db2jdbc" includes="db2jcc4.jar, db2jcc_license_cu.jar"></fileset>
</library>
</jdbcDriver>
<dataSource jndiName="jdbc/DB2Connection" id="DB2Connection"
jdbcDriverRef="myJDBCDriver">
<properties.db2.jcc databaseName="SAMPLE" serverName="igacloud" password="{xor}FhgeOz1tPj08" user="db2admin"></properties.db2.jcc>
</dataSource>
发布于 2015-10-21 04:16:52
与经典WebSphere不同的是,它在管理控制台(数据源面板)中具有“测试连接”功能,而WebSphere WebSphere还没有类似的方法。您是否尝试过使用简单的"Hello World“JPA应用程序测试连接?
CWWKF0012I消息只是确认启用了哪些功能-某些功能依赖于其他功能并自动启用,这就是为什么您会看到比server.xml中定义的功能更多的功能。
https://stackoverflow.com/questions/30130515
复制相似问题