libmuscle.native_instantiator.agent.map_client module

class libmuscle.native_instantiator.agent.map_client.MAPClient(node_name: str, location: str)[source]

Bases: object

The client for the MUSCLE Agent Protocol.

This class connects to the AgentManager and communicates with it.

close() None[source]

Close the connection

This closes the connection. After this no other member functions can be called.

get_command() AgentCommand | None[source]

Get a command from the agent manager.

Returns:

A command, or None if there are no commands pending.

report_resources(resources: OnNodeResources) None[source]

Report local resources

Parameters:

resources – Description of the resources on this node

report_result(names_exit_codes: List[Tuple[str, int]]) None[source]

Report results of finished processes.

Parameters:

names_exit_codes – A list of names and exit codes of finished processes.