Ignore:
Timestamp:
Dec 3, 2008 9:41:58 AM (15 years ago)
Author:
Ted Faber <faber@…>
Branches:
axis_example, compt_changes, info-ops, master, version-1.30, version-2.00, version-3.01, version-3.02
Children:
375ca67
Parents:
46a0f7a
Message:

Differentiate between a failure to connect to a service and the service being
provided using an unexpected protocol. Deal with the internal connection error
more cleanly when the connection is being made to an internal service. That
is, when an internal service is down, propagate a clean error out to the
caller. Before this change, the internal service failure would look like a
protocol error on the external service (SOAP being provided by XMLRPC, for
example) and try the other protocol, which would fail with a misleading error.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fedd/federation/service_error.py

    r46a0f7a r9d3e646  
    1212    partial = 6
    1313    federant = 7
     14    connect = 8
    1415    code_str = {
    1516        access : "Access Denied",
     
    1819        server_config: "Server Configuration Error",
    1920        internal : "Internal Error",
    20         partial: "Partial embedding",
    21         federant: "Federant error"
     21        partial: "Partial Embedding",
     22        federant: "Federant Error",
     23        connect: "Connection Error",
    2224    }
    2325    str_code = dict([ (v, k) for k, v in code_str.iteritems() ])
    24     client_errors = ( req )
    25     server_errors = ( access, protocol, server_config, internal)
     26    client_errors = ( req, partial)
     27    server_errors = ( access, protocol, server_config, internal,
     28            federant, connect)
    2629
    2730    def __init__(self, code=None, desc=None, from_string=None):
Note: See TracChangeset for help on using the changeset viewer.