.tx/config
by Miroslav Suchý
.tx/config | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
New commits:
commit aeefbd9067412e420fa5368722a6ebad0c6290c5
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Fri Mar 4 17:13:52 2011 +0100
migrate from translate.fedoraproject.org to transifex.net
diff --git a/.tx/config b/.tx/config
new file mode 100644
index 0000000..ca53631
--- /dev/null
+++ b/.tx/config
@@ -0,0 +1,22 @@
+[main]
+host = https://www.transifex.net
+
+[spacewalk.yum-rhn-plugin]
+file_filter = client/rhel/yum-rhn-plugin/po/<lang>.po
+source_file = client/rhel/yum-rhn-plugin/po/yum-rhn-plugin.pot
+source_lang = en
+
+[spacewalk.rhn-client-tools]
+file_filter = client/rhel/rhn-client-tools/po/<lang>.po
+source_file = client/rhel/rhn-client-tools/po/rhn-client-tools.pot
+source_lang = en
+
+[spacewalk.rhnsd]
+file_filter = client/rhel/rhnsd/po/<lang>.po
+source_file = client/rhel/rhnsd/po/rhnsd.pot
+source_lang = en
+
+[spacewalk.spacewalk-backend]
+file_filter = backend/po/<lang>.po
+source_file = backend/po/server.pot
+source_lang = en
13 years, 1 month
java/code
by Milan Zazrivec
java/code/src/com/redhat/rhn/frontend/action/user/BaseUserSetupAction.java | 98 ++++++++++
java/code/src/com/redhat/rhn/frontend/action/user/CreateUserAction.java | 11 +
java/code/src/com/redhat/rhn/frontend/action/user/CreateUserSetupAction.java | 26 ++
java/code/src/com/redhat/rhn/frontend/action/user/UserLocalePrefAction.java | 62 ------
java/code/webapp/WEB-INF/pages/user/create/usercreate.jsp | 59 ++++++
java/code/webapp/WEB-INF/struts-config.xml | 2
6 files changed, 197 insertions(+), 61 deletions(-)
New commits:
commit b68c6807eac4af8f86a2e6e5547e4977124de56c
Author: Milan Zazrivec <mzazrivec(a)redhat.com>
Date: Fri Mar 4 17:09:40 2011 +0100
682258 - specify user locale when creating new user
diff --git a/java/code/src/com/redhat/rhn/frontend/action/user/BaseUserSetupAction.java b/java/code/src/com/redhat/rhn/frontend/action/user/BaseUserSetupAction.java
new file mode 100644
index 0000000..b799313
--- /dev/null
+++ b/java/code/src/com/redhat/rhn/frontend/action/user/BaseUserSetupAction.java
@@ -0,0 +1,98 @@
+/**
+ * Copyright (c) 2009--2011 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
+ * implied, including the implied warranties of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. You should have received a copy of GPLv2
+ * along with this software; if not, see
+ * http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
+ *
+ * Red Hat trademarks are not licensed under GPLv2. No permission is
+ * granted to use or replicate Red Hat trademarks that are incorporated
+ * in this software or its documentation.
+ */
+package com.redhat.rhn.frontend.action.user;
+
+import com.redhat.rhn.common.localization.LocalizationService;
+import com.redhat.rhn.domain.user.RhnTimeZone;
+import com.redhat.rhn.domain.user.User;
+import com.redhat.rhn.frontend.struts.RequestContext;
+import com.redhat.rhn.frontend.struts.RhnAction;
+import com.redhat.rhn.manager.user.UserManager;
+
+import org.apache.struts.action.DynaActionForm;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * User locale override stuff
+ *
+ * @version $Rev $
+ */
+public class BaseUserSetupAction extends RhnAction {
+
+ public LangDisplayBean buildNoneLocale() {
+ LocalizationService ls =
+ LocalizationService.getInstance();
+ LangDisplayBean ldb = new LangDisplayBean();
+ ldb.setImageUri("");
+ ldb.setLanguageCode("none");
+ ldb.setLocalizedName(ls.getMessage("preferences.jsp.lang.none"));
+ return ldb;
+ }
+
+ public void setCurrentLocale(RequestContext ctx, User user) {
+ String userLocale = user.getPreferredLocale();
+
+ // If user has locale set, then just use that
+ if (userLocale != null) {
+ ctx.getRequest().setAttribute("currentLocale", userLocale);
+ }
+ else {
+ ctx.getRequest().setAttribute("currentLocale", "none");
+ }
+ }
+
+ public Map buildImageMap() {
+ Map retval = new LinkedHashMap();
+ LocalizationService ls = LocalizationService.getInstance();
+ List locales = ls.getConfiguredLocales();
+ for (Iterator iter = locales.iterator(); iter.hasNext();) {
+ String locale = (String) iter.next();
+ StringBuffer buf = new StringBuffer();
+ buf.append("/img/i18n/").append(locale);
+ buf.append(".gif");
+ LangDisplayBean ldb = new LangDisplayBean();
+ ldb.setImageUri(buf.toString());
+ ldb.setLanguageCode(locale);
+ ldb.setLocalizedName(ls.getMessage("preferences.jsp.lang." + locale));
+ retval.put(locale, ldb);
+ }
+ return retval;
+ }
+
+ public List getTimeZones() {
+ List dataList = UserManager.lookupAllTimeZones();
+ List displayList = new ArrayList();
+ for (int i = 0; i < dataList.size(); i++) {
+ String display = LocalizationService.getInstance()
+ .getMessage(((RhnTimeZone)dataList.get(i)).getOlsonName());
+ String value = String.valueOf(((RhnTimeZone)dataList.get(i)).getTimeZoneId());
+ displayList.add(createDisplayMap(display, value));
+ }
+ return displayList;
+ }
+
+ public Map createDisplayMap(String display, String value) {
+ Map selection = new HashMap();
+ selection.put("display", display);
+ selection.put("value", value);
+ return selection;
+ }
+}
diff --git a/java/code/src/com/redhat/rhn/frontend/action/user/CreateUserAction.java b/java/code/src/com/redhat/rhn/frontend/action/user/CreateUserAction.java
index 05c8ba9..f4fb138 100644
--- a/java/code/src/com/redhat/rhn/frontend/action/user/CreateUserAction.java
+++ b/java/code/src/com/redhat/rhn/frontend/action/user/CreateUserAction.java
@@ -27,6 +27,7 @@ import com.redhat.rhn.frontend.struts.RequestContext;
import com.redhat.rhn.frontend.struts.RhnAction;
import com.redhat.rhn.frontend.struts.RhnValidationHelper;
import com.redhat.rhn.manager.user.CreateUserCommand;
+import com.redhat.rhn.manager.user.UserManager;
import org.apache.commons.lang.StringEscapeUtils;
import org.apache.commons.lang.StringUtils;
@@ -192,6 +193,16 @@ public class CreateUserAction extends RhnAction {
command.publishNewUserEvent(orgAdmin, orgAdmin.getOrg().getActiveOrgAdmins(),
request.getServerName(),
(String) form.get(UserActionHelper.DESIRED_PASS));
+
+ user.setTimeZone(UserManager.getTimeZone(((Integer) form.get("timezone"))
+ .intValue()));
+ String preferredLocale = form.getString("preferredLocale");
+ if (preferredLocale != null && preferredLocale.equals("none")) {
+ preferredLocale = null;
+ }
+ user.setPreferredLocale(preferredLocale);
+ UserManager.storeUser(user);
+
return getStrutsDelegate().forwardParam(mapping.findForward(SUCCESS_INTO_ORG),
"uid", String.valueOf(user.getId()));
diff --git a/java/code/src/com/redhat/rhn/frontend/action/user/CreateUserSetupAction.java b/java/code/src/com/redhat/rhn/frontend/action/user/CreateUserSetupAction.java
index 69b5494..b9eba2b 100644
--- a/java/code/src/com/redhat/rhn/frontend/action/user/CreateUserSetupAction.java
+++ b/java/code/src/com/redhat/rhn/frontend/action/user/CreateUserSetupAction.java
@@ -17,8 +17,11 @@ package com.redhat.rhn.frontend.action.user;
import com.redhat.rhn.common.conf.Config;
import com.redhat.rhn.common.conf.ConfigDefaults;
import com.redhat.rhn.common.localization.LocalizationService;
+import com.redhat.rhn.domain.user.User;
import com.redhat.rhn.frontend.struts.RhnAction;
+import com.redhat.rhn.frontend.struts.RequestContext;
import com.redhat.rhn.frontend.struts.RhnValidationHelper;
+import com.redhat.rhn.manager.user.UserManager;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
@@ -32,7 +35,7 @@ import javax.servlet.http.HttpServletResponse;
* CreateUserSetupAction
* @version $Rev: 1029 $
*/
-public class CreateUserSetupAction extends RhnAction {
+public class CreateUserSetupAction extends BaseUserSetupAction {
/** placeholder string, package protected; so we don't transmit
* the actual pw but the form doesn't look empty */
static final String PLACEHOLDER_PASSWORD = "******";
@@ -43,6 +46,8 @@ public class CreateUserSetupAction extends RhnAction {
HttpServletRequest request,
HttpServletResponse response) {
DynaActionForm form = (DynaActionForm)formIn;
+ RequestContext ctx = new RequestContext(request);
+ User currentUser = ctx.getCurrentUser();
// We have to set these on the Session because struts throws them away
// if we set them on the request itself and validation fails.
@@ -76,6 +81,25 @@ public class CreateUserSetupAction extends RhnAction {
request.setAttribute("displaypamcheckbox", "true");
}
+ request.setAttribute("timezones", getTimeZones());
+
+ // There's no currentUser when creating the very first user
+ if (currentUser != null && currentUser.getTimeZone() != null) {
+ request.setAttribute("default_tz", new Integer(currentUser.getTimeZone()
+ .getTimeZoneId()));
+ }
+ else {
+ request.setAttribute("default_tz", new Integer(UserManager
+ .getDefaultTimeZone().getTimeZoneId()));
+ }
+
+ request.setAttribute("noLocale", buildNoneLocale());
+ request.setAttribute("supportedLocales", buildImageMap());
+ // There's no currentUser when creating the very first user
+ if (currentUser != null) {
+ setCurrentLocale(ctx, currentUser);
+ }
+
return mapping.findForward("default");
}
}
diff --git a/java/code/src/com/redhat/rhn/frontend/action/user/UserLocalePrefAction.java b/java/code/src/com/redhat/rhn/frontend/action/user/UserLocalePrefAction.java
index b771051..d841f40 100644
--- a/java/code/src/com/redhat/rhn/frontend/action/user/UserLocalePrefAction.java
+++ b/java/code/src/com/redhat/rhn/frontend/action/user/UserLocalePrefAction.java
@@ -18,6 +18,7 @@ import com.redhat.rhn.common.localization.LocalizationService;
import com.redhat.rhn.domain.user.RhnTimeZone;
import com.redhat.rhn.domain.user.User;
import com.redhat.rhn.frontend.action.common.BadParameterException;
+import com.redhat.rhn.frontend.action.user.BaseUserSetupAction;
import com.redhat.rhn.frontend.struts.RequestContext;
import com.redhat.rhn.frontend.struts.RhnAction;
import com.redhat.rhn.manager.user.UserManager;
@@ -44,7 +45,7 @@ import javax.servlet.http.HttpServletResponse;
*
* @version $Rev $
*/
-public class UserLocalePrefAction extends RhnAction {
+public class UserLocalePrefAction extends BaseUserSetupAction {
/**
* {@inheritDoc}
@@ -115,65 +116,6 @@ public class UserLocalePrefAction extends RhnAction {
return mapping.findForward("default");
}
- private LangDisplayBean buildNoneLocale() {
- LocalizationService ls =
- LocalizationService.getInstance();
- LangDisplayBean ldb = new LangDisplayBean();
- ldb.setImageUri("");
- ldb.setLanguageCode("none");
- ldb.setLocalizedName(ls.getMessage("preferences.jsp.lang.none"));
- return ldb;
- }
-
- private void setCurrentLocale(RequestContext ctx, User user) {
- String userLocale = user.getPreferredLocale();
-
- // If user has locale set, then just use that
- if (userLocale != null) {
- ctx.getRequest().setAttribute("currentLocale", userLocale);
- }
- else {
- ctx.getRequest().setAttribute("currentLocale", "none");
- }
- }
-
- private Map buildImageMap() {
- Map retval = new LinkedHashMap();
- LocalizationService ls = LocalizationService.getInstance();
- List locales = ls.getConfiguredLocales();
- for (Iterator iter = locales.iterator(); iter.hasNext();) {
- String locale = (String) iter.next();
- StringBuffer buf = new StringBuffer();
- buf.append("/img/i18n/").append(locale);
- buf.append(".gif");
- LangDisplayBean ldb = new LangDisplayBean();
- ldb.setImageUri(buf.toString());
- ldb.setLanguageCode(locale);
- ldb.setLocalizedName(ls.getMessage("preferences.jsp.lang." + locale));
- retval.put(locale, ldb);
- }
- return retval;
- }
-
- private List getTimeZones() {
- List dataList = UserManager.lookupAllTimeZones();
- List displayList = new ArrayList();
- for (int i = 0; i < dataList.size(); i++) {
- String display = LocalizationService.getInstance()
- .getMessage(((RhnTimeZone)dataList.get(i)).getOlsonName());
- String value = String.valueOf(((RhnTimeZone)dataList.get(i)).getTimeZoneId());
- displayList.add(createDisplayMap(display, value));
- }
- return displayList;
- }
-
- private Map createDisplayMap(String display, String value) {
- Map selection = new HashMap();
- selection.put("display", display);
- selection.put("value", value);
- return selection;
- }
-
private User lookupUser(RequestContext ctx, DynaActionForm form) {
User retval = null;
if (form.get("uid") != null) {
diff --git a/java/code/webapp/WEB-INF/pages/user/create/usercreate.jsp b/java/code/webapp/WEB-INF/pages/user/create/usercreate.jsp
index 46e27df..c73be56 100644
--- a/java/code/webapp/WEB-INF/pages/user/create/usercreate.jsp
+++ b/java/code/webapp/WEB-INF/pages/user/create/usercreate.jsp
@@ -107,6 +107,65 @@
</table>
+<c:if test="${account_type == 'into_org'}">
+ <h2><bean:message key="preferences.jsp.tz"/></h2>
+ <p><bean:message key="preferences.jsp.datestimes"/></p>
+ <div class="preference"><bean:message key="preferences.jsp.displaytimesas"/>
+ <select name="timezone">
+ <c:forEach var="tz" items="${requestScope.timezones}">
+ <c:if test="${tz.value == requestScope.default_tz}">
+ <option value="${tz.value}" selected="selected">${tz.display}</option>
+ </c:if>
+ <c:if test="${tz.value != requestScope.default_tz}">
+ <option value="${tz.value}">${tz.display}</option>
+ </c:if>
+ </c:forEach>
+ </select>
+ </div>
+
+ <h2><bean:message key="preferences.jsp.lang" /></h2>
+ <p><bean:message key="preferences.jsp.langs" /></p>
+
+ <div class="preference">
+ <c:set var="counter" value="0" />
+ <table width="75%" cellpadding="0">
+ <tr>
+ <td width="50%">
+ <input type="radio" name="preferredLocale" value="<c:out value="${noLocale.languageCode}" />"
+ <c:if test="${noLocale.languageCode == currentLocale}">
+ checked="checked"
+ </c:if>/>
+ <c:out value="${noLocale.localizedName}" />
+ <br />
+ <br />
+ </td>
+ </tr>
+ <c:forEach var="item" items="${supportedLocales}">
+ <c:if test="${counter == 0}">
+ <tr>
+ </c:if>
+ <td width="50%">
+ <input type="radio" name="preferredLocale" value="<c:out value="${item.key}" />"
+ <c:if test="${item.key == currentLocale}">
+ checked="checked"
+ </c:if>/>
+ <img src="<c:out value="${item.value.imageUri}" />" alt="<c:out value="${item.value.localizedName}" />" /> (<c:out value="${item.value.localizedName}" />)
+ </td>
+ <c:if test="${counter == 1}">
+ </tr>
+ </c:if>
+ <c:set var="counter" value="${counter + 1}" />
+ <c:if test="${counter == 2}">
+ <c:set var="counter" value="0" />
+ </c:if>
+ </c:forEach>
+
+ <c:if test="${counter == 1}">
+ </tr>
+ </c:if>
+ </table>
+ </div>
+</c:if>
<div align="right">
<html:submit>
diff --git a/java/code/webapp/WEB-INF/struts-config.xml b/java/code/webapp/WEB-INF/struts-config.xml
index 4ec43ed..7c9a414 100644
--- a/java/code/webapp/WEB-INF/struts-config.xml
+++ b/java/code/webapp/WEB-INF/struts-config.xml
@@ -67,6 +67,8 @@
<form-property name="usepam" type="java.lang.Boolean"/>
<form-property name="no_scrub" type="java.lang.String"
initial="desiredpassword, desiredpasswordConfirm"/>
+ <form-property name="preferredLocale" type="java.lang.String" />
+ <form-property name="timezone" type="java.lang.Integer"/>
</form-bean>
<form-bean name="userCreateForm"
type="com.redhat.rhn.frontend.struts.ScrubbingDynaActionForm">
13 years, 1 month
Changes to 'refs/tags/spacewalk-schema-1.4.8-1'
by Michael Mraka
Tag 'spacewalk-schema-1.4.8-1' created by Michael Mraka <michael.mraka(a)redhat.com> at 2011-03-04 15:09 +0000
Tagging package [spacewalk-schema] version [1.4.8-1] in directory [schema/spacewalk/].
Changes since spacewalk-backend-1.4.17-1:
Michael Mraka (1):
Automatic commit of package [spacewalk-schema] release [1.4.8-1].
---
rel-eng/packages/spacewalk-schema | 2 +-
schema/spacewalk/spacewalk-schema.spec | 7 ++++++-
2 files changed, 7 insertions(+), 2 deletions(-)
---
13 years, 1 month
rel-eng/packages schema/spacewalk
by Michael Mraka
rel-eng/packages/spacewalk-schema | 2 +-
schema/spacewalk/spacewalk-schema.spec | 7 ++++++-
2 files changed, 7 insertions(+), 2 deletions(-)
New commits:
commit c278ddc8feff3ad1598b9a3a9fa8f04eb367c58f
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 16:09:14 2011 +0100
Automatic commit of package [spacewalk-schema] release [1.4.8-1].
diff --git a/rel-eng/packages/spacewalk-schema b/rel-eng/packages/spacewalk-schema
index 04b4c5e..e430434 100644
--- a/rel-eng/packages/spacewalk-schema
+++ b/rel-eng/packages/spacewalk-schema
@@ -1 +1 @@
-1.4.7-1 schema/spacewalk/
+1.4.8-1 schema/spacewalk/
diff --git a/schema/spacewalk/spacewalk-schema.spec b/schema/spacewalk/spacewalk-schema.spec
index 64e9572..5030e97 100644
--- a/schema/spacewalk/spacewalk-schema.spec
+++ b/schema/spacewalk/spacewalk-schema.spec
@@ -2,7 +2,7 @@ Name: spacewalk-schema
Group: Applications/Internet
Summary: Oracle SQL schema for Spacewalk server
-Version: 1.4.7
+Version: 1.4.8
Release: 1%{?dist}
Source0: %{name}-%{version}.tar.gz
@@ -66,6 +66,11 @@ rm -rf $RPM_BUILD_ROOT
%{_mandir}/man1/spacewalk-sql*
%changelog
+* Fri Mar 04 2011 Michael Mraka <michael.mraka(a)redhat.com> 1.4.8-1
+- added schema upgrade script for rhnBlacklistObsoletes
+- removed rhnBlacklistObsoletes table
+- created postgresql upgrade script for or rhnVirtualization.uuid index
+
* Thu Mar 03 2011 Michael Mraka <michael.mraka(a)redhat.com> 1.4.7-1
- upgrade script for rhnVirtualization.uuid index
- 468690 - added index to rhnVirtualization.uuid
13 years, 1 month
Changes to 'refs/tags/spacewalk-backend-1.4.17-1'
by Michael Mraka
Tag 'spacewalk-backend-1.4.17-1' created by Michael Mraka <michael.mraka(a)redhat.com> at 2011-03-04 15:08 +0000
Tagging package [spacewalk-backend] version [1.4.17-1] in directory [backend/].
Changes since spacecmd-1.4.1-1:
Marcelo Moreira de Mello (1):
Fixed pt_BR translations issues at Kickstart Create.
Michael Mraka (16):
created postgresql upgrade script for or rhnVirtualization.uuid index
data from blacklist.xml are unused for quite long time
rhnBlacklistObsoletes contain way too old stuff
rhnBlacklistObsoletes is no more used
removed blacklists from sync
processBlacklists() is no more called
removed getBlacklistsXmlStream(); it's unused after processBlacklists() removal
removed BlacklistObsoleteItem(); it's unused after processBlacklists() removal
removed setBlacklistObsoletesContainer(); it's unused after BlacklistObsoleteItem() removal
removed blacklistImport.py; it's unused after setBlacklistObsoletesContainer() removal
removed processBlacklistObsoletes(); it's unused after blacklistImport.py removal
removed BlacklistObsoletes(); it's unused after blacklistImport.py removal
removed rhnBlacklistObsoletes table; it's unused after processBlacklistObsoletes() removal
fixed schema dependencies after rhnBlacklistObsoletes removal
added schema upgrade script for rhnBlacklistObsoletes
Automatic commit of package [spacewalk-backend] release [1.4.17-1].
---
backend/satellite_tools/diskImportLib.py | 8
backend/satellite_tools/exporter/exportLib.py | 24 --
backend/satellite_tools/satsync.py | 24 --
backend/satellite_tools/sync_handlers.py | 3
backend/satellite_tools/xmlDiskSource.py | 3
backend/satellite_tools/xmlSource.py | 8
backend/satellite_tools/xmlWireSource.py | 6
backend/server/importlib/Makefile | 1
backend/server/importlib/backend.py | 42 ---
backend/server/importlib/backendOracle.py | 10
backend/server/importlib/blacklistImport.py | 119 ----------
backend/server/importlib/importLib.py | 10
backend/server/rhnChannel.py | 25 --
backend/spacewalk-backend.spec | 9
java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_pt_BR.xml | 10
rel-eng/packages/spacewalk-backend | 2
schema/spacewalk/common/data/data.deps | 1
schema/spacewalk/common/data/rhnBlacklistObsoletes.sql | 62 -----
schema/spacewalk/common/tables/rhnBlacklistObsoletes.sql | 44 ---
schema/spacewalk/common/tables/tables.deps | 2
schema/spacewalk/oracle/triggers/rhnBlacklistObsoletes.sql | 25 --
schema/spacewalk/postgres/triggers/rhnBlacklistObsoletes.sql | 16 -
schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql | 3
schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.oracle | 3
schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.postgresql | 4
schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/009-rhnBlacklistObsoletes.sql | 1
26 files changed, 33 insertions(+), 432 deletions(-)
---
13 years, 1 month
backend/spacewalk-backend.spec rel-eng/packages
by Michael Mraka
backend/spacewalk-backend.spec | 8 +++++++-
rel-eng/packages/spacewalk-backend | 2 +-
2 files changed, 8 insertions(+), 2 deletions(-)
New commits:
commit c46496aa18c50312f86c090959ea2c15fb6398b2
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 16:08:36 2011 +0100
Automatic commit of package [spacewalk-backend] release [1.4.17-1].
diff --git a/backend/spacewalk-backend.spec b/backend/spacewalk-backend.spec
index dc14d56..6fc0bf2 100644
--- a/backend/spacewalk-backend.spec
+++ b/backend/spacewalk-backend.spec
@@ -11,7 +11,7 @@ Name: spacewalk-backend
Summary: Common programs needed to be installed on the Spacewalk servers/proxies
Group: Applications/Internet
License: GPLv2 and Python
-Version: 1.4.16
+Version: 1.4.17
Release: 1%{?dist}
URL: https://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
@@ -685,6 +685,12 @@ rm -f %{rhnconf}/rhnSecret.py*
# $Id$
%changelog
+* Fri Mar 04 2011 Michael Mraka <michael.mraka(a)redhat.com> 1.4.17-1
+- removed blacklists from sync
+- rhnBlacklistObsoletes is no more used
+- data from blacklist.xml are unused for quite long time
+- 679109 - localpath must be defined in except block
+
* Thu Mar 03 2011 Michael Mraka <michael.mraka(a)redhat.com> 1.4.16-1
- removed rpm.readHeaderFromFD(), it brokes signatures
diff --git a/rel-eng/packages/spacewalk-backend b/rel-eng/packages/spacewalk-backend
index 5864727..0be5396 100644
--- a/rel-eng/packages/spacewalk-backend
+++ b/rel-eng/packages/spacewalk-backend
@@ -1 +1 @@
-1.4.16-1 backend/
+1.4.17-1 backend/
13 years, 1 month
14 commits - backend/satellite_tools backend/server backend/spacewalk-backend.spec schema/spacewalk
by Michael Mraka
backend/satellite_tools/diskImportLib.py | 8
backend/satellite_tools/exporter/exportLib.py | 24 --
backend/satellite_tools/satsync.py | 24 --
backend/satellite_tools/sync_handlers.py | 3
backend/satellite_tools/xmlDiskSource.py | 3
backend/satellite_tools/xmlSource.py | 8
backend/satellite_tools/xmlWireSource.py | 6
backend/server/importlib/Makefile | 1
backend/server/importlib/backend.py | 42 ---
backend/server/importlib/backendOracle.py | 10
backend/server/importlib/blacklistImport.py | 119 ----------
backend/server/importlib/importLib.py | 10
backend/server/rhnChannel.py | 25 --
backend/spacewalk-backend.spec | 1
schema/spacewalk/common/data/data.deps | 1
schema/spacewalk/common/data/rhnBlacklistObsoletes.sql | 62 -----
schema/spacewalk/common/tables/rhnBlacklistObsoletes.sql | 44 ---
schema/spacewalk/common/tables/tables.deps | 2
schema/spacewalk/oracle/triggers/rhnBlacklistObsoletes.sql | 25 --
schema/spacewalk/postgres/triggers/rhnBlacklistObsoletes.sql | 16 -
schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/009-rhnBlacklistObsoletes.sql | 1
21 files changed, 13 insertions(+), 422 deletions(-)
New commits:
commit fd512cea6c1bdbfff6bda068f6c68a812f42c001
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 15:05:13 2011 +0100
added schema upgrade script for rhnBlacklistObsoletes
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/009-rhnBlacklistObsoletes.sql b/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/009-rhnBlacklistObsoletes.sql
new file mode 100644
index 0000000..ab8e72c
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/009-rhnBlacklistObsoletes.sql
@@ -0,0 +1 @@
+drop table rhnBlacklistObsoletes;
commit 2e277514476ce660091c70afe443953d4f4998ce
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 14:43:46 2011 +0100
fixed schema dependencies after rhnBlacklistObsoletes removal
diff --git a/schema/spacewalk/common/data/data.deps b/schema/spacewalk/common/data/data.deps
index 66939d5..a4a2e96 100644
--- a/schema/spacewalk/common/data/data.deps
+++ b/schema/spacewalk/common/data/data.deps
@@ -61,7 +61,6 @@ rhnKickstartTimezone :: data/rhnKSInstallType
rhnTaskoSchedule :: rhnTaskoBunch
rhnTaskoTemplate :: rhnTaskoBunch rhnTaskoTask
rhnTemplateString :: data/rhnTemplateCategory
-rhnBlacklistObsoletes :: lookup_functions
rhn_schedule_days :: data/rhn_schedules
diff --git a/schema/spacewalk/common/tables/tables.deps b/schema/spacewalk/common/tables/tables.deps
index c18f582..c72b68a 100644
--- a/schema/spacewalk/common/tables/tables.deps
+++ b/schema/spacewalk/common/tables/tables.deps
@@ -39,8 +39,6 @@ rhnActivationKey :: rhnRegToken rhnKickstartSession
rhnArchTypeActions :: rhnArchType rhnActionType
rhnAppInstallSession :: rhnAppInstallInstance rhnChecksum
rhnAppInstallSessionData :: rhnAppInstallSession
-rhnBlacklistObsoletes :: rhnChannel rhnPackageName rhnChannelPackage \
- rhnPackage
rhnChannel :: web_customer rhnChannelArch rhnChannelProduct \
rhnProductName rhnChecksum
rhnChannelArch :: rhnArchType
commit 39b789231485ee4485a832525fb616623a0cf5ef
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 14:09:57 2011 +0100
removed rhnBlacklistObsoletes table; it's unused after processBlacklistObsoletes() removal
diff --git a/schema/spacewalk/common/data/rhnBlacklistObsoletes.sql b/schema/spacewalk/common/data/rhnBlacklistObsoletes.sql
deleted file mode 100644
index b632c87..0000000
--- a/schema/spacewalk/common/data/rhnBlacklistObsoletes.sql
+++ /dev/null
@@ -1,62 +0,0 @@
---
--- 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
--- implied, including the implied warranties of MERCHANTABILITY or FITNESS
--- FOR A PARTICULAR PURPOSE. You should have received a copy of GPLv2
--- along with this software; if not, see
--- http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
---
--- Red Hat trademarks are not licensed under GPLv2. No permission is
--- granted to use or replicate Red Hat trademarks that are incorporated
--- in this software or its documentation.
---
---
---
---
-
-insert into rhnBlacklistObsoletes
- (name_id, evr_id, package_arch_id, ignore_name_id)
-values (
- LOOKUP_PACKAGE_NAME('gated'), LOOKUP_EVR(NULL, '3.6', '12'),
- LOOKUP_PACKAGE_ARCH('i386'), LOOKUP_PACKAGE_NAME('zebra')
-);
-
-insert into rhnBlacklistObsoletes
- (name_id, evr_id, package_arch_id, ignore_name_id)
-values (
- LOOKUP_PACKAGE_NAME('zebra'), LOOKUP_EVR(NULL, '0.91a', '6'),
- LOOKUP_PACKAGE_ARCH('i386'), LOOKUP_PACKAGE_NAME('gated')
-);
-
--- 7.2 does not contain gated, so zebra obsoletes gated is valid there
-
-insert into rhnBlacklistObsoletes
- (name_id, evr_id, package_arch_id, ignore_name_id)
-select
- LOOKUP_PACKAGE_NAME('gated'), LOOKUP_EVR(NULL, '3.6', '10'),
- pa.id, LOOKUP_PACKAGE_NAME('zebra')
-from rhnPackageArch pa
-where pa.label in ('i386', 'alpha');
-
-insert into rhnBlacklistObsoletes
- (name_id, evr_id, package_arch_id, ignore_name_id)
-select
- LOOKUP_PACKAGE_NAME('zebra'), LOOKUP_EVR(NULL, '0.91a', '3'),
- pa.id, LOOKUP_PACKAGE_NAME('gated')
-from rhnPackageArch pa
-where pa.label in ('i386', 'alpha');
-
-commit;
-
---
--- Revision 1.5 2003/02/10 22:56:02 misa
--- bugzilla: 83597 We cannot generate the data automagically, or we'll catch unwanted packages
---
--- Revision 1.4 2003/02/10 21:45:30 misa
--- bugzilla: 83596 Remove duplicate entries
---
--- Revision 1.3 2003/02/07 17:46:46 pjones
--- rework rhnBlacklistObsoletes
---
diff --git a/schema/spacewalk/common/tables/rhnBlacklistObsoletes.sql b/schema/spacewalk/common/tables/rhnBlacklistObsoletes.sql
deleted file mode 100644
index 42a1ea5..0000000
--- a/schema/spacewalk/common/tables/rhnBlacklistObsoletes.sql
+++ /dev/null
@@ -1,44 +0,0 @@
---
--- Copyright (c) 2008 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
--- implied, including the implied warranties of MERCHANTABILITY or FITNESS
--- FOR A PARTICULAR PURPOSE. You should have received a copy of GPLv2
--- along with this software; if not, see
--- http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
---
--- Red Hat trademarks are not licensed under GPLv2. No permission is
--- granted to use or replicate Red Hat trademarks that are incorporated
--- in this software or its documentation.
---
-
-
-CREATE TABLE rhnBlacklistObsoletes
-(
- name_id NUMBER NOT NULL
- CONSTRAINT rhn_bl_obs_nid_fk
- REFERENCES rhnPackageName (id),
- evr_id NUMBER NOT NULL
- CONSTRAINT rhn_bl_obs_eid_fk
- REFERENCES rhnPackageEVR (id),
- package_arch_id NUMBER NOT NULL
- CONSTRAINT rhn_bl_obs_paid_fk
- REFERENCES rhnPackageArch (id),
- ignore_name_id NUMBER NOT NULL
- CONSTRAINT rhn_bl_obs_inid_fk
- REFERENCES rhnPackageName (id),
- created DATE
- DEFAULT (sysdate) NOT NULL,
- modified DATE
- DEFAULT (sysdate) NOT NULL
-)
-ENABLE ROW MOVEMENT
-;
-
-CREATE INDEX rhn_bl_obs_nepi_idx
- ON rhnBlacklistObsoletes (name_id, evr_id, package_arch_id, ignore_name_id);
-
-ALTER TABLE rhnBlacklistObsoletes
- ADD CONSTRAINT rhn_bl_obs_nepi_uq UNIQUE (name_id, evr_id, package_arch_id, ignore_name_id);
-
diff --git a/schema/spacewalk/oracle/triggers/rhnBlacklistObsoletes.sql b/schema/spacewalk/oracle/triggers/rhnBlacklistObsoletes.sql
deleted file mode 100644
index 51bfb5d..0000000
--- a/schema/spacewalk/oracle/triggers/rhnBlacklistObsoletes.sql
+++ /dev/null
@@ -1,25 +0,0 @@
-
---
--- Copyright (c) 2008 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
--- implied, including the implied warranties of MERCHANTABILITY or FITNESS
--- FOR A PARTICULAR PURPOSE. You should have received a copy of GPLv2
--- along with this software; if not, see
--- http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
---
--- Red Hat trademarks are not licensed under GPLv2. No permission is
--- granted to use or replicate Red Hat trademarks that are incorporated
--- in this software or its documentation.
---
-
-create or replace trigger
-rhn_bl_obs_mod_trig
-before insert or update on rhnBlacklistObsoletes
-for each row
-begin
- :new.modified := sysdate;
-end;
-/
-show errors
diff --git a/schema/spacewalk/postgres/triggers/rhnBlacklistObsoletes.sql b/schema/spacewalk/postgres/triggers/rhnBlacklistObsoletes.sql
deleted file mode 100644
index df0c035..0000000
--- a/schema/spacewalk/postgres/triggers/rhnBlacklistObsoletes.sql
+++ /dev/null
@@ -1,16 +0,0 @@
--- oracle equivalent source sha1 f2173f3c25e95db9dde31b15c4a4c965a504503c
--- retrieved from ./1241102873/cdc6d42049bf86fbc9f1d3a5c54275eeacbd641d/schema/spacewalk/oracle/triggers/rhnBlacklistObsoletes.sql
-create or replace function rhn_bl_obs_mod_trig_fun() returns trigger as
-$$
-begin
- new.modified := current_timestamp;
- return new;
-end;
-$$ language plpgsql;
-
-create trigger
-rhn_bl_obs_mod_trig
-before insert or update on rhnBlacklistObsoletes
-for each row
-execute procedure rhn_bl_obs_mod_trig_fun();
-
commit b21fca28f26f5f01e1ade5ea0c3b1c35acc9a809
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 14:09:57 2011 +0100
removed BlacklistObsoletes(); it's unused after blacklistImport.py removal
diff --git a/backend/server/importlib/importLib.py b/backend/server/importlib/importLib.py
index 3b2f0a1..e880446 100644
--- a/backend/server/importlib/importLib.py
+++ b/backend/server/importlib/importLib.py
@@ -496,16 +496,6 @@ class ServerGroupServerArchCompat(Information):
'server-group-type' : StringType,
}
-class BlacklistObsoletes(Information):
- attributeTypes = {
- 'name' : StringType,
- 'epoch' : StringType,
- 'version' : StringType,
- 'release' : StringType,
- 'package-arch' : StringType,
- 'ignored-name' : StringType,
- }
-
class KickstartFile(Information):
attributeTypes = {
'relative_path' : StringType,
commit ec058706ae05c7850e284b3e6346c9221c327c2b
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 14:35:15 2011 +0100
removed processBlacklistObsoletes(); it's unused after blacklistImport.py removal
diff --git a/backend/server/importlib/backend.py b/backend/server/importlib/backend.py
index 87bf6be..0976e2b 100644
--- a/backend/server/importlib/backend.py
+++ b/backend/server/importlib/backend.py
@@ -572,48 +572,6 @@ class Backend:
hash.update(result)
return hash
- def processBlacklistObsoletes(self, blacklists):
- # Slightly different: the table doesn't have a sequenced field
- parentTable = 'rhnBlacklistObsoletes'
- parentTableObj = self.tables[parentTable]
- dml = DML([parentTable], self.tables)
-
- q = "select %s from %s" % (string.join(parentTableObj.pk, ", "),
- parentTable)
- h = self.dbmodule.prepare(q)
- h.execute()
-
- db_fields = {}
- for k in parentTableObj.pk:
- db_fields[k] = parentTableObj.fields[k]
-
- db_values_hash = {}
- while 1:
- row = h.fetchone_dict()
- if not row:
- break
- val = _buildDatabaseValue(row, db_fields)
- key = build_key(val, parentTableObj.pk)
- db_values_hash[key] = val
-
- # Now iterate through the values
- for entry in blacklists:
- val = {}
- _buildExternalValue(val, entry, parentTableObj)
- key = build_key(val, parentTableObj.pk)
- if db_values_hash.has_key(key):
- # Value exists
- del db_values_hash[key]
- continue
- # Have to add this value
- addHash(dml.insert[parentTable], val)
- # The rest of the stuff has to be deleted
- for k, v in db_values_hash.items():
- addHash(dml.delete[parentTable], v)
-
- self.__doDML(dml)
-
-
def processChannelArches(self, arches):
self.__processObjectCollection(arches, 'rhnChannelArch',
uploadForce=4, ignoreUploaded=1, severityLimit=4)
commit d0e5aa385fe78d02844b4f39688038db5fe97bd6
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 14:09:57 2011 +0100
removed blacklistImport.py; it's unused after setBlacklistObsoletesContainer() removal
diff --git a/backend/satellite_tools/diskImportLib.py b/backend/satellite_tools/diskImportLib.py
index 6a310ba..32d51ff 100644
--- a/backend/satellite_tools/diskImportLib.py
+++ b/backend/satellite_tools/diskImportLib.py
@@ -26,7 +26,6 @@ from spacewalk.server.importlib.backendOracle import SQLBackend
from spacewalk.server.importlib.channelImport import ChannelImport, ChannelFamilyImport
from spacewalk.server.importlib.packageImport import PackageImport, SourcePackageImport
from spacewalk.server.importlib import archImport
-from spacewalk.server.importlib import blacklistImport
from spacewalk.server.importlib import productNamesImport
class Backend:
diff --git a/backend/server/importlib/Makefile b/backend/server/importlib/Makefile
index 53c43a0..f6e110d 100644
--- a/backend/server/importlib/Makefile
+++ b/backend/server/importlib/Makefile
@@ -7,7 +7,6 @@ TOP = ../..
SUBDIR = server/importlib
SPACEWALK_FILES = __init__ archImport backendLib backendOracle backend \
- blacklistImport \
channelImport debPackage errataCache errataImport headerSource importLib \
kickstartImport mpmSource \
packageImport productNamesImport packageUpload userAuth
diff --git a/backend/server/importlib/blacklistImport.py b/backend/server/importlib/blacklistImport.py
deleted file mode 100644
index 9a30c23..0000000
--- a/backend/server/importlib/blacklistImport.py
+++ /dev/null
@@ -1,119 +0,0 @@
-#
-# 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
-# implied, including the implied warranties of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE. You should have received a copy of GPLv2
-# along with this software; if not, see
-# http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
-#
-# Red Hat trademarks are not licensed under GPLv2. No permission is
-# granted to use or replicate Red Hat trademarks that are incorporated
-# in this software or its documentation.
-#
-#
-# Blacklists import
-#
-
-from importLib import Import
-
-class BlacklistObsoletesImport(Import):
- def __init__(self, batch, backend):
- Import.__init__(self, batch, backend)
- self.names = {}
- self.evrs = {}
- self.package_arches = {}
-
- def preprocess(self):
- for entry in self.batch:
- self.names[entry['name']] = None
- self.names[entry['ignored-name']] = None
-
- evr = self._make_evr(entry)
- entry['evr'] = evr
- self.evrs[evr] = None
-
- self.package_arches[entry['package-arch']] = None
-
- def fix(self):
- self.backend.lookupPackageNames(self.names)
- self.backend.lookupEVRs(self.evrs)
- self.backend.lookupPackageArches(self.package_arches)
- for entry in self.batch:
- entry['name_id'] = self.names[entry['name']]
- entry['evr_id'] = self.evrs[entry['evr']]
- entry['package_arch_id'] = self.package_arches[entry['package-arch']]
- entry['ignore_name_id'] = self.names[entry['ignored-name']]
-
- def submit(self):
- self.backend.processBlacklistObsoletes(self.batch)
- self.backend.commit()
-
- def _make_evr(self, entry):
- result = []
- for label in ['epoch', 'version', 'release']:
- val = entry[label]
- if val == '':
- val = None
- result.append(val)
- return tuple(result)
-
-if __name__ == '__main__':
- from spacewalk.server import rhnSQL
- rhnSQL.initDB('satuser/satuser@satdev')
- from importLib import BlacklistObsoletes
- batch = [
- BlacklistObsoletes().populate({
- 'name' : 'zebra',
- 'epoch' : '',
- 'version' : '0.91a',
- 'release' : '6',
- 'package-arch' : 'i386',
- 'ignored-name' : 'gated',
- }),
- BlacklistObsoletes().populate({
- 'name' : 'zebra',
- 'epoch' : '',
- 'version' : '0.91a',
- 'release' : '3',
- 'package-arch' : 'i386',
- 'ignored-name' : 'gated',
- }),
- BlacklistObsoletes().populate({
- 'name' : 'zebra',
- 'epoch' : '',
- 'version' : '0.91a',
- 'release' : '3',
- 'package-arch' : 'alpha',
- 'ignored-name' : 'gated',
- }),
- BlacklistObsoletes().populate({
- 'name' : 'gated',
- 'epoch' : '',
- 'version' : '3.6',
- 'release' : '10',
- 'package-arch' : 'i386',
- 'ignored-name' : 'zebra',
- }),
- BlacklistObsoletes().populate({
- 'name' : 'gated',
- 'epoch' : '',
- 'version' : '3.6',
- 'release' : '10',
- 'package-arch' : 'alpha',
- 'ignored-name' : 'zebra',
- }),
- BlacklistObsoletes().populate({
- 'name' : 'gated',
- 'epoch' : '',
- 'version' : '3.6',
- 'release' : '12',
- 'package-arch' : 'i386',
- 'ignored-name' : 'zebra',
- }),
- ]
- from backendOracle import OracleBackend
- ob = OracleBackend()
- importer = BlacklistObsoletesImport(batch, ob)
- importer.run()
diff --git a/backend/spacewalk-backend.spec b/backend/spacewalk-backend.spec
index 55de363..dc14d56 100644
--- a/backend/spacewalk-backend.spec
+++ b/backend/spacewalk-backend.spec
@@ -429,7 +429,6 @@ rm -f %{rhnconf}/rhnSecret.py*
%{pythonrhnroot}/server/importlib/backend.py*
%{pythonrhnroot}/server/importlib/backendLib.py*
%{pythonrhnroot}/server/importlib/backendOracle.py*
-%{pythonrhnroot}/server/importlib/blacklistImport.py*
%{pythonrhnroot}/server/importlib/channelImport.py*
%{pythonrhnroot}/server/importlib/debPackage.py*
%{pythonrhnroot}/server/importlib/errataCache.py*
commit 4422371712037459ad48ca4760b304915deabd3c
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 14:09:57 2011 +0100
removed setBlacklistObsoletesContainer(); it's unused after BlacklistObsoleteItem() removal
diff --git a/backend/satellite_tools/diskImportLib.py b/backend/satellite_tools/diskImportLib.py
index 7dae65a..6a310ba 100644
--- a/backend/satellite_tools/diskImportLib.py
+++ b/backend/satellite_tools/diskImportLib.py
@@ -62,13 +62,6 @@ class diskImportLibContainer:
importer.run()
self.batch = []
-class BlacklistObsoletesContainer(diskImportLibContainer, xmlSource.BlacklistObsoletesContainer):
- importer_class = blacklistImport.BlacklistObsoletesImport
- def endContainerCallback(self):
- if not self.batch:
- return
- diskImportLibContainer.endContainerCallback(self)
-
class ProductNamesContainer(diskImportLibContainer, xmlSource.ProductNamesContainer):
importer_class = productNamesImport.ProductNamesImport
def endContainerCallback(self):
diff --git a/backend/satellite_tools/sync_handlers.py b/backend/satellite_tools/sync_handlers.py
index 575fcea..316edb6 100644
--- a/backend/satellite_tools/sync_handlers.py
+++ b/backend/satellite_tools/sync_handlers.py
@@ -429,7 +429,6 @@ class ContainerHandler:
self.setChannelPackageArchContainer()
# all other containers
self.setChannelFamilyContainer()
- self.setBlacklistObsoletesContainer()
self.setProductNamesContainer()
def __del__(self):
@@ -471,8 +470,6 @@ class ContainerHandler:
# set all other containers:
def setChannelFamilyContainer(self):
self.handler.set_container(ChannelFamilyContainer())
- def setBlacklistObsoletesContainer(self):
- self.handler.set_container(diskImportLib.BlacklistObsoletesContainer())
def setProductNamesContainer(self):
self.handler.set_container(diskImportLib.ProductNamesContainer())
commit 19deef3db77a05aa16205d2d9491a907a6528d20
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 13:55:59 2011 +0100
removed BlacklistObsoleteItem(); it's unused after processBlacklists() removal
diff --git a/backend/satellite_tools/xmlSource.py b/backend/satellite_tools/xmlSource.py
index 8f154e4..325f384 100644
--- a/backend/satellite_tools/xmlSource.py
+++ b/backend/satellite_tools/xmlSource.py
@@ -712,11 +712,6 @@ class ErrataFileItem(BaseChecksummedItem):
}
addItem(ErrataFileItem)
-class BlacklistObsoleteItem(BaseItem):
- item_name = 'rhn-blacklist-obsolete'
- item_class = importLib.BlacklistObsoletes
-addItem(BlacklistObsoleteItem)
-
class ProductNamesItem(BaseItem):
item_name = 'rhn-product-name'
item_class = importLib.ProductName
@@ -1043,9 +1038,6 @@ class ChannelPackageArchCompatContainer(ContainerHandler):
class ServerGroupServerArchCompatContainer(ContainerHandler):
container_name = 'rhn-server-group-server-arch-compatibility-map'
-class BlacklistObsoletesContainer(ContainerHandler):
- container_name = 'rhn-blacklist-obsoletes'
-
class ProductNamesContainer(ContainerHandler):
container_name = 'rhn-product-names'
commit ad45906345fa3939fe8b1e4d5b95189409fee7f0
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 13:55:59 2011 +0100
removed getBlacklistsXmlStream(); it's unused after processBlacklists() removal
diff --git a/backend/satellite_tools/xmlDiskSource.py b/backend/satellite_tools/xmlDiskSource.py
index 8a2ea5a..48e5e2b 100644
--- a/backend/satellite_tools/xmlDiskSource.py
+++ b/backend/satellite_tools/xmlDiskSource.py
@@ -255,9 +255,6 @@ class MetadataDiskSource:
def getChannelFamilyXmlStream(self):
return ChannelFamilyDiskSource(self.mountpoint).load()
- def getBlacklistsXmlStream(self):
- return BlacklistsDiskSource(self.mountpoint).load()
-
def getProductNamesXmlStream(self):
return ProductnamesDiskSource(self.mountpoint).load()
diff --git a/backend/satellite_tools/xmlWireSource.py b/backend/satellite_tools/xmlWireSource.py
index b612c85..0174630 100644
--- a/backend/satellite_tools/xmlWireSource.py
+++ b/backend/satellite_tools/xmlWireSource.py
@@ -250,12 +250,6 @@ class MetadataWireSource(BaseWireSource):
self._prepare()
return self._openSocketStream("dump.errata", (self.systemid, erratumIds))
- def getBlacklistsXmlStream(self):
- "retrieve xml stream for blacklists"
- self._prepare()
- return self._openSocketStream("dump.blacklist_obsoletes",
- (self.systemid, ))
-
def getKickstartsXmlStream(self, ksLabels):
"retrieve xml stream for kickstart trees"
self._prepare()
commit 9cc3c65cb04e2e399f8d76b4b7257e0d9bf375ab
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 11:50:36 2011 +0100
processBlacklists() is no more called
diff --git a/backend/satellite_tools/satsync.py b/backend/satellite_tools/satsync.py
index 3a013fd..39fed19 100644
--- a/backend/satellite_tools/satsync.py
+++ b/backend/satellite_tools/satsync.py
@@ -590,6 +590,10 @@ Please contact your RHN representative""") % (generation, sat_cert.generation))
def processChannelFamilies(self):
self._process_simple("getChannelFamilyXmlStream", "channel-families")
+ try:
+ self._process_simple("getProductNamesXmlStream", "product names")
+ except Exception:
+ None
def _set_comps_for_channel(self, backend, channel_id, path, timestamp):
sth = backend.dbmodule.prepare("""
@@ -821,13 +825,6 @@ Please contact your RHN representative""") % (generation, sat_cert.generation))
self._channel_req = rc
return rc
- def processBlacklists(self):
- self._process_simple("getBlacklistsXmlStream", "blacklists")
- try:
- self._process_simple("getProductNamesXmlStream", "product names")
- except Exception:
- None
-
def _get_channel_timestamp(self, channel):
try:
timestamp = self._channel_collection.get_channel_timestamp(channel)
commit b934af65fdb1461f24417f9abe9c1749bee6b13e
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 00:16:41 2011 +0100
removed blacklists from sync
diff --git a/backend/satellite_tools/satsync.py b/backend/satellite_tools/satsync.py
index bf6fa44..3a013fd 100644
--- a/backend/satellite_tools/satsync.py
+++ b/backend/satellite_tools/satsync.py
@@ -90,8 +90,7 @@ class Runner:
'rpms' : [''],
'srpms' : [''],
'channels' : ['channel-families'],
- 'channel-families' : ['blacklists'],
- 'blacklists' : ['arches'],
+ 'channel-families' : [''],
'short' : [''],
'download-errata' : ['errata'],
'download-packages' : [''],
@@ -106,7 +105,6 @@ class Runner:
'channel-families',
'arches',
'channels',
- 'blacklists',
'short',
'download-packages',
'rpms',
@@ -171,7 +169,6 @@ class Runner:
if actionDict.has_key('list-channels'):
if actionDict['list-channels'] == 1:
actionDict['channels'] = 1
- actionDict['blacklists'] = 0
actionDict['arches'] = 0
actionDict['channel-families'] = 1
channels = []
@@ -306,9 +303,6 @@ class Runner:
sendMail()
return 1
- def _step_blacklists(self):
- return self.syncer.processBlacklists()
-
def _step_short(self):
try:
return self.syncer.processShortPackages()
@@ -2107,9 +2101,7 @@ def processCommandline():
sys.exit(27)
# the action dictionary used throughout
- actionDict = {
- 'blacklists' : 0,
- }
+ actionDict = {}
if OPTIONS.list_channels:
if OPTIONS.step:
@@ -2147,7 +2139,6 @@ def processCommandline():
channels = OPTIONS.channel or []
if OPTIONS.list_channels:
actionDict['channels'] = 1
- actionDict['blacklists'] = 0
actionDict['arches'] = 0
actionDict['channel-families'] = 1
channels = []
commit f4609362f38bff3f21fad396326e895778eaf779
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 00:07:52 2011 +0100
rhnBlacklistObsoletes is no more used
diff --git a/backend/server/importlib/backendOracle.py b/backend/server/importlib/backendOracle.py
index 9576755..352db24 100644
--- a/backend/server/importlib/backendOracle.py
+++ b/backend/server/importlib/backendOracle.py
@@ -433,16 +433,6 @@ class OracleBackend(Backend):
},
pk = ['server_arch_id', 'server_group_type'],
),
- Table('rhnBlacklistObsoletes',
- fields = {
- 'name_id' : DBint(),
- 'evr_id' : DBint(),
- 'package_arch_id' : DBint(),
- 'ignore_name_id' : DBint(),
- },
- pk = ['name_id', 'evr_id', 'package_arch_id',
- 'ignore_name_id'],
- ),
Table('rhnKickstartableTree',
fields = {
'id' : DBint(),
commit 8047a43a663446afcdfeba094daddce7e51abb49
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 00:04:18 2011 +0100
rhnBlacklistObsoletes contain way too old stuff
so it no more match to any existing data and we can safely skip it
diff --git a/backend/server/rhnChannel.py b/backend/server/rhnChannel.py
index 646d814..53c7ccc 100644
--- a/backend/server/rhnChannel.py
+++ b/backend/server/rhnChannel.py
@@ -1365,31 +1365,6 @@ def list_obsoletes(channel):
and c.label = :channel
and c.id = cp.channel_id
and cp.package_id = po.package_id
- minus
- -- obsoletes that are blacklisted follow
- select cp.channel_id,
- po.package_id, po.capability_id, po.sense
- from rhnPackageName pni,
- rhnPackageCapability pc,
- rhnBlacklistObsoletes bo,
- rhnPackage p,
- rhnPackageObsoletes po,
- rhnChannelPackage cp,
- rhnChannel c
- where 1=1
- and c.label = :channel
- and c.id = cp.channel_id
- -- find all the packages we have obsoletes for
- and cp.package_id = po.package_id
- -- now find the name, and get the blacklists that apply
- and po.package_id = p.id
- and p.name_id = bo.name_id
- and p.evr_id = bo.evr_id
- and p.package_arch_id = bo.package_arch_id
- -- now match the blacklisted names to the caps
- and po.capability_id = pc.id
- and pc.name = pni.name
- and bo.ignore_name_id = pni.id
) p_info
where 1=1
and p_info.package_id = p.id
commit e7f15a6698266509e17017434ae26f3e48a29d83
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Thu Mar 3 23:52:31 2011 +0100
data from blacklist.xml are unused for quite long time
but we need to create at empty file so older satellites / spacewalks can
still sync from us
diff --git a/backend/satellite_tools/exporter/exportLib.py b/backend/satellite_tools/exporter/exportLib.py
index 1f3985e..dd8d15e 100644
--- a/backend/satellite_tools/exporter/exportLib.py
+++ b/backend/satellite_tools/exporter/exportLib.py
@@ -1290,25 +1290,13 @@ class ServerGroupTypeServerArchCompatDumper(RestrictedArchCompatDumper):
%s
"""
-class BlacklistObsoletesDumper(BaseQueryDumper):
+class BlacklistObsoletesDumper(BaseDumper):
tag_name = 'rhn-blacklist-obsoletes'
- iterator_query = """
- select pn1.name, pe.epoch, pe.version, pe.release,
- pa.name "package-arch", pn2.name "ignored-name"
- from rhnBlacklistObsoletes bo,
- rhnPackageName pn1, rhnPackageEVR pe, rhnPackageArch pa,
- rhnPackageName pn2
- where bo.name_id = pn1.id
- and bo.evr_id = pe.id
- and bo.package_arch_id = pa.id
- and bo.ignore_name_id = pn2.id
- """
-
- def dump_subelement(self, data):
- if data['epoch'] is None:
- data['epoch'] = ""
- EmptyDumper(self._writer, 'rhn-blacklist-obsolete', data).dump()
-
+ def dump(self):
+ note = """\n<!-- This file is intentionally left empty.
+ Older Satellites and Spacewalks require this file to exist in the dump. -->\n"""
+ self._writer.stream.write(note)
+ self._writer.empty_tag(self.tag_name)
class _KickstartableTreeDumper(BaseRowDumper):
tag_name = 'rhn-kickstartable-tree'
13 years, 1 month
schema/spacewalk
by Michael Mraka
schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql | 3 ---
schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.oracle | 3 +++
schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.postgresql | 4 ++++
3 files changed, 7 insertions(+), 3 deletions(-)
New commits:
commit b881c49e880c0ed44f26fdce88be9d720e88ddd6
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Fri Mar 4 10:50:42 2011 +0100
created postgresql upgrade script for or rhnVirtualization.uuid index
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql b/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql
deleted file mode 100644
index 56d9c7f..0000000
--- a/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql
+++ /dev/null
@@ -1,3 +0,0 @@
-CREATE INDEX rhn_vi_uuid_idx
- ON rhnVirtualInstance (uuid)
- TABLESPACE [[64k_tbs]];
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.oracle b/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.oracle
new file mode 100644
index 0000000..56d9c7f
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.oracle
@@ -0,0 +1,3 @@
+CREATE INDEX rhn_vi_uuid_idx
+ ON rhnVirtualInstance (uuid)
+ TABLESPACE [[64k_tbs]];
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.postgresql b/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.postgresql
new file mode 100644
index 0000000..6910847
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.3-to-spacewalk-schema-1.4/008-rhnVirtualization.sql.postgresql
@@ -0,0 +1,4 @@
+-- oracle equivalent source sha1 8574c7915e5896013dc9c3bce43408ff3a5592e7
+
+CREATE INDEX rhn_vi_uuid_idx
+ ON rhnVirtualInstance (uuid);
13 years, 1 month
java/code
by Jan Pazdziora
java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_pt_BR.xml | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
New commits:
commit 59475fc0a0eca5897d7d85bd2df55e3abc895664
Author: Marcelo Moreira de Mello <mmello(a)redhat.com>
Date: Thu Mar 3 16:21:34 2011 -0300
Fixed pt_BR translations issues at Kickstart Create.
diff --git a/java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_pt_BR.xml b/java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_pt_BR.xml
index e6d99e4..b629299 100644
--- a/java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_pt_BR.xml
+++ b/java/code/src/com/redhat/rhn/frontend/strings/jsp/StringResource_pt_BR.xml
@@ -5544,7 +5544,7 @@ value for this entitlement, excluding the default organization's consumption.</s
<context context-type="sourcefile">/rhn/systems/Proxy</context>
<context context-type="sourcefile">/rhn/systems/@@PRODUCT_NAME@@</context>
</context-group>
- <target>Convidado Virtual</target></trans-unit>
+ <target>Sistema Virtual</target></trans-unit>
<trans-unit id="systemlist.jsp.nonvirt">
<source>Non-Virtual System</source>
@@ -12503,16 +12503,16 @@ o <strong>Guia de Administração de Sistemas Red Hat Enterprise Li
<target>Host de Virtualização Xen</target></trans-unit>
<trans-unit id="kickstart.jsp.virt-type.qemu">
<source>KVM Virtualized Guest</source>
- <target>Convidado de Virtualização KVM</target></trans-unit>
+ <target>Sistema Virtualizado KVM</target></trans-unit>
<trans-unit id="kickstart.jsp.virt-type.none">
<source>None</source>
- <target>Nada</target></trans-unit>
+ <target>Nenhum</target></trans-unit>
<trans-unit id="kickstart.jsp.virt-type.xenfv">
<source>Xen Fully-Virtualized Guest</source>
- <target>Covidado de Virtualização Completa Xen</target></trans-unit>
+ <target>Sistema Full-Virtualizado Xen</target></trans-unit>
<trans-unit id="kickstart.jsp.virt-type.xenpv">
<source>Xen Para-Virtualized Guest</source>
- <target>Convidado de Pára-Virtualização Xen</target></trans-unit>
+ <target>Sistema Para-Virtualizado Xen</target></trans-unit>
</group>
13 years, 1 month
Changes to 'refs/tags/spacecmd-1.4.1-1'
by aparsons
Tag 'spacecmd-1.4.1-1' created by Aron Parsons <aparsons(a)redhat.com> at 2011-03-03 22:47 +0000
Tagging package [spacecmd] version [1.4.1-1] in directory [spacecmd/].
Changes since spacewalk-schema-1.4.7-1:
Aron Parsons (6):
spacecmd: delete child channels first in softwarechannel_delete
spacecmd: ignore channel failures introduced by organizations when caching errata
spacecmd: print a summary list of all errata (name, synopsis, date)
spacecmd: ignore channel failures introduced by organizations when caching packages
spacecmd: log channel access issues in debug mode only
Automatic commit of package [spacecmd] release [1.4.1-1].
Michael Mraka (1):
679109 - localpath must be defined in except block
---
backend/satellite_tools/reposync.py | 3 +
rel-eng/packages/spacecmd | 2 -
spacecmd/spacecmd.spec | 14 +++++++-
spacecmd/src/lib/errata.py | 17 +++++++++-
spacecmd/src/lib/misc.py | 61 ++++++++++++++++++++----------------
spacecmd/src/lib/softwarechannel.py | 15 ++++++++
6 files changed, 81 insertions(+), 31 deletions(-)
---
13 years, 1 month