Debian Codegraph @

docs/core/benchmarks/tpserver.py

raw
1 """Throughput server."""
2
3 import sys
4
5 from twisted.internet import protocol, reactor
6 from twisted.protocols.wire import Discard
7 from twisted.python import log
8
9
10 def main():
11 f = protocol.ServerFactory()
12 f.protocol = Discard
13 reactor.listenTCP(8000, f)
14 reactor.run()
15
16
17 if __name__ == "__main__":
18 main()