db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bryan Pendleton (JIRA)" <derby-...@db.apache.org>
Subject [jira] Updated: (DERBY-826) sysinfo does not report the version of derby.jar if the class does not explictly contain it.
Date Sat, 15 Apr 2006 00:29:01 GMT
     [ http://issues.apache.org/jira/browse/DERBY-826?page=all ]

Bryan Pendleton updated DERBY-826:
----------------------------------

    Attachment: derby-826-v3.diff

Hi Andrew. Thank you for considering all my feedback. Your new patch looks very good to me.
I have only one final concern. When I was spot-testing your patch, I noticed that, while the
mergeZips method appears to strip duplicates out of zip1 entirely, and it strips out of zip2
any entries that also exist in zip1, it does not strip duplicates which exist twice in zip2.

For example, try running java -cp derby.jar:db2jcc.jar:db2jcc.jar:derbytools.jar sysinfo.
I believe you will see info about db2jcc.jar being printed twice.

I think this can be fixed by changing the zip2 processing loop in mergeZips so that, when
it searches to see if the current entry duplicates an existing entry, it searches the entries
in "v", rather than searching the entries in zip1.

I've attached a proposed version 3 of the patch. The only substantive change between this
version and your version is as follows:

< +            for (int k = 0; k < zip1.length; k++)
---
> +            for (int k = 0; k < v.size(); k++)
265c265,266
< +                  if (zip1[k] == null)
---
> +                  ZipInfoProperties z = (ZipInfoProperties)v.get(k);
> +                  if (z == null)
267c268
< +                  if (zip2[j].getLocation().equals(zip1[k].getLocation()))
---
> +                  if (zip2[j].getLocation().equals(z.getLocation()))



> sysinfo does not report the version of derby.jar if the class does not explictly contain
it.
> --------------------------------------------------------------------------------------------
>
>          Key: DERBY-826
>          URL: http://issues.apache.org/jira/browse/DERBY-826
>      Project: Derby
>         Type: Bug

>   Components: Tools
>     Versions: 10.2.0.0
>     Reporter: Daniel John Debrunner
>     Assignee: Andrew McIntyre
>     Priority: Minor
>  Attachments: derby-826-v3.diff, derby-826.diff, derby-826_v2.diff
>
> derby.jar is in the classpath here indirectly because derbynet.jar includes it through
a manifest entry.
> java -cp jars/sane/derbynet.jar org.apache.derby.tools.sysinfo
> ------------------ Java Information ------------------
> Java Version:    1.4.2
> Java Vendor:     IBM Corporation
> Java home:       C:\Program Files\IBM\Java142\jre
> Java classpath:  jars/sane/derbynet.jar
> OS name:         Windows XP
> OS architecture: x86
> OS version:      5.1
> Java user name:  djd
> Java user home:  C:\Documents and Settings\Administrator
> Java user dir:   c:\_work\svn_clean2\trunk
> java.specification.name: Java Platform API Specification
> java.specification.version: 1.4
> --------- Derby Information --------
> JRE - JDBC: J2SE 1.4.2 - JDBC 3.0
> [C:\_work\svn_clean2\trunk\jars\sane\derbynet.jar] 10.2.0.0 alpha - (370500M)
> ------------------------------------------------------
> ----------------- Locale Information -----------------
> Current Locale :  [English/United States [en_US]]
> Found support for locale: [de_DE]
>          version: 10.2.0.0 alpha - (370500M)
> Found support for locale: [es]
>          version: 10.2.0.0 alpha - (370500M)
> Found support for locale: [fr]
>          version: 10.2.0.0 alpha - (370500M)
> Found support for locale: [it]
>          version: 10.2.0.0 alpha - (370500M)
> Found support for locale: [ja_JP]
>          version: 10.2.0.0 alpha - (370500M)
> Found support for locale: [ko_KR]
>          version: 10.2.0.0 alpha - (370500M)
> Found support for locale: [pt_BR]
>          version: 10.2.0.0 alpha - (370500M)
> Found support for locale: [zh_CN]
>          version: 10.2.0.0 alpha - (370500M)
> Found support for locale: [zh_TW]
>          version: 10.2.0.0 alpha - (370500M)
> ------------------------------------------------------

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message