Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 344183 - Long numeric artifact names produce an exception and make branch non-usable
Summary: Long numeric artifact names produce an exception and make branch non-usable
Status: RESOLVED FIXED
Alias: None
Product: OSEE
Classification: Technology
Component: OSEE Application Framework (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 0.9.8   Edit
Assignee: Ryan Brooks CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-28 15:06 EDT by md Mising name CLA
Modified: 2011-08-16 20:25 EDT (History)
1 user (show)

See Also:


Attachments
Proposed fix (1.90 KB, application/octet-stream)
2011-04-28 15:22 EDT, md Mising name CLA
no flags Details
Patch containing bug fix from MD (2.10 KB, patch)
2011-05-19 12:41 EDT, Ryan Brooks CLA
ryan.d.brooks: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description md Mising name CLA 2011-04-28 15:06:42 EDT
Build Identifier: eclipse -M20110210-1200, osee 0.9.8 SR2

If more then one artifact or folder names contain only digits and are longer then 20 characters(may be less), then due to InvalidNumberFormat exception in ArtifactNameComparator.java the branch can not be rendered in artifact explorer tree anymore.  

Reproducible: Always

Steps to Reproduce:
1. Use demo setup and database and start system
2. on any branch rename any  two folders in artifact explorer to  long numeric    only names ,
   for example "Validation Tests" to "99999999999999999999" and 
   "Verification Tests" to "888888888888888888888".
3. switch to another branch and back 
4. the branch with renamed folders do not render properly and exception occurs.
Comment 1 md Mising name CLA 2011-04-28 15:22:31 EDT
Created attachment 194309 [details]
Proposed fix
Comment 2 md Mising name CLA 2011-04-28 15:25:31 EDT
in attachment there is proposed fix -
use Long if names are less then 19 characters and string compare otherwise.
Works fine for me.
Comment 3 Ryan Brooks CLA 2011-05-19 12:41:21 EDT
Created attachment 196135 [details]
Patch containing bug fix from MD
Comment 4 Ryan Brooks CLA 2011-05-19 12:45:53 EDT
MD,

Thanks for finding and fixing this bug.  I have created a patch file from your original Java file so it can be applied in the usual way.  Since this is a bug fix, I'll apply it to our next service release of 0.9.8 which is SR3.

If you don't mind providing your name, then I can provide the correct author when I apply the patch in Git.

Thanks,
Ryan
Comment 5 Ryan Brooks CLA 2011-08-16 20:25:22 EDT
Ryan Brooks applied this patch to 0.9.8_SR3 in the commit:
bug[bgz_344183]: Fix ArtifactNameComparator to handle long numeric names