As a result, the server and the worker will never be able to parse commands (except if I am mistaken and this is set somewhere, but I could not find any reference to type_name aside from the command handlers). I think we can either
Make the proxies pass it as an additional argument to the SSH connection
Make the SSH connection infer the type by looking at the Python class name (object.__class__.__name__)
What do you think is the better approach? My personal preference is 2. since it is easier to implement and won't require changing the interfaces, plus removes the need to manually specify the type everywhere.
I just noticed we never set the
type_name
which the command handlers use to differentiate between commands:https://github.com/DistributedTaskScheduling/JobAdder/blob/master/src/ja/common/proxy/command_handler.py#L60
As a result, the server and the worker will never be able to parse commands (except if I am mistaken and this is set somewhere, but I could not find any reference to
type_name
aside from the command handlers). I think we can eitherMake the proxies pass it as an additional argument to the SSH connection
Make the SSH connection infer the type by looking at the Python class name (
object.__class__.__name__
)What do you think is the better approach? My personal preference is 2. since it is easier to implement and won't require changing the interfaces, plus removes the need to manually specify the type everywhere.