Continuum

Handle filesystem problems when adding a pom

Details

  • Type: Sub-task Sub-task
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: None
  • Fix Version/s: 1.1-alpha-1
  • Component/s: None
  • Labels:
    None
  • Complexity:
    Intermediate
  • Number of attachments :
    4

Description

I see in the logs

61589439 [SocketListener0-5] INFO org.apache.maven.continuum.Continuum - Could not download https://svn.simulalabs.net/svn/repos/BEA-DotNet/trunk/pom.xml: /tmp/continuum/
svn/repos/BEA-DotNet/trunk/pom.xml (No such file or directory)
6

we should check that file error and show an internal error page instead of current

Could not download https://svn.simulalabs.net/svn/repos/BEA-DotNet/trunk/pom.xml: /tmp/continuum/svn/repos/BEA-DotNet/trunk/pom.xml (No such file or directory)
Check the logs for more details.

  1. CONTINUUM-777_2.patch
    11/Aug/06 12:51 AM
    14 kB
    Lester Ecarma
  2. CONTINUUM-777_3.patch
    16/Aug/06 2:52 AM
    3 kB
    Lester Ecarma
  3. CONTINUUM-777_more_result_handling.patch
    14/Aug/06 8:38 PM
    27 kB
    Joakim Erdfelt
  4. CONTINUUM-777.patch
    08/Aug/06 3:43 AM
    4 kB
    Lester Ecarma

Activity

Hide
Lester Ecarma added a comment -

The attached patch (CONTINUUM-777.patch) only covers AddMavenTwoProjectAction. I'm not sure if I got it right, so I'll wait for comments before I work on the other classes.

Show
Lester Ecarma added a comment - The attached patch (CONTINUUM-777.patch) only covers AddMavenTwoProjectAction. I'm not sure if I got it right, so I'll wait for comments before I work on the other classes.
Hide
Lester Ecarma added a comment -

Second stab at this issue (CONTINUUM-777_2.patch). As with the first one, this only covers AddMavenTwoProjectAction.

Show
Lester Ecarma added a comment - Second stab at this issue (CONTINUUM-777_2.patch). As with the first one, this only covers AddMavenTwoProjectAction.
Hide
Carlos Sanchez added a comment -

refactored architecture to handle this.

Errors that must be presented to the user don't throw exceptions, they are added to a ContinuumProjectBuildingResult.
ContinuumProjectBuildingResult has constants with the keys of the errors. We use keys so it can be i18n later on the web layer.

Errors to be shown to the user are (but not limited to):

  • xml errors in pom
  • host unknown
  • url doesn't exist
  • pom has missing info (scm, groupId, artifactId...)

Anything unexpected must be thrown as an exception to be catched by the upper layers

http://svn.apache.org/viewvc?view=rev&revision=431403

Show
Carlos Sanchez added a comment - refactored architecture to handle this. Errors that must be presented to the user don't throw exceptions, they are added to a ContinuumProjectBuildingResult. ContinuumProjectBuildingResult has constants with the keys of the errors. We use keys so it can be i18n later on the web layer. Errors to be shown to the user are (but not limited to):
  • xml errors in pom
  • host unknown
  • url doesn't exist
  • pom has missing info (scm, groupId, artifactId...)
Anything unexpected must be thrown as an exception to be catched by the upper layers http://svn.apache.org/viewvc?view=rev&revision=431403
Hide
Carlos Sanchez added a comment -

I have added a bunch of TODOs for what still needs to be done

Show
Carlos Sanchez added a comment - I have added a bunch of TODOs for what still needs to be done
Hide
Joakim Erdfelt added a comment -

Added patch to satisfy Carlos' request.

NOTE: The Validation Errors in DefaultMavenBuilderHelper.getMavenProject(ContinuumProjectBuildingResult, File) require the need for parameters on the error messages.

The stubs ContinuumProjectBuildingResult.addError(String key, Object param) and ContinuumProjectBuildingResult.addError(String key, Object params[]) have been created to facilitate this work.

Another patch can be submitted (in a different jira?) to add i18n / parameter support to the ContinuumProjectBuildingResult and related JSPs.

Show
Joakim Erdfelt added a comment - Added patch to satisfy Carlos' request. NOTE: The Validation Errors in DefaultMavenBuilderHelper.getMavenProject(ContinuumProjectBuildingResult, File) require the need for parameters on the error messages. The stubs ContinuumProjectBuildingResult.addError(String key, Object param) and ContinuumProjectBuildingResult.addError(String key, Object params[]) have been created to facilitate this work. Another patch can be submitted (in a different jira?) to add i18n / parameter support to the ContinuumProjectBuildingResult and related JSPs.
Hide
Carlos Sanchez added a comment -

committed patch

Show
Carlos Sanchez added a comment - committed patch
Hide
Lester Ecarma added a comment -

Added another patch (CONTINUUM-777_3.patch). Contains fix to a bug I found in AddMavenOneProjectAction and modifications to the view layer to display the error messages.

Show
Lester Ecarma added a comment - Added another patch (CONTINUUM-777_3.patch). Contains fix to a bug I found in AddMavenOneProjectAction and modifications to the view layer to display the error messages.
Hide
Carlos Sanchez added a comment -

Fixed but not with this patch:

  • use css to show errors
  • show all errors, not only one
Show
Carlos Sanchez added a comment - Fixed but not with this patch:
  • use css to show errors
  • show all errors, not only one

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: