Uploaded image for project: 'Tools (JBoss Tools)'
  1. Tools (JBoss Tools)
  2. JBIDE-25098

Provide a status preserving the stacktrace in DownloadRuntimeOperationUtility.downloadAndUnzip

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Done
    • Major
    • 4.5.1.AM3
    • 4.5.0.Final
    • server
    • None

    Description

      in org.jboss.tools.runtime.core.util.internal.DownloadRuntimeOperationUtility.downloadAndUnzip(String, String, String, boolean, String, String, TaskModel, IProgressMonitor)

      a status is directly returned instead of following the guidelines explained in the javadoc for CoreException.getStatus to recreate a Status which will preserve the stacktrace

      IStatus org.eclipse.core.runtime.CoreException.getStatus()
      
      
      Returns the status object for this exception. 
      
      IMPORTANT:
       The result must NOT be used for logging, error reporting, or as a method return value, since that code pattern hides the original stack trace. Instead, create a new Status with your plug-in ID and this CoreException, and use that new status for error reporting or as a method return value. For example, instead of: 
            yourPlugin.getLog().log(exception.getStatus());
         
      Use:       IStatus result = new Status(exception.getStatus().getSeverity(), pluginId, message, exception);
            yourPlugin.getLog().log(result);
         
      
      Returns:a status object
      

      Attachments

        Issue Links

          Activity

            People

              apupier@redhat.com Aurélien Pupier
              apupier@redhat.com Aurélien Pupier
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: