forked from trpc-group/trpc-cpp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
forward_service.h
36 lines (27 loc) · 1.02 KB
/
forward_service.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
//
//
// Tencent is pleased to support the open source community by making tRPC available.
//
// Copyright (C) 2023 THL A29 Limited, a Tencent company.
// All rights reserved.
//
// If you have downloaded a copy of the tRPC source code from Tencent,
// please note that tRPC source code is licensed under the Apache 2.0 License,
// A copy of the Apache 2.0 License is included in this file.
//
//
#pragma once
#include <memory>
#include "examples/features/prometheus/proxy/forward.trpc.pb.h"
#include "examples/helloworld/helloworld.trpc.pb.h"
namespace examples::forward {
using GreeterProxyPtr = std::shared_ptr<::trpc::test::helloworld::GreeterServiceProxy>;
class ForwardServiceImpl : public ::trpc::test::route::Forward {
public:
ForwardServiceImpl();
::trpc::Status Route(::trpc::ServerContextPtr context, const ::trpc::test::helloworld::HelloRequest* request,
::trpc::test::helloworld::HelloReply* reply) override;
private:
GreeterProxyPtr greeter_proxy_;
};
} // namespace examples::forward