db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dag H. Wanvik (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (DERBY-6125) Code clean up in client driver.
Date Tue, 02 Apr 2013 05:21:15 GMT

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

Dag H. Wanvik updated DERBY-6125:

    Attachment: derby-6125-05-a.diff

Uploading a new patch, derby-6125-05-a, regression ran OK.

Patch derby-6125-05-a details:

- reworked ClientXid#equals to find favor with FindBugs: now tests for null and wrong type.
  The old version would get classcastexception if a wrong type object was compared.

- copies bytes in setPKGNAMCBytes to avoid having a package private variable
  wriable from outside the package (its an array).

- removed unnecessary a priori allocation to Sqlca#sqlErrd_.

- made Statement#materialStatement_ private; new accessors

- removed unnecessary default NetConnection finalizer

- removed unnecessary test for BIG_ENDIAN in NetSqlca#getRowCount: the
  protocol always uses big endian (SignedBinary.BIG_ENDIAN = 1 is final).

- removed unnecessary type argument to NetSqlca#getRowCount now that endian test is no longer

- removed potentially harmful finalizer in NetXAConnection: it calls a
  finalizer for another class (NetConnection). FindBugs advice on this

  "If a connected set of objects beings finalizable, then the VM will
  invoke the finalize method on all the finalizable object, possibly
  at the same time in different threads. Thus, it is a particularly
  bad idea, in the finalize method for a class X, invoke finalize on
  objects referenced by X, because they may already be getting
  finalized in a separate thread. "

- made Typdef#FdocaSimpleDataArray private

- made SqlException#SQLExceptionFactory package private (was protected)

> Code clean up in client driver.
> -------------------------------
>                 Key: DERBY-6125
>                 URL: https://issues.apache.org/jira/browse/DERBY-6125
>             Project: Derby
>          Issue Type: Improvement
>          Components: Network Client
>            Reporter: Dag H. Wanvik
>         Attachments: derby-6125-01-a.diff, derby-6125-01-b.diff, derby-6125-01-b.status,
derby-6125-02-a.diff, derby-6125-02-a.status, derby-6125-03-a.diff, derby-6125-03-a.status,
derby-6125-04-a.diff, derby-6125-04-a.status, derby-6125-05-a.diff
> Clean up unused code, lacking finals, too wide visibility etc.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

View raw message