dev@glassfish.java.net

Re: Why does v3 bundle dataprovider.jar ?

From: Ken Paulsen <Ken.Paulsen_at_Sun.COM>
Date: Fri, 07 Nov 2008 11:56:09 -0800

We repackage dataprovider.jar to be an OSGi bundle. From the
v3/admingui/dataprovider/pom.xml file:

    <dependency>
        <groupId>com.sun.woodstock.dependlibs</groupId>
        <artifactId>dataprovider</artifactId>
        <version>1.0</version>
        <scope>compile</scope>
    </dependency>

Since the sql code is NOT required for dataprovider, we mark it optional
in the repackaged pom.xml file:

    <Import-Package>com.sun.sql.*;resolution:=optional,*</Import-Package>

What exception do you get? I assume you have sqlx.jar in your
WEB-INF/lib? Depending on how dataprovider.jar attempts to access
sqlx.jar, that might work. If it directly accesses it (vs. using the
context-classloader), it will not work -- you will need an OSGi bundle
containing the sqlx classes -- this bundle will need to be placed in the
modules directory.

Jerome, we should talk more about this...

Ken

John Baker wrote:
>
> Also, from where was dataprovider.jar obtained (which repository /
> date/version) ?
>
> If I copy sqlx.jar to v3 then there is an exception and the line
> number doesn't seem to correspond with the latest version
> of dataprovider.jar
>
> John
>
> John Baker wrote:
>>
>> Why is dataprovider.jar bundled with v3 ?
>>
>> This looks like the one from Visual Web.
>>
>> And if there's a good reason for including it, why was sqlx.jar not
>> included ?
>> The CachedRowSetDataProvider class uses the classes in sqlx.jar.
>>
>> John
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>