Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 328148 - Dropping resource onto Eclipse IFile causes RSEG1003U unexpected exception
Summary: Dropping resource onto Eclipse IFile causes RSEG1003U unexpected exception
Status: RESOLVED FIXED
Alias: None
Product: Target Management
Classification: Tools
Component: RSE (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.3 M3   Edit
Assignee: David McKnight CLA
QA Contact: Martin Oberhuber CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 328157
  Show dependency tree
 
Reported: 2010-10-19 11:40 EDT by Kenya Ishimoto CLA
Modified: 2010-11-09 10:53 EST (History)
2 users (show)

See Also:


Attachments
Error log (4.25 KB, text/plain)
2010-10-19 11:44 EDT, Kenya Ishimoto CLA
no flags Details
patch to use parent when target is a File (2.28 KB, patch)
2010-10-19 12:03 EDT, David McKnight CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kenya Ishimoto CLA 2010-10-19 11:40:31 EDT
Build Identifier: 3.2

Drag an RSE resource and drop onto eclipse IFile causes error "RSEG1003U An unexpected exception has occurred". For example, if the drop target is file1.txt in folder1 in project1, the following error message dialog is displayed:

Dialog title: RSEG1003U
Message: An unexpected exception has occurred
Message in Details field: Resource '/project1/folder1/file1.txt' does not exist.

Reproducible: Always

Steps to Reproduce:
1. In Remote Systems view, expand Local system > Local Files and select a file (or select a remote resource. This error seems to occur with remote resource too.)
2. Drag the file and drop onto a file in Eclipse Navigator view
Comment 1 Kenya Ishimoto CLA 2010-10-19 11:44:46 EDT
Created attachment 181196 [details]
Error log

The attached file is errors in .matadata/.log file
Comment 2 Kenya Ishimoto CLA 2010-10-19 11:45:57 EDT
We think, to be consistent with Eclipse, dropping onto a file should be treated as drop onto its parent container. In Navigator view, it works so.
At least the "unexpected exception" error should be prevented.

This problem affects our customized view (z/OS Projects view of Rational Developer for System z) and causes the same error.
When a resource is dropped onto a remote resource, SystemDNDTransferRunnable#runInWorkspace calls transferRSEResources method and we can handle the case in our target adapter.
However, when a resource is dropped onto an Eclipse IResource, SystemDNDTransferRunnable.runInWorkspace calls transferRSEResourcesToEclipseResource, and we cannot prevent the error.
Comment 3 David McKnight CLA 2010-10-19 12:03:25 EDT
Created attachment 181198 [details]
patch to use parent when target is a File
Comment 4 David McKnight CLA 2010-10-19 12:07:21 EDT
This patch should resolve this.  Could you try it out to confirm?
Comment 5 David McKnight CLA 2010-10-19 15:46:56 EDT
I've committed my change to the HEAD stream.  Please let me know if you need a backport to RSE 3.2.2.
Comment 6 Kenya Ishimoto CLA 2010-10-20 02:11:12 EDT
David, I have tried the attached patch in my runtime-workspace, and confirmed that it resolves the problem in both Navigator view and our view (z/OS Projects view). The dropped resource was copied to its parent folder.
Comment 7 John W Snyder CLA 2010-10-20 10:22:02 EDT
Yes, please backport to RSE 3.2.2