thrift-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matthieu Imbert <>
Subject per-connexion state with txthrift
Date Thu, 11 Feb 2010 13:58:46 GMT

Is there a way to maintain some per-connexion state with a python twisted thrift server?

Currently, my twisted thrift server's code is inside a handler which is instanciated only
once, when initializing the server, with this kind of code:

  factory = ThriftServerFactory(
    processor = MyService.Processor(MyHandler()),
    iprot_factory = TBinaryProtocol.TBinaryProtocolFactory())
  reactor.listenTCP(some_port, factory)

There is only one MyHandler instance, thus this instance is shared for all incoming client
connexions, i see no way to maintain per-connexion state.


Matthieu Imbert <>
INRIA engineer / SED / GRAAL and RESO teams
+33(0)472728741 / +33(0)437287473
LIP ENS-Lyon, 46 allée d'Italie
69364 Lyon cedex 07, FRANCE

View raw message