Hi everybody,
I already asked this question but did not provide enough information... :(
I can not get the DataSource Component to work properly.
I am running Phoenix v4.0a3 as container.
Here is the exception in the phoenix.log file:
org.apache.avalon.framework.CascadingException: Block named "bridge" failed
to pass through the Initialization stage. (Reason: Unable to provide
DataSourceComponent for oracle).
at
org.apache.avalon.phoenix.components.application.LifecycleHelper.fail(Lifecy
cleHelper.java:416)
at
org.apache.avalon.phoenix.components.application.LifecycleHelper.startup(Lif
ecycleHelper.java:221)
at
org.apache.avalon.phoenix.components.application.DefaultApplication.runPhase
(DefaultApplication.java:177)
at
org.apache.avalon.phoenix.components.application.DefaultApplication.start(De
faultApplication.java:89)
at
org.apache.avalon.phoenix.components.kernel.DefaultKernel.startup(DefaultKer
nel.java:125)
at
org.apache.avalon.phoenix.components.kernel.DefaultKernel.addApplication(Def
aultKernel.java:170)
at
org.apache.avalon.phoenix.components.deployer.DefaultDeployer.deploy(Default
Deployer.java:168)
Here is my DataSource configuration:
<data-sources>
<data-source name="oracle"
class="org.apache.avalon.excalibur.datasource.JdbcDataSource">
<pool-controller min="5" max="10">
<keep-alive disable="false">select 1 from dual</keep-alive>
</pool-controller>
<driver>oracle.jdbc.driver.OracleDriver</driver>
<dburl>jdbc:oracle:thin:@10.0.2.25:1521:TSRV</dburl>
<user>XXXX</user>
<password>YYYY</password>
</data-source>
</data-sources>
Here is the configuration part of the component that is trying to retrieve
the DataSource:
<bridge>
<db-pool pickup="oracle" submit="oracle"/>
</bridge>
Here is my code snippet:
private DataSourceComponent dsPickup = null;
private DataSourceComponent dsSubmit = null;
dsSelector = (ComponentSelector)manager.lookup(
DataSourceSelector.ROLE);
dsPickup = (DataSourceComponent)
dsSelector.select (poolConfig.getAttribute("pickup"));
Could you provide me some infos on this.
Thanks a lot for your help.
Guillaume Kieffer
Product Development & Integration