Results 1 to 3 of 3

Thread: Exceptions and Spring's HttpInvoker

  1. #1
    Join Date
    Sep 2004
    Location
    USA
    Posts
    27

    Default Exceptions and Spring's HttpInvoker

    Hi,

    Are there any special requirements in terms of declared and runtime exceptions for the services that are remotely exposed using HttpInvoker.

    For example (abbreviated):
    Code:
    public class AcountService implements AccountService
    ...
       public void setAccountNumber( String AccountNumber )
       throws AccountNumberNotValid{
            
           ... somewhere in the code runtime NumberFormatException is thrown
    
       }
    }
    Class below throws declared exception, and runtime exception.

    My expectation is that client will have to handle an exception, right?

    How about runtime exceptions. How are these received on the client?

  2. #2
    Join Date
    Aug 2004
    Location
    Amsterdam, Netherlands
    Posts
    450

    Default

    There's an exception translator that translates all exceptions thrown by the service. So you should just receive all exceptions you throw in your service without doing anything special.

    rgds,
    Alef Arendsen
    Alef Arendsen
    SpringSource
    http://www.springsource.com

  3. #3
    Join Date
    Sep 2004
    Location
    USA
    Posts
    27

    Default

    Thank you Alef,

    Can you also tell me please what are the spring dependencies on the client side if I want to use Spring HTTPInvoker?

    Thank you,
    Edmon

Similar Threads

  1. No rollback with exceptions using Hibernate
    By elwell642 in forum Data
    Replies: 4
    Last Post: Feb 8th, 2005, 08:52 AM
  2. Replies: 2
    Last Post: Dec 20th, 2004, 04:35 PM
  3. Hibernate checked Exceptions
    By ndijkstra in forum Data
    Replies: 3
    Last Post: Oct 20th, 2004, 10:43 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •