<target name="createpool">
<wlconfig username="${username}" password="${password}" url="${adminURL}">
<query domain="${domainName}" type="Server" name="${targetserver}" property="x" />
<create type="JDBCConnectionPool" name="${JDBCConnectionPool.name}" >
<set attribute="CapacityIncrement" value="1"/>
<set attribute="DriverName" value="${database.driver}"/>
<set attribute="InitialCapacity" value="0"/>
<set attribute="MaxCapacity" value="10"/>
<set attribute="Password" value="${database.password}"/>
<set attribute="Properties" value="user=${database.user}"/>
<set attribute="RefreshMinutes" value="0"/>
<set attribute="ShrinkPeriodMinutes" value="15"/>
<set attribute="ShrinkingEnabled" value="true"/>
<set attribute="TestConnectionsOnRelease" value="false"/>
<set attribute="TestConnectionsOnReserve" value="true"/>
<set attribute="TestTableName" value="SYSTABLES"/>
<set attribute="URL" value="${database.url}"/>
<set attribute="Targets" value="${x}" />
</create>
<create type="JDBCDataSource" name="${JDBCDataSource.name}" >
<set attribute="JNDIName" value="${JNDI.name}"/>
<set attribute="PoolName" value="${Pool.name}"/>
<set attribute="Targets" value="${targetserver}" />
</create>
</wlconfig>
</target>
请提供解决方案来解决这个问题,因为在运行这个ant脚本后,它给我无法创建mbean:无法创建提供商JDBCDataSource。
<query domain="${domainName}" type="Server" name="${targetserver}" property="targetserv"/>
<set attribute="Targets" value="${targetserv}" />
通过这些更改,它工作得很好