[Twisted-Python] Perspective Broker vs AMP

Jean-Paul Calderone exarkun at divmod.com
Mon Mar 31 08:44:41 EDT 2008

On Mon, 31 Mar 2008 13:18:44 +0100, Simon Pickles <sipickles at hotmail.com> wrote:
>Jean-Paul Calderone wrote:
> [snip]
>>In addition to the other suggestions that have been made in this thread,
>>notice that PBClientFactory.login takes two arguments: the credentials
>>object used for authentication and an optional "client" object which
>>defaults to None.
>This looks very interesting.
>>The value of this parameter is made available to your
>>realm in the `mind´ parameter.
>Er, I'm sorry but I don't understand realm and mind. I'm new to this area.
>>This means you can pass a reference to
>>login for this parameter and the server can use it to make calls onto the
>>client whenever it wants, rather than having to wait for a subsequent
>>call made by the client.
>This is exactly what I would like to do.

Have you read the cred howto?  There is a section on realms and one on minds
(although the mind section is quite abstract and may not make any sense).


Basically, the mind is just an argument which will be available in your
realm to use however you like.  The realm is the object which creates your
avatars.  Avatars are the objects which are returned by the login method
of PBClientFactory.


More information about the Twisted-Python mailing list