exiddis::master::WorkerSender::WorkerSender Class Reference
Inherits twisted::web::xmlrpc::Proxy.
List of all members.
Detailed Description
Send messages via XML-RPC to one of the workers (every worker has it's own WorkerSender in Master server application).
Member Function Documentation
| def exiddis::master::WorkerSender::WorkerSender::__init__ |
( |
|
self, |
|
|
|
parent, |
|
|
|
id, |
|
|
|
host, |
|
|
|
port | |
|
) |
| | |
Create new instance of WorkerSender class.
Keyword parameters:
parent - reference to parent object (e.g. Workers class instance)
id - id of worker with which comminicates this WorkerSender
host - host of worker
port - port of worker
| def exiddis::master::WorkerSender::WorkerSender::addSequence |
( |
|
self, |
|
|
|
seq | |
|
) |
| | |
Inform worker that new sequence has been assigned to it.
Keyword arguments:
seq - sequence object sent using pickle module
| def exiddis::master::WorkerSender::WorkerSender::addSequenceResp |
( |
|
self, |
|
|
|
resp | |
|
) |
| | |
Callback called when addSequence ends with success and doing nothing.
| def exiddis::master::WorkerSender::WorkerSender::addToGroup |
( |
|
self, |
|
|
|
wuid | |
|
) |
| | |
Inform worker that new worker has joined group.
Keyword parameters:
wuid - new worker's id
| def exiddis::master::WorkerSender::WorkerSender::addToGroupResp |
( |
|
self, |
|
|
|
resp | |
|
) |
| | |
Callback called when addToGroup ends with success and doing nothing. In fact, this doc message is almost 40 times longer then entire method.
| def exiddis::master::WorkerSender::WorkerSender::addUserRight |
( |
|
self, |
|
|
|
user, |
|
|
|
seqId, |
|
|
|
role | |
|
) |
| | |
Inform worker about new rights for one of it's sequences.
Keyword parameters:
user - id of the user that obtained new rights
seqId - id of sequence to with the rights were obtained
role - type of user's role
| def exiddis::master::WorkerSender::WorkerSender::addUserRightResp |
( |
|
self, |
|
|
|
resp | |
|
) |
| | |
Callback called when addUserRight ends with success and doing nothing.
| def exiddis::master::WorkerSender::WorkerSender::assignBackup |
( |
|
self, |
|
|
|
host, |
|
|
|
port | |
|
) |
| | |
Send to worker it's backup host and port. This function is unused due to the fact that worker-to-worker backups are not supported yet.
| def exiddis::master::WorkerSender::WorkerSender::assignBackupResp |
( |
|
self, |
|
|
|
resp | |
|
) |
| | |
Callback called when assignBackup ends with success and guess what? Doing nothing.
| def exiddis::master::WorkerSender::WorkerSender::giveSeqBack |
( |
|
self |
) |
|
Send request for returning one of worker's sequences (called when worker is overloaded).
It's not the best load-balancing method but was the easiest to implement and we haven't got enough time to provide something better.
| def exiddis::master::WorkerSender::WorkerSender::giveSeqBackResp |
( |
|
self, |
|
|
|
resp | |
|
) |
| | |
Callback called when giveSeqBack ends with success. Update assignments of returned sequence.
| def exiddis::master::WorkerSender::WorkerSender::notify |
( |
|
self, |
|
|
|
error | |
|
) |
| | |
Callback called when an error occurs. Delete worker from system.
| def exiddis::master::WorkerSender::WorkerSender::removeSequence |
( |
|
self, |
|
|
|
seqId | |
|
) |
| | |
Inform worker that given sequence is no longer assigned to it.
Keyword parameters:
seqId - sequence id
| def exiddis::master::WorkerSender::WorkerSender::removeSequenceResp |
( |
|
self, |
|
|
|
resp | |
|
) |
| | |
Callback called when removeSequence ends with success and doing nothing.
| def exiddis::master::WorkerSender::WorkerSender::updateSequences |
( |
|
self |
) |
|
Send request for obtaining data about worker's sequences' current values (for backuping purposes) and sequences' load-levels (for load-balancing).
| def exiddis::master::WorkerSender::WorkerSender::updateSequencesResp |
( |
|
self, |
|
|
|
resp | |
|
) |
| | |
Callback called when updateSequences ends with success and guess what? No! It does plenty of important things, namely:
* sends data about load-level to load-balancer for parsing,
* updates backup with actual values of sequences.
The documentation for this class was generated from the following file:
- exiddis/master/WorkerSender.py