backend/satellite_tools/connection.py | 13 -------------
backend/server/rhnServer/server_kickstart.py | 22 ----------------------
backend/server/test/test-cx_Oracle-memleak.py | 8 +-------
3 files changed, 1 insertion(+), 42 deletions(-)
New commits:
commit 36f4526d39593b874ac36de3aa27975112931a23
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Tue Oct 26 16:41:07 2010 +0200
Method parse_url not used in backend, removing as dead code.
diff --git a/backend/satellite_tools/connection.py
b/backend/satellite_tools/connection.py
index f14ce59..e7c7fc3 100644
--- a/backend/satellite_tools/connection.py
+++ b/backend/satellite_tools/connection.py
@@ -16,7 +16,6 @@
#
#
-import urllib
import string
import gzipstream
@@ -101,18 +100,6 @@ class GETServer(rpclib.GETServer):
_transport_class_proxy = ProxyTransport
_transport_class_https_proxy = SafeProxyTransport
-def parse_url(url):
- url_type, rest = urllib.splittype(url)
- if url_type is None:
- url_type = 'http'
- rest = '//' + rest
-
- url_type = string.lower(url_type)
-
- hostport, path = urllib.splithost(rest)
- host, port = urllib.splitport(hostport)
- return url_type, host, port, path
-
class CompressedStream:
"""
GzipStream will not close the connection by itself, so we have to keep the
commit ba9368ee2c25d6f798733dd4a31ff2f806fef22b
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Tue Oct 26 16:38:47 2010 +0200
The method _line_value does not seem to be used in the test.
diff --git a/backend/server/test/test-cx_Oracle-memleak.py
b/backend/server/test/test-cx_Oracle-memleak.py
index cc9a4e8..54483f1 100644
--- a/backend/server/test/test-cx_Oracle-memleak.py
+++ b/backend/server/test/test-cx_Oracle-memleak.py
@@ -1,5 +1,5 @@
#
-# Copyright (c) 2008 Red Hat, Inc.
+# Copyright (c) 2008--2010 Red Hat, Inc.
#
# This software is licensed to you under the GNU General Public License,
# version 2 (GPLv2). There is NO WARRANTY for this software, express or
@@ -34,12 +34,6 @@ def mem_usage():
dict[arr[0]] = arr[1]
return dict['Name'], dict['VmSize'], dict['VmRSS'],
dict['VmData']
-def _line_value(line):
- arr = string.split(line, ':', 1)
- if len(arr) == 1:
- return None
- return string.strip(arr[1])
-
dbh = cx_Oracle.Connection(sys.argv[1])
h = dbh.cursor()
h.execute('select 1 from dual')
commit e33df1eb4bd4a7633ebb74e9339360c6e7329ef4
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Tue Oct 26 16:35:05 2010 +0200
Removing get_kickstart_label which does not seem to be used anywhere.
diff --git a/backend/server/rhnServer/server_kickstart.py
b/backend/server/rhnServer/server_kickstart.py
index 05a9007..7defef4 100644
--- a/backend/server/rhnServer/server_kickstart.py
+++ b/backend/server/rhnServer/server_kickstart.py
@@ -152,28 +152,6 @@ def get_kickstart_session_id(server_id, action_id):
return None
return row['id']
-_query_lookup_kickstart_label = rhnSQL.Statement("""
- select k.label
- from rhnKickstartSession ks, rhnKSData k
- where (
- (ks.old_server_id = :server_id and ks.new_server_id is NULL)
- or ks.new_server_id = :server_id
- or ks.host_server_id = :server_id
- )
- and ks.action_id = :action_id
- and k.id = ks.kickstart_id
-""")
-
-def get_kickstart_label(server_id, action_id):
- h = rhnSQL.prepare(_query_lookup_kickstart_label)
- h.execute(server_id=server_id, action_id=action_id)
-
- row = h.fetchone_dict()
- if not row:
- # Nothing to do
- return None
- return row['label']
-
_query_insert_package_delta = rhnSQL.Statement("""