Uploaded image for project: 'Spring Framework'
  1. Spring Framework
  2. SPR-9325

Add more details in ResourceAccessException message thrown by doExecute method of RestTemplate

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Complete
    • Affects Version/s: 3.1.1
    • Fix Version/s: 3.2 RC1
    • Component/s: Core
    • Last commented by a User:
      true

      Description

      The RestTemplate is throwing exception message as follows:

      throw new ResourceAccessException("I/O error: " + ex.getMessage(), ex);

      The message can be improved by adding URL and Method passed to doExecute method.

      Thanks,

        Issue Links

          Activity

          Hide
          cbeams Chris Beams added a comment -

          Hi Ritesh,

          Sounds like a good idea! Putting this in the General Backlog for now, but if you're interested, please consider making the change and submitting a pull request per the contributor guidelines.

          Show
          cbeams Chris Beams added a comment - Hi Ritesh, Sounds like a good idea! Putting this in the General Backlog for now, but if you're interested, please consider making the change and submitting a pull request per the contributor guidelines .
          Hide
          rcrathore Ritesh added a comment -

          Thanks Chris,

          I have created a pull request (https://github.com/SpringSource/spring-framework/pull/82). This is first time I am doing this so please let me know if I have made any mistake. I haven't made any change in any test, I think the ioException test of RestTemplateTests covers my changes.

          Show
          rcrathore Ritesh added a comment - Thanks Chris, I have created a pull request ( https://github.com/SpringSource/spring-framework/pull/82 ). This is first time I am doing this so please let me know if I have made any mistake. I haven't made any change in any test, I think the ioException test of RestTemplateTests covers my changes.

            People

            • Assignee:
              rstoya05-aop Rossen Stoyanchev
              Reporter:
              rcrathore Ritesh
              Last updater:
              Juergen Hoeller
            • Votes:
              1 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                4 years, 19 weeks, 6 days ago