git | 28 Mar 23:58 2014

[x2gobroker] 07/07: drop obsolete function parameter 'query_mode' when calling agent tasks

This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch master
in repository x2gobroker.

commit 700270b04644b2df8fb3b49d2d6cef4b895404eb
Author: Mike Gabriel <mike.gabriel@...>
Date:   Mon Mar 24 14:43:50 2014 +0100

    drop obsolete function parameter 'query_mode' when calling agent tasks
---
 x2gobroker/brokers/base_broker.py |   14 +++++---------
 1 file changed, 5 insertions(+), 9 deletions(-)

diff --git a/x2gobroker/brokers/base_broker.py b/x2gobroker/brokers/base_broker.py
index 8da869c..2b1cdf4 100644
--- a/x2gobroker/brokers/base_broker.py
+++ b/x2gobroker/brokers/base_broker.py
 <at>  <at>  -875,7 +875,7  <at>  <at>  class X2GoBroker(object):
                 remote_agent = {u'hostname': remote_agent_server, u'port': remote_agent_port, }

                 try:
-                    if x2gobroker.agent.ping(query_mode=agent_query_mode, remote_agent=remote_agent):
+                    if x2gobroker.agent.ping(remote_agent=remote_agent):
                         break
                 except x2gobroker.x2gobroker_exceptions.X2GoBrokerAgentException:
                     remote_agent = None
 <at>  <at>  -928,7 +928,7  <at>  <at>  class X2GoBroker(object):
                 agent_query_mode = ( remote_agent == u'LOCAL') and u'LOCAL' or u'SSH'
                 if remote_agent:
                     try:
-                        running_sessions, suspended_sessions = x2gobroker.agent.has_sessions(username,
query_mode=agent_query_mode, remote_agent=remote_agent)
+                        running_sessions, suspended_sessions = x2gobroker.agent.has_sessions(username, remote_agent=remote_agent)
                         if running_sessions:
                             logger_broker.debug('base_broker.X2GoBroker.list_profiles(): found running sessions on host(s):
{hosts}'.format(hosts=', '.join(running_sessions)))
                         if suspended_sessions:
 <at>  <at>  -980,7 +980,7  <at>  <at>  class X2GoBroker(object):
             # query remote agent for session info
             busy_servers = None
             try:
-                busy_servers = x2gobroker.agent.find_busy_servers(username=username,
query_mode=agent_query_mode, remote_agent=remote_agent)
+                busy_servers = x2gobroker.agent.find_busy_servers(username=username, remote_agent=remote_agent)
             except x2gobroker.x2gobroker_exceptions.X2GoBrokerAgentException:
                 pass

 <at>  <at>  -1048,7 +1048,7  <at>  <at>  class X2GoBroker(object):
         if remote_agent and server_list and username:

             try:
-                session_list = x2gobroker.agent.list_sessions(username=username,
query_mode=agent_query_mode, remote_agent=remote_agent)
+                session_list = x2gobroker.agent.list_sessions(username=username, remote_agent=remote_agent)
             except x2gobroker.x2gobroker_exceptions.X2GoBrokerAgentException:
                 session_list = []

 <at>  <at>  -1069,7 +1069,7  <at>  <at>  class X2GoBroker(object):
                         session_info = suspended_sessions[0]
                     else:
                         session_info = running_sessions[0]
-                        x2gobroker.agent.suspend_session(username=username,
session_name=session_info.split('|')[1], query_mode=agent_query_mode, remote_agent=remote_agent)
+                        x2gobroker.agent.suspend_session(username=username,
session_name=session_info.split('|')[1], remote_agent=remote_agent)
                         # this is the turn-around in x2gocleansessions, so waiting as along as the daemon that will suspend the session
                         time.sleep(2)
                         session_info = session_info.replace('|R|', '|S|')
 <at>  <at>  -1105,7 +1105,6  <at>  <at>  class X2GoBroker(object):
                 x2gobroker.agent.add_authorized_key(username=username,
                                                     pubkey_hash=pubkey,
                                                     authorized_keys_file=self.get_authorized_keys_file(profile_id),
-                                                    query_mode=agent_query_mode,
                                                     remote_agent=remote_agent,
                 ),
                 selected_session.update({
 <at>  <at>  -1114,7 +1113,6  <at>  <at>  class X2GoBroker(object):
                 x2gobroker.agent.delete_authorized_key(username=username,
                                                        pubkey_hash=pubkey,
                                                        authorized_keys_file=self.get_authorized_keys_file(profile_id),
-                                                       query_mode=agent_query_mode,
                                                        remote_agent=remote_agent,
                                                        delay_deletion=20,
                 )
 <at>  <at>  -1123,7 +1121,6  <at>  <at>  class X2GoBroker(object):
                 x2gobroker.agent.add_authorized_key(username=username,
                                                     pubkey_hash=pubkey,
                                                     authorized_keys_file=self.get_authorized_keys_file(profile_id),
-                                                    query_mode=agent_query_mode,
                                                     remote_agent=remote_agent,
                 ),
                 selected_session.update({
 <at>  <at>  -1132,7 +1129,6  <at>  <at>  class X2GoBroker(object):
                 x2gobroker.agent.delete_authorized_key(username=username,
                                                        pubkey_hash=pubkey,
                                                        authorized_keys_file=self.get_authorized_keys_file(profile_id),
-                                                       query_mode=agent_query_mode,
                                                        remote_agent=remote_agent,
                                                        delay_deletion=20,
                 )

--
Alioth's /srv/git/_hooks_/post-receive-email on /srv/git/code.x2go.org/x2gobroker.git
_______________________________________________
X2Go-commits mailing list
X2Go-commits@...
https://lists.berlios.de/mailman/listinfo/x2go-commits


Gmane