java/code
by Justin Sherrill
java/code/src/com/redhat/rhn/common/db/datasource/xml/Package_queries.xml | 19 +++
java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/ErrataHandler.java | 48 ----------
java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/test/ErrataHandlerTest.java | 21 ++--
java/code/src/com/redhat/rhn/manager/rhnpackage/PackageManager.java | 17 +++
4 files changed, 50 insertions(+), 55 deletions(-)
New commits:
commit 15d04d2f146546a0ca4fcd1e9bb2224cc824ff47
Author: Justin Sherrill <jsherril(a)redhat.com>
Date: Thu Sep 2 12:05:40 2010 -0400
623447 - speeding up errata.listPackages api call
diff --git a/java/code/src/com/redhat/rhn/common/db/datasource/xml/Package_queries.xml b/java/code/src/com/redhat/rhn/common/db/datasource/xml/Package_queries.xml
index 698f0a8..985a2cd 100644
--- a/java/code/src/com/redhat/rhn/common/db/datasource/xml/Package_queries.xml
+++ b/java/code/src/com/redhat/rhn/common/db/datasource/xml/Package_queries.xml
@@ -1931,4 +1931,23 @@ select distinct p.evr_id as id
</mode>
+<mode name="package_dto_for_errata" class="com.redhat.rhn.frontend.dto.PackageDto">
+ <query params="eid">
+ select P.id, PN.name, evr.version, evr.release, PA.label as arch_label, evr.epoch, C.checksum, CT.label as checksum_type,
+ TO_CHAR(P.last_modified, 'YYYY-MM-DD HH24:MI:SS') AS last_modified
+ from rhnPackage P
+ inner join rhnErrataPackage EP on P.id = EP.package_id
+ inner join rhnPackageEvr evr on P.evr_id = evr.id
+ inner join rhnPackageName pn on P.name_id = PN.id
+ inner join rhnPackageArch PA on PA.id = P.package_arch_id
+ inner join rhnChecksum C on C.id = P.checksum_id
+ inner join rhnChecksumType CT on CT.id = C.CHECKSUM_TYPE_ID
+ where EP.errata_id = :eid
+
+ </query>
+</mode>
+
+
+
+
</datasource_modes>
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/ErrataHandler.java b/java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/ErrataHandler.java
index 41eafea..3ae844e 100644
--- a/java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/ErrataHandler.java
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/ErrataHandler.java
@@ -32,6 +32,7 @@ import com.redhat.rhn.domain.rhnpackage.Package;
import com.redhat.rhn.domain.rhnpackage.PackageFactory;
import com.redhat.rhn.domain.user.User;
import com.redhat.rhn.frontend.dto.CVE;
+import com.redhat.rhn.frontend.dto.PackageDto;
import com.redhat.rhn.frontend.xmlrpc.BaseHandler;
import com.redhat.rhn.frontend.xmlrpc.DuplicateErrataException;
import com.redhat.rhn.frontend.xmlrpc.InvalidAdvisoryReleaseException;
@@ -43,7 +44,6 @@ import com.redhat.rhn.frontend.xmlrpc.MissingErrataAttributeException;
import com.redhat.rhn.frontend.xmlrpc.NoChannelsSelectedException;
import com.redhat.rhn.frontend.xmlrpc.NoSuchChannelException;
import com.redhat.rhn.frontend.xmlrpc.PermissionCheckFailureException;
-import com.redhat.rhn.frontend.xmlrpc.packages.PackageHelper;
import com.redhat.rhn.manager.errata.ErrataManager;
import com.redhat.rhn.manager.errata.cache.ErrataCacheManager;
import com.redhat.rhn.manager.rhnpackage.PackageManager;
@@ -646,55 +646,15 @@ public class ErrataHandler extends BaseHandler {
* @xmlrpc.param #session_key()
* @xmlrpc.param #param("string", "advisoryName")
* @xmlrpc.returntype
- * #array()
- * #struct("package")
- * #prop("int", "id")
- * #prop("string", "name")
- * #prop("string", "epoch")
- * #prop("string", "version")
- * #prop("string", "release")
- * #prop("string", "arch_label")
- * #prop_array("providing_channels", "string", "- Channel label
- * providing this package.")
- * #prop("string", "build_host")
- * #prop("string", "description")
- * #prop("string", "checksum")
- * #prop("string", "vendor")
- * #prop("string", "summary")
- * #prop("string", "cookie")
- * #prop("string", "license")
- * #prop("string", "file")
- * #prop("string", "path")
- * #prop("string", "build_date")
- * #prop("string", "last_modified_date")
- * #prop("string", "size")
- * #prop("string", "payload_size")
- * #struct_end()
- * #array_end()
+ * $PackageDtoSerializer
*/
- public Object[] listPackages(String sessionKey, String advisoryName)
+ public List<PackageDto> listPackages(String sessionKey, String advisoryName)
throws FaultException {
// Get the logged in user
User loggedInUser = getLoggedInUser(sessionKey);
Errata errata = lookupErrata(advisoryName, loggedInUser.getOrg());
- //The set of packages for this erratum
- Set packages = errata.getPackages();
-
- //Main List containing the maps
- List returnList = new ArrayList();
-
- /*
- * Loop through the packages and add each one to the returnList array
- */
- for (Iterator itr = packages.iterator(); itr.hasNext();) {
- Package pkg = (Package) itr.next();
- // fill out a new row containing the package info map
- Map pmap = PackageHelper.packageToMap(pkg, loggedInUser);
- returnList.add(pmap);
- }
-
- return returnList.toArray();
+ return PackageManager.listPackageDtosForErrata(errata);
}
/**
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/test/ErrataHandlerTest.java b/java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/test/ErrataHandlerTest.java
index 26534be..ffad0c0 100644
--- a/java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/test/ErrataHandlerTest.java
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/errata/test/ErrataHandlerTest.java
@@ -29,6 +29,7 @@ import com.redhat.rhn.domain.rhnpackage.PackageEvr;
import com.redhat.rhn.domain.rhnpackage.PackageEvrFactory;
import com.redhat.rhn.domain.rhnpackage.test.PackageTest;
import com.redhat.rhn.domain.user.User;
+import com.redhat.rhn.frontend.dto.PackageDto;
import com.redhat.rhn.frontend.xmlrpc.InvalidAdvisoryReleaseException;
import com.redhat.rhn.frontend.xmlrpc.errata.ErrataHandler;
import com.redhat.rhn.frontend.xmlrpc.test.BaseHandlerTestCase;
@@ -249,16 +250,14 @@ public class ErrataHandlerTest extends BaseHandlerTestCase {
errata.addPackage(p);
ErrataManager.storeErrata(errata);
- Object[] pkgs = handler.listPackages(adminKey, errata.getAdvisory());
+ List<PackageDto> pkgs = handler.listPackages(adminKey, errata.getAdvisory());
assertNotNull(pkgs);
- assertEquals(errata.getPackages().size(), pkgs.length);
- assertTrue(pkgs.length > 0);
+ assertEquals(errata.getPackages().size(), pkgs.size());
+ assertTrue(pkgs.size() > 0);
boolean found = false;
- for (int i = 0; i < pkgs.length; i++) {
- Map pkg = (Map) pkgs[i];
- if (pkg.get("id").equals(p.getId())) {
- assertEquals(p.getBuildHost(), pkg.get("build_host"));
+ for (PackageDto pkg : pkgs) {
+ if (pkg.getId().equals(p.getId())) {
found = true;
}
}
@@ -270,7 +269,7 @@ public class ErrataHandlerTest extends BaseHandlerTestCase {
Errata errata = ErrataFactoryTest.createTestErrata(user.getOrg().getId());
ErrataManager.storeErrata(errata);
- int initialNumPkgs = handler.listPackages(adminKey, errata.getAdvisory()).length;
+ int initialNumPkgs = handler.listPackages(adminKey, errata.getAdvisory()).size();
Package pkg1 = PackageTest.createTestPackage(user.getOrg());
Package pkg2 = PackageTest.createTestPackage(user.getOrg());
@@ -284,7 +283,7 @@ public class ErrataHandlerTest extends BaseHandlerTestCase {
// verify
assertEquals(2, numPkgsAdded);
- int resultNumPkgs = handler.listPackages(adminKey, errata.getAdvisory()).length;
+ int resultNumPkgs = handler.listPackages(adminKey, errata.getAdvisory()).size();
assertEquals(initialNumPkgs + 2, resultNumPkgs);
boolean found1 = false, found2 = false;
@@ -309,7 +308,7 @@ public class ErrataHandlerTest extends BaseHandlerTestCase {
errata.addPackage(pkg2);
ErrataManager.storeErrata(errata);
- int initialNumPkgs = handler.listPackages(adminKey, errata.getAdvisory()).length;
+ int initialNumPkgs = handler.listPackages(adminKey, errata.getAdvisory()).size();
// execute
List<Integer> pkgIds = new ArrayList<Integer>();
@@ -319,7 +318,7 @@ public class ErrataHandlerTest extends BaseHandlerTestCase {
// verify
assertEquals(1, numPkgsRemoved);
- int resultNumPkgs = handler.listPackages(adminKey, errata.getAdvisory()).length;
+ int resultNumPkgs = handler.listPackages(adminKey, errata.getAdvisory()).size();
assertEquals(initialNumPkgs - 1, resultNumPkgs);
boolean found1 = false, found2 = false;
diff --git a/java/code/src/com/redhat/rhn/manager/rhnpackage/PackageManager.java b/java/code/src/com/redhat/rhn/manager/rhnpackage/PackageManager.java
index ce11de0..ed72ab3 100644
--- a/java/code/src/com/redhat/rhn/manager/rhnpackage/PackageManager.java
+++ b/java/code/src/com/redhat/rhn/manager/rhnpackage/PackageManager.java
@@ -40,6 +40,7 @@ import com.redhat.rhn.domain.role.RoleFactory;
import com.redhat.rhn.domain.server.Server;
import com.redhat.rhn.domain.user.User;
import com.redhat.rhn.frontend.dto.PackageComparison;
+import com.redhat.rhn.frontend.dto.PackageDto;
import com.redhat.rhn.frontend.dto.UpgradablePackageListItem;
import com.redhat.rhn.frontend.listview.PageControl;
import com.redhat.rhn.frontend.xmlrpc.PermissionCheckFailureException;
@@ -1460,4 +1461,20 @@ public class PackageManager extends BaseManager {
}
+ /**
+ * List package's for an errata. This was mainly made for the errata xmlrpc handler
+ * was created to be fast.
+ * @param errata the errata
+ * @return list of Packages
+ */
+ public static List<PackageDto> listPackageDtosForErrata(Errata errata) {
+
+ SelectMode m = ModeFactory.getMode("Package_queries", "package_dto_for_errata");
+ Map params = new HashMap();
+ params.put("eid", errata.getId());
+
+ DataResult result = m.execute(params);
+ return result;
+ }
+
}
13 years, 8 months
java/code
by Tomas Lestach
java/code/src/com/redhat/rhn/frontend/xmlrpc/channel/software/ChannelSoftwareHandler.java | 68 ++--------
1 file changed, 19 insertions(+), 49 deletions(-)
New commits:
commit 935d133d9b9fe1122a903691449907b8e4b932c4
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Thu Sep 2 17:05:36 2010 +0200
591291 - do not touch packages in mergeErrata api call
detailed explanation in the BZ
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/channel/software/ChannelSoftwareHandler.java b/java/code/src/com/redhat/rhn/frontend/xmlrpc/channel/software/ChannelSoftwareHandler.java
index 6b5cd8c..030ec78 100644
--- a/java/code/src/com/redhat/rhn/frontend/xmlrpc/channel/software/ChannelSoftwareHandler.java
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/channel/software/ChannelSoftwareHandler.java
@@ -1763,24 +1763,9 @@ public class ChannelSoftwareHandler extends BaseHandler {
throw new PermissionCheckFailureException();
}
- Set<Errata> diffErrata = new HashSet(mergeFrom.getErratas());
-
- // find errata that we do not need to merge
- List<Errata> same = ErrataManager.listSamePublishedInChannels(
- loggedInUser, mergeFrom, mergeTo);
-
- List<Errata> brothers = ErrataManager.listPublishedBrothersInChannels(
- loggedInUser, mergeFrom, mergeTo);
-
- List<Errata> clones = ErrataManager.listPublishedClonesInChannels(
- loggedInUser, mergeFrom, mergeTo);
- // and remove them
- diffErrata.removeAll(same);
- diffErrata.removeAll(brothers);
- diffErrata.removeAll(clones);
-
Set<Errata> mergedErrata =
- mergeErrataToChannel(loggedInUser, diffErrata, mergeTo, mergeFrom);
+ mergeErrataToChannel(loggedInUser, new HashSet(mergeFrom.getErratas()),
+ mergeTo, mergeFrom);
return mergedErrata.toArray();
}
@@ -1824,48 +1809,33 @@ public class ChannelSoftwareHandler extends BaseHandler {
List<Errata> fromErrata = ErrataFactory.lookupByChannelBetweenDates(
loggedInUser.getOrg(), mergeFrom, startDate, endDate);
- Set<Errata> diffErrata = new HashSet(fromErrata);
- // find errata that we do not need to merge
- List<Errata> same = ErrataManager.listSamePublishedInChannels(
- loggedInUser, mergeFrom, mergeTo);
- List<Errata> brothers = ErrataManager.listPublishedBrothersInChannels(
- loggedInUser, mergeFrom, mergeTo);
- List<Errata> clones = ErrataManager.listPublishedClonesInChannels(
- loggedInUser, mergeFrom, mergeTo);
- // and remove them
- diffErrata.removeAll(same);
- diffErrata.removeAll(brothers);
- diffErrata.removeAll(clones);
-
Set<Errata> mergedErrata =
- mergeErrataToChannel(loggedInUser, diffErrata, mergeTo, mergeFrom);
+ mergeErrataToChannel(loggedInUser, new HashSet(fromErrata), mergeTo, mergeFrom);
return mergedErrata.toArray();
}
- private Set<Errata> mergeErrataToChannel(User user, Set<Errata> diffErrata,
+ private Set<Errata> mergeErrataToChannel(User user, Set<Errata> errataToMerge,
Channel toChannel, Channel fromChannel) {
- List<Long> cids = new ArrayList<Long>();
- cids.add(toChannel.getId());
-
- Set<Long> errataIds = getErrataIds(diffErrata);
-
- ErrataManager.publishErrataToChannelAsync(toChannel, errataIds, user);
-
- List errataPkgs = ErrataFactory.listErrataChannelPackages(fromChannel.getId(),
- errataIds);
- List currentChannelPkgs = ChannelFactory.getPackageIds(toChannel.getId());
- errataPkgs.removeAll(currentChannelPkgs);
- ChannelManager.addPackages(toChannel, errataPkgs, user);
+ // find errata that we do not need to merge
+ List<Errata> same = ErrataManager.listSamePublishedInChannels(
+ user, fromChannel, toChannel);
+ List<Errata> brothers = ErrataManager.listPublishedBrothersInChannels(
+ user, fromChannel, toChannel);
+ List<Errata> clones = ErrataManager.listPublishedClonesInChannels(
+ user, fromChannel, toChannel);
+ // and remove them
+ errataToMerge.removeAll(same);
+ errataToMerge.removeAll(brothers);
+ errataToMerge.removeAll(clones);
- ChannelManager.refreshWithNewestPackages(toChannel, "api");
+ ErrataManager.publishErrataToChannelAsync(toChannel,
+ getErrataIds(errataToMerge), user);
- for (Errata e : diffErrata) {
- ErrataCacheManager.insertCacheForChannelErrataAsync(cids, e);
- }
+ // no need to regenerate errata cache, because we didn't touch any packages
- return diffErrata;
+ return errataToMerge;
}
private Set<Long> getErrataIds(Set<Errata> errata) {
13 years, 8 months
Changes to 'refs/tags/spacewalk-schema-1.2.11-1'
by Jan Pazdziora
Tag 'spacewalk-schema-1.2.11-1' created by Jan Pazdziora <jpazdziora(a)redhat.com> at 2010-09-02 14:54 +0000
Tagging package [spacewalk-schema] version [1.2.11-1] in directory [schema/spacewalk/].
Changes since spacewalk-java-1.2.23-1:
Jan Pazdziora (3):
After running the schema upgrade, recompile the PL/SQL objects and check that there are no invalid objects left behind.
Reapply rhn_cache and rhn_org package and rhn_user package and package body, to make for clean schema upgrades from 0.2.
Automatic commit of package [spacewalk-schema] release [1.2.11-1].
Michael Mraka (1):
removed unneeded oracle settings from httpd environment
Tomas Lestach (4):
check only active schedules when checking DB for initialization
add sanity check for predefined tasks
make null checks for cron expressions
add upgrade hint for quartz tables
---
java/code/src/com/redhat/rhn/taskomatic/TaskoQuartzHelper.java | 2
java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java | 16
java/code/src/com/redhat/rhn/taskomatic/TaskoXmlRpcHandler.java | 2
java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java | 3
java/code/src/com/redhat/rhn/taskomatic/serializer/TaskoScheduleSerializer.java | 4
rel-eng/packages/spacewalk-schema | 2
schema/spacewalk/oracle/quartz/tables/qrtz.sql | 2
schema/spacewalk/postgres/quartz/tables/qrtz.sql | 2
schema/spacewalk/spacewalk-schema-upgrade | 17
schema/spacewalk/spacewalk-schema.spec | 9
schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/501-rhn_cache.sql | 45 +
schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/502-rhn_org.sql | 55 +
schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/503-rhn_user.sql | 64 ++
schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/504-rhn_user-body.sql | 308 ++++++++++
spacewalk/config/spacewalk-config.spec | 7
15 files changed, 524 insertions(+), 14 deletions(-)
---
13 years, 8 months
rel-eng/packages schema/spacewalk
by Jan Pazdziora
rel-eng/packages/spacewalk-schema | 2 +-
schema/spacewalk/spacewalk-schema.spec | 9 ++++++++-
2 files changed, 9 insertions(+), 2 deletions(-)
New commits:
commit 1729740503efb1aa828320ba8fcf7c331f81f82b
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Thu Sep 2 16:54:08 2010 +0200
Automatic commit of package [spacewalk-schema] release [1.2.11-1].
diff --git a/rel-eng/packages/spacewalk-schema b/rel-eng/packages/spacewalk-schema
index 01d4a2a..5bbf217 100644
--- a/rel-eng/packages/spacewalk-schema
+++ b/rel-eng/packages/spacewalk-schema
@@ -1 +1 @@
-1.2.10-1 schema/spacewalk/
+1.2.11-1 schema/spacewalk/
diff --git a/schema/spacewalk/spacewalk-schema.spec b/schema/spacewalk/spacewalk-schema.spec
index a4eafd8..6563917 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.2.10
+Version: 1.2.11
Release: 1%{?dist}
Source0: %{name}-%{version}.tar.gz
@@ -59,6 +59,13 @@ rm -rf $RPM_BUILD_ROOT
%{_mandir}/man1/spacewalk-schema-upgrade*
%changelog
+* Thu Sep 02 2010 Jan Pazdziora 1.2.11-1
+- Reapply rhn_cache and rhn_org package and rhn_user package and package body,
+ to make for clean schema upgrades from 0.2.
+- After running the schema upgrade, recompile the PL/SQL objects and check that
+ there are no invalid objects left behind.
+- add upgrade hint for quartz tables (tlestach(a)redhat.com)
+
* Wed Sep 01 2010 Jan Pazdziora 1.2.10-1
- 626741 - do not allow two repos with same label or repository url
13 years, 8 months
schema/spacewalk
by Jan Pazdziora
schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/501-rhn_cache.sql | 45 +
schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/502-rhn_org.sql | 55 +
schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/503-rhn_user.sql | 64 ++
schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/504-rhn_user-body.sql | 308 ++++++++++
4 files changed, 472 insertions(+)
New commits:
commit 8c6d61e1c5889a20cabe2c3a7637300eef9188ac
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Thu Sep 2 16:53:19 2010 +0200
Reapply rhn_cache and rhn_org package and rhn_user package and package body, to make for clean schema upgrades from 0.2.
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/501-rhn_cache.sql b/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/501-rhn_cache.sql
new file mode 100644
index 0000000..8386052
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/501-rhn_cache.sql
@@ -0,0 +1,45 @@
+--
+-- 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 package
+rhn_cache
+is
+ version varchar2(100) := '';
+
+ -- this searches out all users who get perms...
+ procedure update_perms_for_server(
+ server_id_in in number
+ );
+
+ procedure update_perms_for_user(
+ user_id_in in number
+ );
+
+ procedure update_perms_for_server_group(
+ server_group_id_in in number
+ );
+end rhn_cache;
+/
+show errors
+
+--
+--
+-- Revision 1.1 2004/07/02 19:14:32 pjones
+-- 125937 -- tools to manipulate rhnUserServerPerms when appropriate.
+--
+
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/502-rhn_org.sql b/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/502-rhn_org.sql
new file mode 100644
index 0000000..eec5241
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/502-rhn_org.sql
@@ -0,0 +1,55 @@
+--
+-- 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
+PACKAGE rhn_org
+IS
+ version varchar2(100) := '';
+
+ CURSOR server_group_by_label(org_id_in NUMBER, group_label_in VARCHAR2) IS
+ SELECT SG.*
+ FROM rhnServerGroupType SGT,
+ rhnServerGroup SG
+ WHERE SG.group_type = SGT.id
+ AND SGT.label = group_label_in
+ AND SG.org_id = org_id_in;
+
+ FUNCTION find_server_group_by_type(org_id_in NUMBER,
+ group_label_in VARCHAR2)
+ RETURN NUMBER;
+
+ procedure delete_org(org_id_in in number);
+ procedure delete_user(user_id_in in number, deleting_org in number := 0);
+
+END rhn_org;
+/
+SHOW ERRORS
+
+--
+-- Revision 1.7 2004/07/13 22:46:04 pjones
+-- bugzilla: 125938 -- nothing uses update_errata_cache() any more, remove it
+--
+-- Revision 1.6 2004/02/10 15:05:01 pjones
+-- bugzilla: none -- add version tag here
+--
+-- Revision 1.5 2003/02/18 16:35:45 pjones
+-- delete_user
+--
+-- Revision 1.4 2002/05/10 22:08:23 pjones
+-- id/log
+--
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/503-rhn_user.sql b/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/503-rhn_user.sql
new file mode 100644
index 0000000..90199d1
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/503-rhn_user.sql
@@ -0,0 +1,64 @@
+--
+-- 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
+package rhn_user
+is
+ version varchar2(100) := '';
+
+ function check_role(user_id_in in number, role_in in varchar2) return number;
+ PRAGMA RESTRICT_REFERENCES(check_role, WNDS, RNPS, WNPS);
+
+ function check_role_implied(user_id_in in number, role_in in varchar2) return number;
+ PRAGMA RESTRICT_REFERENCES(check_role_implied, WNDS, RNPS, WNPS);
+
+ function get_org_id(user_id_in in number) return number;
+ PRAGMA RESTRICT_REFERENCES(get_org_id, WNDS, RNPS, WNPS);
+
+ function find_mailable_address(user_id_in in number) return varchar2;
+
+ procedure add_servergroup_perm(
+ user_id_in in number,
+ server_group_id_in in number
+ );
+
+ procedure remove_servergroup_perm(
+ user_id_in in number,
+ server_group_id_in in number
+ );
+
+ procedure add_to_usergroup(
+ user_id_in in number,
+ user_group_id_in in number
+ );
+
+ procedure add_users_to_usergroups(
+ user_id_in in number
+ );
+
+ procedure remove_from_usergroup(
+ user_id_in in number,
+ user_group_id_in in number
+ );
+
+ procedure remove_users_from_servergroups(
+ user_id_in in number
+ );
+end rhn_user;
+/
+SHOW ERRORS
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/504-rhn_user-body.sql b/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/504-rhn_user-body.sql
new file mode 100644
index 0000000..8ccf09f
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.1-to-spacewalk-schema-1.2/504-rhn_user-body.sql
@@ -0,0 +1,308 @@
+--
+-- 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
+package body rhn_user
+is
+ body_version varchar2(100) := '';
+
+ function check_role(user_id_in in number, role_in in varchar2)
+ return number
+ is
+ throwaway number;
+ begin
+ -- the idea: if we get past this query, the org has the setting, else catch the exception and return 0
+ select 1 into throwaway
+ from rhnUserGroupType UGT,
+ rhnUserGroup UG,
+ rhnUserGroupMembers UGM
+ where UGM.user_id = user_id_in
+ and UGM.user_group_id = UG.id
+ and UG.group_type = UGT.id
+ and UGT.label = role_in;
+
+ return 1;
+ exception
+ when no_data_found
+ then
+ return 0;
+ end check_role;
+
+ function check_role_implied(user_id_in in number, role_in in varchar2)
+ return number
+ is
+ throwaway number;
+ begin
+ -- if the user directly has the role, they win
+ if rhn_user.check_role(user_id_in, role_in) = 1
+ then
+ return 1;
+ end if;
+
+ -- config_admin and channel_admin are automatically implied for org admins
+ if role_in = 'config_admin' and rhn_user.check_role(user_id_in, 'org_admin') = 1
+ then
+ return 1;
+ end if;
+
+ if role_in = 'channel_admin' and rhn_user.check_role(user_id_in, 'org_admin') = 1
+ then
+ return 1;
+ end if;
+
+ return 0;
+ end check_role_implied;
+
+ function get_org_id(user_id_in in number)
+ return number
+ is
+ org_id_out number;
+ begin
+ select org_id into org_id_out
+ from web_contact
+ where id = user_id_in;
+
+ return org_id_out;
+ end get_org_id;
+
+ -- paid users often don't have verified email addresses, so
+ -- try to find an address that is useful to us.
+ function find_mailable_address(user_id_in in number)
+ return varchar2 is
+ PRAGMA AUTONOMOUS_TRANSACTION;
+ -- this would be so much prettier if we just had an order built
+ -- into rhnEmailAddressState
+ cursor addrs is
+ select ea.state_id, ea.address
+ from rhnEmailAddressState eas,
+ rhnEmailAddress ea
+ where ea.user_id = user_id_in
+ and eas.label = 'verified'
+ and ea.state_id = eas.id
+ union all
+ select ea.state_id, ea.address
+ from rhnEmailAddressState eas,
+ rhnEmailAddress ea
+ where ea.user_id = user_id_in
+ and eas.label = 'unverified'
+ and ea.state_id = eas.id
+ union all
+ select ea.state_id, ea.address
+ from rhnEmailAddressState eas,
+ rhnEmailAddress ea
+ where ea.user_id = user_id_in
+ and eas.label = 'pending'
+ and ea.state_id = eas.id
+ union all
+ select ea.state_id, ea.address
+ from rhnEmailAddressState eas,
+ rhnEmailAddress ea
+ where ea.user_id = user_id_in
+ and eas.label = 'pending_warned'
+ and ea.state_id = eas.id
+ union all
+ select ea.state_id, ea.address
+ from rhnEmailAddressState eas,
+ rhnEmailAddress ea
+ where ea.user_id = user_id_in
+ and eas.label = 'needs_verifying'
+ and ea.state_id = eas.id
+ union all
+ select -1 state_id,
+ email address
+ from web_user_personal_info
+ where web_user_id = user_id_in;
+ retval rhnEmailAddress.address%TYPE;
+ begin
+ for addr in addrs loop
+ retval := addr.address;
+ if addr.address is null then
+ update web_user_contact_permission
+ set email = 'N'
+ where web_user_id = user_id_in;
+ commit;
+ return null;
+ end if;
+ if addr.state_id = -1 then
+ insert into rhnEmailAddress (
+ id, address,
+ user_id, state_id
+ ) (
+ select rhn_eaddress_id_seq.nextval, addr.address,
+ user_id_in, eas.id
+ from rhnEmailAddressState eas
+ where eas.label = 'unverified'
+ );
+ end if;
+ commit;
+ return retval;
+ end loop;
+ return null;
+ end;
+
+ procedure add_servergroup_perm(
+ user_id_in in number,
+ server_group_id_in in number
+ ) is
+ cursor orgs_match is
+ select 1
+ from rhnServerGroup sg,
+ web_contact u
+ where u.id = user_id_in
+ and sg.id = server_group_id_in
+ and sg.org_id = u.org_id;
+ begin
+ for okay in orgs_match loop
+ insert into rhnUserServerGroupPerms(user_id, server_group_id)
+ values (user_id_in, server_group_id_in);
+ rhn_cache.update_perms_for_user(user_id_in);
+ return;
+ end loop;
+ rhn_exception.raise_exception('usgp_different_orgs');
+ exception when dup_val_on_index then
+ rhn_exception.raise_exception('usgp_already_allowed');
+ end add_servergroup_perm;
+
+ procedure remove_servergroup_perm(
+ user_id_in in number,
+ server_group_id_in in number
+ ) is
+ cursor perms is
+ select 1
+ from rhnUserServerGroupPerms
+ where user_id = user_id_in
+ and server_group_id = server_group_id_in;
+ begin
+ for perm in perms loop
+ delete from rhnUserServerGroupPerms
+ where user_id = user_id_in
+ and server_group_id = server_group_id_in;
+ rhn_cache.update_perms_for_user(user_id_in);
+ return;
+ end loop;
+ rhn_exception.raise_exception('usgp_not_allowed');
+ end remove_servergroup_perm;
+
+ procedure add_to_usergroup(
+ user_id_in in number,
+ user_group_id_in in number
+ ) is
+ cursor perm_granting_usergroups is
+ select user_group_id_in
+ from rhnUserGroup ug,
+ rhnUserGroupType ugt
+ where ugt.label in ('org_admin') -- and server_group_admin ?
+ and ug.id = user_group_id_in
+ and ug.group_type = ugt.id;
+ begin
+ insert into rhnUserGroupMembers(user_id, user_group_id)
+ values (user_id_in, user_group_id_in);
+
+ for ug in perm_granting_usergroups loop
+ rhn_cache.update_perms_for_user(user_id_in);
+ return;
+ end loop;
+ end add_to_usergroup;
+
+ procedure add_users_to_usergroups(
+ user_id_in in number
+ ) is
+ cursor ugms is
+ select element user_id,
+ element_two user_group_id
+ from rhnSet
+ where user_id = user_id_in
+ and label = 'user_group_list';
+ begin
+ for ugm in ugms loop
+ rhn_user.add_to_usergroup(ugm.user_id, ugm.user_group_id);
+ end loop;
+ end add_users_to_usergroups;
+
+ procedure remove_from_usergroup(
+ user_id_in in number,
+ user_group_id_in in number
+ ) is
+ cursor perm_granting_usergroups is
+ select label
+ from rhnUserGroupType ugt,
+ rhnUserGroupMembers ugm,
+ rhnUserGroup ug
+ where 1=1
+ and ug.id = user_group_id_in
+ and ugm.user_group_id = user_group_id_in
+ and ug.group_type = ugt.id
+ and ugm.user_id = user_id_in;
+ begin
+ -- we only do anything if you're really in the group, because
+ -- testing is significantly cheaper than rebuilding the user's
+ -- cache for no reason.
+ for ug in perm_granting_usergroups loop
+ delete from rhnUserGroupMembers
+ where user_id = user_id_in
+ and user_group_id = user_group_id_in;
+ if ug.label in ('org_admin') then
+ rhn_cache.update_perms_for_user(user_id_in);
+ end if;
+ end loop;
+ end remove_from_usergroup;
+
+ procedure remove_users_from_servergroups(
+ user_id_in in number
+ ) is
+ cursor ugms is
+ select element user_id,
+ element_two user_group_id
+ from rhnSet
+ where user_id = user_id_in
+ and label = 'user_group_list';
+ begin
+ for ugm in ugms loop
+ rhn_user.remove_from_usergroup(ugm.user_id, ugm.user_group_id);
+ end loop;
+ end remove_users_from_servergroups;
+end rhn_user;
+/
+SHOW ERRORS
+
+-- select rhn_user.get_org_id(502474) from dual;
+-- 1271287
+-- select rhn_user.check_role(502474, 'org_admin') from dual;
+-- 1
+-- select rhn_user.check_role(502474, 'org_admin_nope') from dual;
+-- 0, but should later raise an exception
+
+--
+--
+-- Revision 1.8 2004/07/12 19:35:51 pjones
+-- bugzilla: 125937 -- we _always_ delete, but only rebuild cache on org_admin.
+--
+-- Revision 1.7 2004/07/02 22:29:36 pjones
+-- bugzilla: none -- typos and spelling errors.
+--
+-- Revision 1.6 2004/07/02 19:16:54 pjones
+-- bugzilla: 125937 -- tools to manipulate rhnServerGroupMembers and
+-- rhnUserGroupMembers
+--
+-- Revision 1.5 2004/03/31 21:09:47 pjones
+-- bugzilla: none -- if the user truly doesn't have any email address, compensate.
+--
+-- Revision 1.4 2004/02/12 20:53:30 pjones
+-- bugzilla: 108212 -- s/get_email_address/find_mailable_address/ and make it
+-- do the same as web's version
+--
13 years, 8 months
schema/spacewalk
by Jan Pazdziora
schema/spacewalk/spacewalk-schema-upgrade | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
New commits:
commit f7ec4688236a39e789f48460920f53273c3292c9
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Thu Sep 2 16:32:54 2010 +0200
After running the schema upgrade, recompile the PL/SQL objects and check that there are no invalid objects left behind.
diff --git a/schema/spacewalk/spacewalk-schema-upgrade b/schema/spacewalk/spacewalk-schema-upgrade
index ff6a7b0..937e3f6 100755
--- a/schema/spacewalk/spacewalk-schema-upgrade
+++ b/schema/spacewalk/spacewalk-schema-upgrade
@@ -220,6 +220,23 @@ $in .= <<EOF;
spool $SCHEMA_UPGRADE_LOGDIR/$stamp-end.log append
whenever sqlerror exit sql.sqlcode
+exec dbms_utility.compile_schema(user);
+
+-- check whether all objects are valid
+declare
+ invalid_objects number;
+begin
+ select count(*)
+ into invalid_objects
+ from user_objects
+ where status <> 'VALID' and
+ (object_name, object_type) not in (select object_name, type from recyclebin);
+ if invalid_objects > 0 then
+ RAISE_APPLICATION_ERROR(-20001, 'SCHEMA UPGRADE ENDS WITH INVALD OBJECTS');
+ end if;
+end;
+/
+
insert into rhnVersionInfo
( label, name_id, evr_id, created, modified )
values ('schema', lookup_package_name('$my_schema_name'),
13 years, 8 months
4 commits - java/code schema/spacewalk
by Tomas Lestach
java/code/src/com/redhat/rhn/taskomatic/TaskoQuartzHelper.java | 2 -
java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java | 16 +++++++++-
java/code/src/com/redhat/rhn/taskomatic/TaskoXmlRpcHandler.java | 2 -
java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java | 3 +
java/code/src/com/redhat/rhn/taskomatic/serializer/TaskoScheduleSerializer.java | 4 +-
schema/spacewalk/oracle/quartz/tables/qrtz.sql | 2 +
schema/spacewalk/postgres/quartz/tables/qrtz.sql | 2 +
7 files changed, 26 insertions(+), 5 deletions(-)
New commits:
commit 063a73ab8941f6ebc7b009727444682db3e3994f
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Thu Sep 2 11:26:52 2010 +0200
add upgrade hint for quartz tables
diff --git a/schema/spacewalk/oracle/quartz/tables/qrtz.sql b/schema/spacewalk/oracle/quartz/tables/qrtz.sql
index 6fbd8ea..c6ffe6b 100644
--- a/schema/spacewalk/oracle/quartz/tables/qrtz.sql
+++ b/schema/spacewalk/oracle/quartz/tables/qrtz.sql
@@ -7,6 +7,8 @@
-- Many other users (including the primary author of Quartz) have had success
-- runing in dedicated mode, so only consider the above as a hint ;-)
--
+-- MAKE SURE ANY QUARTZ UPGRADES ARE DONE IN A WAY - DROP ALL & CREATE ALL
+-- (our schema differ skips checking quartz constrains because of missing contraint names)
CREATE TABLE qrtz_job_details
(
diff --git a/schema/spacewalk/postgres/quartz/tables/qrtz.sql b/schema/spacewalk/postgres/quartz/tables/qrtz.sql
index 5d781c1..c74c8fa 100644
--- a/schema/spacewalk/postgres/quartz/tables/qrtz.sql
+++ b/schema/spacewalk/postgres/quartz/tables/qrtz.sql
@@ -2,6 +2,8 @@
--
-- In your Quartz properties file, you'll need to set
-- org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.PostgreSQLDelegate
+-- MAKE SURE ANY QUARTZ UPGRADES ARE DONE IN A WAY - DROP ALL & CREATE ALL
+-- (our schema differ skips checking quartz constrains because of missing contraint names)
CREATE TABLE qrtz_job_details
(
commit 016b2e65317419c83e2ee97240dbf8a7fd7886da
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed Sep 1 16:51:42 2010 +0200
make null checks for cron expressions
just in case somebody creates a single schedule DB entry
diff --git a/java/code/src/com/redhat/rhn/taskomatic/TaskoQuartzHelper.java b/java/code/src/com/redhat/rhn/taskomatic/TaskoQuartzHelper.java
index d9ae5a4..cebb115 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/TaskoQuartzHelper.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/TaskoQuartzHelper.java
@@ -65,7 +65,7 @@ public class TaskoQuartzHelper {
public static Date createJob(TaskoSchedule schedule) throws InvalidParamException {
// create trigger
Trigger trigger = null;
- if (schedule.getCronExpr().isEmpty()) {
+ if ((schedule.getCronExpr() == null) || (schedule.getCronExpr().isEmpty())) {
trigger = new SimpleTrigger(schedule.getJobLabel(),
getGroupName(schedule.getOrgId()), 1, 1);
trigger.setEndTime(new Date());
diff --git a/java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java b/java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java
index 845033b..be8609e 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java
@@ -78,7 +78,7 @@ public class TaskoSchedule {
else {
setActiveFrom(activeFromIn);
}
- if (cronExprIn.isEmpty()) {
+ if ((cronExprIn == null) || (cronExprIn.isEmpty())) {
// set activeFrom for single runs
setActiveTill(getActiveFrom());
}
diff --git a/java/code/src/com/redhat/rhn/taskomatic/TaskoXmlRpcHandler.java b/java/code/src/com/redhat/rhn/taskomatic/TaskoXmlRpcHandler.java
index 427cf55..200a2dd 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/TaskoXmlRpcHandler.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/TaskoXmlRpcHandler.java
@@ -236,7 +236,7 @@ public class TaskoXmlRpcHandler {
// create schedule
TaskoSchedule schedule = null;
schedule = new TaskoSchedule(orgId, bunch, jobLabel, params,
- start, null, "");
+ start, null, null);
TaskoFactory.save(schedule);
// create job
Date scheduleDate = TaskoQuartzHelper.createJob(schedule);
diff --git a/java/code/src/com/redhat/rhn/taskomatic/serializer/TaskoScheduleSerializer.java b/java/code/src/com/redhat/rhn/taskomatic/serializer/TaskoScheduleSerializer.java
index 8ff303b..0c57d53 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/serializer/TaskoScheduleSerializer.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/serializer/TaskoScheduleSerializer.java
@@ -55,7 +55,9 @@ public class TaskoScheduleSerializer implements XmlRpcCustomSerializer {
helper.add("bunch", schedule.getBunch().getName());
helper.add("active_from", schedule.getActiveFrom());
helper.add("active_till", schedule.getActiveTill());
- helper.add("cron_expr", schedule.getCronExpr());
+ if (schedule.getCronExpr() != null) {
+ helper.add("cron_expr", schedule.getCronExpr());
+ }
Map dataMap = schedule.getDataMap();
if (dataMap == null) {
dataMap = new HashMap();
commit 8b5801a5ecaf347401f37be48c33454af2bbc663
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Thu Sep 2 10:50:44 2010 +0200
add sanity check for predefined tasks
not used at the moment, but who knows what comes :-)
diff --git a/java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java b/java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java
index c909c1f..845033b 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/TaskoSchedule.java
@@ -88,6 +88,20 @@ public class TaskoSchedule {
}
/**
+ * sanity check for predefined schedules
+ * (defined directly in the DB)
+ */
+ public void sanityCheckForPredefinedSchedules() {
+ if (getActiveTill() == null) {
+ if ((cronExpr == null) || (cronExpr.isEmpty())) {
+ // set activeTill for single runs
+ setActiveTill(new Date());
+ TaskoFactory.commitTransaction();
+ }
+ }
+ }
+
+ /**
* unschedule this particular schedule
*/
public void unschedule() {
diff --git a/java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java b/java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java
index cfed185..b4970bc 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java
@@ -196,6 +196,7 @@ public class SchedulerKernel {
this.scheduler.getJobNames(TaskoQuartzHelper.getGroupName(null)));
for (TaskoSchedule schedule : TaskoFactory.listActiveSchedulesByOrg(null)) {
if (!jobNames.contains(schedule.getJobLabel())) {
+ schedule.sanityCheckForPredefinedSchedules();
TaskoQuartzHelper.createJob(schedule);
}
}
commit 654a48d93c04adcce9a30fa93b9f3dda01f51196
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed Sep 1 16:49:25 2010 +0200
check only active schedules when checking DB for initialization
diff --git a/java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java b/java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java
index 7389ccf..cfed185 100644
--- a/java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java
+++ b/java/code/src/com/redhat/rhn/taskomatic/core/SchedulerKernel.java
@@ -194,7 +194,7 @@ public class SchedulerKernel {
try {
jobNames = Arrays.asList(
this.scheduler.getJobNames(TaskoQuartzHelper.getGroupName(null)));
- for (TaskoSchedule schedule : TaskoFactory.listSchedulesByOrg(null)) {
+ for (TaskoSchedule schedule : TaskoFactory.listActiveSchedulesByOrg(null)) {
if (!jobNames.contains(schedule.getJobLabel())) {
TaskoQuartzHelper.createJob(schedule);
}
13 years, 8 months
spacewalk/config
by Michael Mraka
spacewalk/config/spacewalk-config.spec | 7 -------
1 file changed, 7 deletions(-)
New commits:
commit 03ac8926e35fb86e95e3fd1edc0d41652e18e7f4
Author: Michael Mraka <michael.mraka(a)redhat.com>
Date: Thu Sep 2 09:25:13 2010 +0200
removed unneeded oracle settings from httpd environment
we set it in sub compenents
diff --git a/spacewalk/config/spacewalk-config.spec b/spacewalk/config/spacewalk-config.spec
index 3c5673a..8474f6f 100644
--- a/spacewalk/config/spacewalk-config.spec
+++ b/spacewalk/config/spacewalk-config.spec
@@ -89,13 +89,6 @@ if [ -f /etc/init.d/satellite-httpd ] ; then
fi
-%post
-
-cat >> %{_sysconfdir}/sysconfig/httpd <<EOF
-export ORACLE_HOME=/opt/oracle
-export NLS_LANG=english.AL32UTF8
-EOF
-
%changelog
* Wed Sep 01 2010 Jan Pazdziora 1.2.1-1
13 years, 8 months
Changes to 'refs/tags/spacewalk-java-1.2.23-1'
by Partha Aji
Tag 'spacewalk-java-1.2.23-1' created by Partha Aji <paji(a)redhat.com> at 2010-09-01 23:29 +0000
Tagging package [spacewalk-java] version [1.2.23-1] in directory [java/].
Changes since spacewalk-search-1.2.2-1:
Partha Aji (1):
Automatic commit of package [spacewalk-java] release [1.2.23-1].
---
java/spacewalk-java.spec | 11 ++++++++++-
rel-eng/packages/spacewalk-java | 2 +-
2 files changed, 11 insertions(+), 2 deletions(-)
---
13 years, 8 months
java/spacewalk-java.spec rel-eng/packages
by Partha Aji
java/spacewalk-java.spec | 11 ++++++++++-
rel-eng/packages/spacewalk-java | 2 +-
2 files changed, 11 insertions(+), 2 deletions(-)
New commits:
commit 3749e714c80434d9035bc9a525f2998eb558fa7d
Author: Partha Aji <paji(a)redhat.com>
Date: Wed Sep 1 19:29:22 2010 -0400
Automatic commit of package [spacewalk-java] release [1.2.23-1].
diff --git a/java/spacewalk-java.spec b/java/spacewalk-java.spec
index 8863d65..f1bb01b 100644
--- a/java/spacewalk-java.spec
+++ b/java/spacewalk-java.spec
@@ -19,7 +19,7 @@ Name: spacewalk-java
Summary: Spacewalk Java site packages
Group: Applications/Internet
License: GPLv2
-Version: 1.2.22
+Version: 1.2.23
Release: 1%{?dist}
URL: https://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
@@ -336,6 +336,15 @@ fi
%{jardir}/postgresql-jdbc.jar
%changelog
+* Wed Sep 01 2010 Partha Aji <paji(a)redhat.com> 1.2.23-1
+- 518664 - Made spacewalk search deal with other locales (paji(a)redhat.com)
+- checkstyle fix (jsherril(a)redhat.com)
+- 616570 - adding support for looking up debuginfo rpms if they are located on
+ the satellite itself (jsherril(a)redhat.com)
+- fixing kickstart %post script logging to actually work and not break
+ kickstarts (jsherril(a)redhat.com)
+- fix ClearLogHistory (tlestach(a)redhat.com)
+
* Wed Sep 01 2010 Tomas Lestach <tlestach(a)redhat.com> 1.2.22-1
- 627905 - taskomatic requires jakarta-commons-dbcp (tlestach(a)redhat.com)
diff --git a/rel-eng/packages/spacewalk-java b/rel-eng/packages/spacewalk-java
index c734fce..ba32cf0 100644
--- a/rel-eng/packages/spacewalk-java
+++ b/rel-eng/packages/spacewalk-java
@@ -1 +1 @@
-1.2.22-1 java/
+1.2.23-1 java/
13 years, 8 months