Home
last modified time | relevance | path

Searched refs:servicer_context (Results 1 – 15 of 15) sorted by relevance

/external/grpc-grpc/src/python/grpcio_testing/grpc_testing/_server/
D_service.py45 def _unary_response(argument, implementation, rpc, servicer_context): argument
47 response = implementation(argument, servicer_context)
54 def _stream_response(argument, implementation, rpc, servicer_context): argument
56 response_iterator = implementation(argument, servicer_context)
73 def unary_unary(implementation, rpc, request, servicer_context): argument
74 _unary_response(request, implementation, rpc, servicer_context)
77 def unary_stream(implementation, rpc, request, servicer_context): argument
78 _stream_response(request, implementation, rpc, servicer_context)
81 def stream_unary(implementation, rpc, handler, servicer_context): argument
83 _RequestIterator(rpc, handler), implementation, rpc, servicer_context)
[all …]
D_server.py33 def service(implementation, rpc, servicer_context): argument
34 _service.unary_unary(implementation, rpc, request, servicer_context)
41 def service(implementation, rpc, servicer_context): argument
42 _service.unary_stream(implementation, rpc, request, servicer_context)
49 def service(implementation, rpc, servicer_context): argument
50 _service.stream_unary(implementation, rpc, handler, servicer_context)
57 def service(implementation, rpc, servicer_context): argument
58 _service.stream_stream(implementation, rpc, handler, servicer_context)
75 servicer_context = _servicer_context.ServicerContext(
82 servicer_context,
/external/grpc-grpc/src/python/grpcio/grpc/beta/
D_server_adaptations.py37 def __init__(self, servicer_context): argument
38 self._servicer_context = servicer_context
49 def __init__(self, servicer_context): argument
50 self._servicer_context = servicer_context
88 def adaptation(request, servicer_context): argument
90 _FaceServicerContext(servicer_context))
97 def adaptation(request_iterator, servicer_context): argument
99 _FaceServicerContext(servicer_context))
159 servicer_context): argument
164 if not servicer_context.is_active() or thread_joined.is_set():
[all …]
/external/grpc-grpc/src/python/grpcio_tests/tests/unit/
D_metadata_test.py90 def validate_client_metadata(test, servicer_context): argument
91 invocation_metadata = servicer_context.invocation_metadata()
101 def handle_unary_unary(test, request, servicer_context): argument
102 validate_client_metadata(test, servicer_context)
103 servicer_context.send_initial_metadata(_INITIAL_METADATA)
104 servicer_context.set_trailing_metadata(_TRAILING_METADATA)
108 def handle_unary_stream(test, request, servicer_context): argument
109 validate_client_metadata(test, servicer_context)
110 servicer_context.send_initial_metadata(_INITIAL_METADATA)
111 servicer_context.set_trailing_metadata(_TRAILING_METADATA)
[all …]
D_invocation_defects_test.py62 def handle_unary_unary(self, request, servicer_context): argument
64 if servicer_context is not None:
65 servicer_context.set_trailing_metadata(((
71 def handle_unary_stream(self, request, servicer_context): argument
76 if servicer_context is not None:
77 servicer_context.set_trailing_metadata(((
82 def handle_stream_unary(self, request_iterator, servicer_context): argument
83 if servicer_context is not None:
84 servicer_context.invocation_metadata()
91 if servicer_context is not None:
[all …]
D_interceptor_test.py65 def handle_unary_unary(self, request, servicer_context): argument
67 if servicer_context is not None:
68 servicer_context.set_trailing_metadata(((
74 def handle_unary_stream(self, request, servicer_context): argument
79 if servicer_context is not None:
80 servicer_context.set_trailing_metadata(((
85 def handle_stream_unary(self, request_iterator, servicer_context): argument
86 if servicer_context is not None:
87 servicer_context.invocation_metadata()
94 if servicer_context is not None:
[all …]
D_exit_scenarios.py59 def hang_unary_unary(request, servicer_context): argument
63 def hang_unary_stream(request, servicer_context): argument
67 def hang_partial_unary_stream(request, servicer_context): argument
73 def hang_stream_unary(request_iterator, servicer_context): argument
77 def hang_partial_stream_unary(request_iterator, servicer_context): argument
83 def hang_stream_stream(request_iterator, servicer_context): argument
87 def hang_partial_stream_stream(request_iterator, servicer_context): argument
D_compression_test.py28 def handle_unary(request, servicer_context): argument
29 servicer_context.send_initial_metadata([('grpc-internal-encoding-request',
34 def handle_stream(request_iterator, servicer_context): argument
37 servicer_context.send_initial_metadata([('grpc-internal-encoding-request',
D_session_cache_test.py46 def handle_unary_unary(request, servicer_context): argument
48 _ID: servicer_context.peer_identities(),
49 _ID_KEY: servicer_context.peer_identity_key(),
50 _AUTH_CTX: servicer_context.auth_context()
D_empty_message_test.py31 def handle_unary_unary(request, servicer_context): argument
35 def handle_unary_stream(request, servicer_context): argument
40 def handle_stream_unary(request_iterator, servicer_context): argument
46 def handle_stream_stream(request_iterator, servicer_context): argument
D_rpc_test.py64 def handle_unary_unary(self, request, servicer_context): argument
66 if servicer_context is not None:
67 servicer_context.set_trailing_metadata(((
74 servicer_context.is_active()
75 servicer_context.time_remaining()
78 def handle_unary_stream(self, request, servicer_context): argument
83 if servicer_context is not None:
84 servicer_context.set_trailing_metadata(((
89 def handle_stream_unary(self, request_iterator, servicer_context): argument
90 if servicer_context is not None:
[all …]
D_auth_context_test.py53 def handle_unary_unary(request, servicer_context): argument
55 _ID: servicer_context.peer_identities(),
56 _ID_KEY: servicer_context.peer_identity_key(),
57 _AUTH_CTX: servicer_context.auth_context()
D_resource_exhausted_test.py67 def handle_unary_unary(trigger, request, servicer_context): argument
72 def handle_unary_stream(trigger, request, servicer_context): argument
78 def handle_stream_unary(trigger, request_iterator, servicer_context): argument
86 def handle_stream_stream(trigger, request_iterator, servicer_context): argument
D_channel_close_test.py37 def stream_stream(self, request_iterator, servicer_context): argument
/external/grpc-grpc/src/python/grpcio_tests/tests/interop/
Dmethods.py36 def _maybe_echo_metadata(servicer_context): argument
38 invocation_metadata = dict(servicer_context.invocation_metadata())
42 servicer_context.send_initial_metadata((initial_metadatum,))
46 servicer_context.set_trailing_metadata((trailing_metadatum,))
49 def _maybe_echo_status_and_message(request, servicer_context): argument
52 servicer_context.set_code(request.response_status.code)
53 servicer_context.set_details(request.response_status.message)