Revision 445d7262 lib/rapi/connector.py

b/lib/rapi/connector.py
89 89

  
90 90

  
91 91
def GetHandlers(node_name_pattern, instance_name_pattern,
92
                group_name_pattern, job_id_pattern, disk_pattern,
92
                group_name_pattern, network_name_pattern,
93
                job_id_pattern, disk_pattern,
93 94
                query_res_pattern):
94 95
  """Returns all supported resources and their handlers.
95 96

  
......
167 168
    re.compile(r"^/2/instances/(%s)/console$" % instance_name_pattern):
168 169
      rlib2.R_2_instances_name_console,
169 170

  
171
    "/2/networks": rlib2.R_2_networks,
172
    re.compile(r"^/2/networks/(%s)$" % network_name_pattern):
173
      rlib2.R_2_networks_name,
174
    re.compile(r"^/2/networks/(%s)/connect$" % network_name_pattern):
175
      rlib2.R_2_networks_name_connect,
176
    re.compile(r"^/2/networks/(%s)/disconnect$" % network_name_pattern):
177
      rlib2.R_2_networks_name_disconnect,
178
    re.compile(r"^/2/networks/(%s)/connectall$" % network_name_pattern):
179
      rlib2.R_2_networks_name_connectall,
180
    re.compile(r"^/2/networks/(%s)/disconnectall$" % network_name_pattern):
181
      rlib2.R_2_networks_name_disconnectall,
182

  
170 183
    "/2/groups": rlib2.R_2_groups,
171 184
    re.compile(r"^/2/groups/(%s)$" % group_name_pattern):
172 185
      rlib2.R_2_groups_name,
......
197 210
    }
198 211

  
199 212

  
200
CONNECTOR.update(GetHandlers(_NAME_PATTERN, _NAME_PATTERN, _NAME_PATTERN,
213
CONNECTOR.update(GetHandlers(_NAME_PATTERN, _NAME_PATTERN,
214
                             _NAME_PATTERN, _NAME_PATTERN,
201 215
                             constants.JOB_ID_TEMPLATE, _DISK_PATTERN,
202 216
                             _NAME_PATTERN))

Also available in: Unified diff