proxygen
CodecErrorResponseHandler.cpp
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2015-present, Facebook, Inc.
3  * All rights reserved.
4  *
5  * This source code is licensed under the BSD-style license found in the
6  * LICENSE file in the root directory of this source tree. An additional grant
7  * of patent rights can be found in the PATENTS file in the same directory.
8  *
9  */
11 
12 #include <folly/Conv.h>
13 
14 using folly::IOBuf;
15 using std::string;
16 using std::unique_ptr;
17 
18 namespace proxygen {
19 
21  : txn_(nullptr) {}
22 
24 }
25 
26 void
28  txn_ = txn;
29 }
30 
31 void
33  delete this;
34 }
35 
37  std::unique_ptr<HTTPMessage> /*msg*/) noexcept {
38  VLOG(4) << "discarding headers";
39 }
40 
41 void CodecErrorResponseHandler::onBody(unique_ptr<IOBuf> /*chain*/) noexcept {
42  VLOG(4) << "discarding request body";
43 }
44 
46  unique_ptr<HTTPHeaders> /*trailers*/) noexcept {
47  VLOG(4) << "discarding request trailers";
48 }
49 
50 void
52 }
53 
55  UpgradeProtocol /*protocol*/) noexcept {}
56 
58  VLOG(4) << "processing error " << error;
59  txn_->sendAbort();
60 }
61 
62 } // proxygen
void onHeadersComplete(std::unique_ptr< HTTPMessage > msg) noexceptoverride
void onTrailers(std::unique_ptr< HTTPHeaders > trailers) noexceptoverride
requires E e noexcept(noexcept(s.error(std::move(e))))
requires And< SemiMovable< VN >... > &&SemiMovable< E > auto error(E e)
Definition: error.h:48
#define nullptr
Definition: http_parser.c:41
void setTransaction(HTTPTransaction *txn) noexceptoverride
void onError(const HTTPException &error) noexceptoverride
void onBody(std::unique_ptr< folly::IOBuf > chain) noexceptoverride
const char * string
Definition: Conv.cpp:212
void onUpgrade(UpgradeProtocol protocol) noexceptoverride