MCPcopy
hub / github.com/tinode/chat / init_server

Function init_server

chatbot/python/chatbot.py:221–230  ·  view source on GitHub ↗
(listen)

Source from the content-addressed store, hash-verified

219 return pb.ClientMsg(note=pb.ClientNote(topic=topic, what=pb.READ, seq_id=seq))
220
221def init_server(listen):
222 # Launch plugin server: accept connection(s) from the Tinode server.
223 server = grpc.server(futures.ThreadPoolExecutor(max_workers=16))
224 pbx.add_PluginServicer_to_server(Plugin(), server)
225 server.add_insecure_port(listen)
226 server.start()
227
228 log("Plugin server running at '"+listen+"'")
229
230 return server
231
232def init_client(addr, schema, secret, cookie_file_name, secure, ssl_host):
233 log("Connecting to", "secure" if secure else "", "server at", addr,

Callers 1

runFunction · 0.85

Calls 3

logFunction · 0.85
startMethod · 0.80
PluginClass · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…