You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by Myrna van Lunteren <m....@gmail.com> on 2007/05/09 09:30:46 UTC

Blob/Clob Stored procedures with embedded and JSR169

Hi,

I encountered some interesting test failures with the upgrade tests
calling the  Blob- and ClobStoredProcedureTest with JSR169. The
failures are because of usage of DriverManager at
org.apache.derby.impl.services.reflect.DirectCall.invoke(Unknown
Source)


This is in *lobStoredProcedureTest.suite():
       if (JDBC.vmSupportsJSR169()) {
            return new TestSuite("empty: client not supported on JSR169");
        }
        else {
            return TestConfiguration.defaultSuite(
                    BlobStoredProcedureTest.class);
        }

Now, I have the following questions:
1. re *lobStoredProcedureTest.suite: why is this test using
TestConfiguration.defaultSuite, when it is apparently only a test for
client?
2. when this test does run with embedded, what does it actually do?
3. If it can be run with embedded, shouldn't it also be possible to
run with JSR169?

Thx,
Myrna

Re: Blob/Clob Stored procedures with embedded and JSR169

Posted by V Narayanan <V....@Sun.COM>.
Thank you for doing this.

Narayanan

Myrna van Lunteren wrote On 05/09/07 22:40,:

> Thx for your reply.
>
> I'll log a separate bug for the failure with the upgrade tests and add
> the stack trace. It's probably the same as the original trouble.
> Apparently, junit grabs hold of the actual fixtures in the test, not
> the suite method, and so, the tests still run from the upgrade test
> suite. I'll modify the upgrade test' suite method to not run those
> *lobStoredProcedureTests with JSR169.
> I'll also modify the text for the empty suite in the
> *lobStoredProcedureTests, to point out that the code uses
> DriverManager to get a connection.
>
> Myrna


Re: Blob/Clob Stored procedures with embedded and JSR169

Posted by Myrna van Lunteren <m....@gmail.com>.
Thx for your reply.

I'll log a separate bug for the failure with the upgrade tests and add
the stack trace. It's probably the same as the original trouble.
Apparently, junit grabs hold of the actual fixtures in the test, not
the suite method, and so, the tests still run from the upgrade test
suite. I'll modify the upgrade test' suite method to not run those
*lobStoredProcedureTests with JSR169.
I'll also modify the text for the empty suite in the
*lobStoredProcedureTests, to point out that the code uses
DriverManager to get a connection.

Myrna

Re: Blob/Clob Stored procedures with embedded and JSR169

Posted by V Narayanan <V....@Sun.COM>.
Hi,

failures of these tests in weme6.1 were fixed as part of DERBY-2427

 >1. re *lobStoredProcedureTest.suite: why is this test using
 >TestConfiguration.defaultSuite, when it is apparently only a test for
 >client?

This test does not need to run in the embedded mode. They just need to 
test the LOB related
stored procedures when working in the client/server mode. I can re-write 
it to work this way if
it is resulting in problems during test runs. I just let it remain the 
way it is today since it was
not resulting in any problems.

 >2. when this test does run with embedded, what does it actually do?

Whether you run in embedded or client server mode the stored procedures 
related to
locator exist and are accessible and would have the same functionality.

 >3. If it can be run with embedded, shouldn't it also be possible to
 >run with JSR169?

No! Because the LODStoredProcedures.java class uses DriverManager to get 
a connection.
If you run with JSR169 I guess this is not possible. This was why the 
tests were disabled in
DERBY-2427.

Can you please mention what is the error you are getting? Would it be 
possible for you to
give the stack trace of the exception of the failure you get? I would 
think disabling the tests while
running with JSR169 which resolved 2427 would work in the case of 
upgrade too.

Narayanan

Myrna van Lunteren wrote On 05/09/07 13:00,:

> Hi,
>
> I encountered some interesting test failures with the upgrade tests
> calling the  Blob- and ClobStoredProcedureTest with JSR169. The
> failures are because of usage of DriverManager at
> org.apache.derby.impl.services.reflect.DirectCall.invoke(Unknown
> Source)
>
>
> This is in *lobStoredProcedureTest.suite():
>        if (JDBC.vmSupportsJSR169()) {
>             return new TestSuite("empty: client not supported on 
> JSR169");
>         }
>         else {
>             return TestConfiguration.defaultSuite(
>                     BlobStoredProcedureTest.class);
>         }
>
> Now, I have the following questions:
> 1. re *lobStoredProcedureTest.suite: why is this test using
> TestConfiguration.defaultSuite, when it is apparently only a test for
> client?
> 2. when this test does run with embedded, what does it actually do?
> 3. If it can be run with embedded, shouldn't it also be possible to
> run with JSR169?
>
> Thx,
> Myrna