I'm trying to define a data source for Oracle Lite. To test, I'm using the
"useless news" example that comes with Orion. OLite provides a native JDBC
driver that Oracle says is 1.22 compliant.

Here is my datasources file:
<data-sources>
        <data-source
                class="com.evermind.sql.ConnectionDataSource"
                name="OracleLite"
                location="jdbc/OracleLiteCoreDS"
                xa-location="jdbc/xa/OracleLiteXADS"
                ejb-location="jdbc/OracleLiteDS"
                connection-driver="oracle.lite.poljdbc.POLJDBCDriver"
                username="system"
                password="manager"
                url="jdbc:polite:polite"
                inactivity-timeout="30"
                schema="database-schemas/oraclelite.xml"
        />
</data-sources>

This creates the news table in the OLite database. The News component adds
rows to the table, but does not display news items in the item list. (I can
run Oracle Navigator and see the rows in the table.) If I enter some text in
the Search field and click Search, Windows (2kPro) generates a DrWatson
file: OLite crashes with an "access violation". This crashes Orion.

I have written a stand-alone Java program that shows the OLite JDBC driver
to be operating ok. The program uses forName to load/register the OLite JDBC
driver, gets a connection, executes a query, and dumps the resultset. This
works.

Should I use a different class for the data-source, like OrionCMTDataSource,
since the OLite JDBC driver is only 1.22 compliant? If so, how? I've tried
this by using the following datasource file, but I get a Java
nullpointerexception when I run Orion:
<data-sources>
        <data-source
                class="com.evermind.sql.DriverManagerXADataSource"
                name="xads"
                location="jdbc/xads"
                xa-location="jdbc/xa/xads"
                connection-driver="oracle.lite.poljdbc.POLJDBCDriver"
                username="system"
                password="manager"
                url="jdbc:polite:polite"
                inactivity-timeout="30"
                schema="database-schemas/oraclelite.xml"
        />
        <data-source
                class="com.evermind.sql.OrionCMTDataSource"
                name="Default data-source"
                location="jdbc/cmtds"
                pooled-location="jdbc/cmtpooledds"
                ejb-location="jdbc/cmtejbds"
                source-location="jdbc/xads"
        />
</data-sources>

Any comments? 

Thanks,
Andrew

Reply via email to