db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Knut Anders Hatlen (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (DERBY-5847) Clean up IDE warnings in DRDAConnThread
Date Wed, 11 Jul 2012 12:10:34 GMT

     [ https://issues.apache.org/jira/browse/DERBY-5847?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Knut Anders Hatlen updated DERBY-5847:
--------------------------------------

    Attachment: d5847-8b-misc.patch

Replacing the 8a-misc patch with d5847-8b-misc.patch. The new version removes the dead code
and adds the following comment:

            // The protocol wants us to send RDBUPDRM here, but we don't do
            // that because it used to cause protocol errors. DERBY-5847 has
            // some discussion about this issue.

It's a bit vague, since we don't know exactly which errors the code caused.

For the record, I tried to enable the code and ran some statements that exercised the path.
That is, the following commands in ij:

ij> connect 'jdbc:derby://localhost/db;create=true';
ij> create table t (x int);
0 rows inserted/updated/deleted
ij> prepare ps as 'insert into t values 1,2,3';
ij> execute ps;
3 rows inserted/updated/deleted
ij> execute ps;
3 rows inserted/updated/deleted

I verified that RDBUPDRM was sent on the "execute ps" statements, and no protocol error was
seen.

I also repeated the experiment using the JCC driver (had to make the changes in a 10.8 server
to get it to run, as trunk rejects JCC after DERBY-5565). Same result there; RDBUPDRM was
sent, and the JCC client happily accepted it.

So it may be OK to start sending RDBUPDRM now. But there's also a chance that there's some
other usage pattern that will trigger the mentioned protocol error. Since there are no known
problems caused by the lack of the RDBUPDRM, and this issue is about silencing warnings, I'll
just leave it like that for now.
                
> Clean up IDE warnings in DRDAConnThread
> ---------------------------------------
>
>                 Key: DERBY-5847
>                 URL: https://issues.apache.org/jira/browse/DERBY-5847
>             Project: Derby
>          Issue Type: Improvement
>          Components: Network Server
>    Affects Versions: 10.10.0.0
>            Reporter: Knut Anders Hatlen
>            Assignee: Knut Anders Hatlen
>            Priority: Minor
>         Attachments: d5847-1a-string-equality.patch, d5847-2a-unnecessary-return.patch,
d5847-3a-static-fields-and-imports.patch, d5847-4a-unused-assignment.patch, d5847-5a-performance-warnings.patch,
d5847-6a-obsolete-collection.patch, d5847-7a-sync-on-non-final.patch, d5847-8a-misc.patch,
d5847-8b-misc.patch, d5847-9a-this-leak.patch, d5847-9b-this-leak.patch
>
>
> When I open DRDAConnThread in NetBeans, I see 49 warnings. Most of them are harmless
(like static fields accessed via an instance, suggestions about using StringBuilder instead
of StringBuffer, or using System.arraycopy() instead of for loops). Others indicate real problems,
like the use of != to compare SQL states in writeSQLDIAGGRP().
> We should clean up the warnings so that it's easier to notice new warnings about potential
problems.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message