Use OAuthProblemException for OAuthDataStore
--------------------------------------------

                 Key: SHINDIG-995
                 URL: https://issues.apache.org/jira/browse/SHINDIG-995
             Project: Shindig
          Issue Type: Improvement
          Components: Java
    Affects Versions: trunk
            Reporter: Paul Lindner
            Assignee: Paul Lindner


Implementors of the OAuthDataStore class do not have an easy way to propagate 
errors to the caller.  A simple way to deal with this is to use the 
OAuthProblemException class.

For three-legged oauth this works quite well, as there's an exception handler 
in doGet/doPost

For two-legged OAuth we can convert the exception to a 
InvalidAuthenticationException and proceed.  For now we can include the 
getMessage() output here, in future we could also directly handle 
OAuthProblemException by explicitly allowing them to be thrown or by inspecting 
the cause field of the thrown InvalidAuthenticationException.

Code Review here:

http://codereview.appspot.com/28108



-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to