Changes between Version 51 and Version 52 of FrequentlyAskedQuestions


Ignore:
Timestamp:
10/22/2012 07:25:21 PM (21 months ago)
Author:
exarkun
Comment:

more emphasis, also backticks don't work inside links

Legend:

Unmodified
Added
Removed
Modified
  • FrequentlyAskedQuestions

    v51 v52  
    9797Twisted already does this.  If you want to connect to multiple servers, call `connectTCP` (or similar) multiple times, and each call will result in a single outgoing connection.  `listenTCP` will result in your factory (and therefore your protocol) being invoked for each incoming connection. 
    9898 
    99 Sometimes people ask this question when they write a function that calls `connectTCP`, then `reactor.run()`.  You don't usually need to call `reactor.run()` yourself; let [http://twistedmatrix.com/documents/current/core/howto/basics.html#auto1 `twistd`] do it.  If you do need to call it yourself, call it ''just once'' after your initial setup.  When `reactor.run()` exits, your program should too. 
     99Sometimes people ask this question when they write a function that calls `connectTCP`, then `reactor.run()`.  You don't usually need to call `reactor.run()` yourself; let [http://twistedmatrix.com/documents/current/core/howto/basics.html#auto1 twistd] (not "Twisted") do it.  If you do need to call it yourself, call it ''just once'' after your initial setup.  When `reactor.run()` exits, your program should too. 
    100100 
    101101=== How do I make input on one connection result in output on another? ===