Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-61711

Spec for couchdb result() doesn't handle case

    XMLWordPrintable

Details

    • Untriaged
    • 0
    • Unknown

    Description

      The -spec for result() in lhttpc_types.hrl

      -type result() ::
              {ok, {{pos_integer(), string()}, headers(), body()}} |
              {ok, upload_state()} |
              {error, atom() | {atom(), [any()]}}.
      

      doesn't handle a return from lhttpc:request

      preflight_lhttpc_request(Type, URL, Options) ->
          case lhttpc:request(URL, head, [], [], 20000, Options) of
      

      which can be

      {error,{{tls_alert,{handshake_failure,"TLS client: In state hello received SERVER ALERT: Fatal - Handshake Failure\n"}},
              [{lhttpc_client,send_request,1,
                              [{file,"/Users/steve.watanabe/trinity/couchdb/src/lhttpc/lhttpc_client.erl"},                         
                                {line,220}]},
               {lhttpc_client,execute,9,
                              [{file,"/Users/steve.watanabe/trinity/couchdb/src/lhttpc/lhttpc_client.erl"},
                               {line,169}]},
               {lhttpc_client,request,9,
                              [{file,"/Users/steve.watanabe/trinity/couchdb/src/lhttpc/lhttpc_client.erl"},
                               {line,93}]}]}} 

      This is needed by a proposed fix for MB-61648.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              steve.watanabe Steve Watanabe
              steve.watanabe Steve Watanabe
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty