java/spacewalk-java.spec rel-eng/packages
by Tomas Lestach
java/spacewalk-java.spec | 12 +++++++++++-
rel-eng/packages/spacewalk-java | 2 +-
2 files changed, 12 insertions(+), 2 deletions(-)
New commits:
commit 14edf50ba725fe4f6338e391122d9758376b8b50
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Thu Apr 29 13:05:49 2010 +0200
Automatic commit of package [spacewalk-java] release [1.1.8-1].
diff --git a/java/spacewalk-java.spec b/java/spacewalk-java.spec
index 59ac969..3a3aaae 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.1.7
+Version: 1.1.8
Release: 1%{?dist}
URL: https://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
@@ -310,6 +310,16 @@ fi
%{jardir}/postgresql-jdbc.jar
%changelog
+* Thu Apr 29 2010 Tomas Lestach <tlestach(a)redhat.com> 1.1.8-1
+- introducing DistChannelHandler (tlestach(a)redhat.com)
+- add 2 new DistChannelMap related queries with appropriate methods
+ (tlestach(a)redhat.com)
+- rename {lookup,find}ByOsReleaseAndChannelArch ->
+ ByProductNameReleaseAndChannelArch (tlestach(a)redhat.com)
+- Added all the javascript macgic needed to show and hide stuff
+ (paji(a)redhat.com)
+- Fixed a Compile typo to work with 1.5 compiler (paji(a)redhat.com)
+
* Wed Apr 28 2010 Jan Pazdziora 1.1.7-1
- Added new expandable and non-expandable columns. Also UI improvements
(paji(a)redhat.com)
diff --git a/rel-eng/packages/spacewalk-java b/rel-eng/packages/spacewalk-java
index 137eef9..5f0df26 100644
--- a/rel-eng/packages/spacewalk-java
+++ b/rel-eng/packages/spacewalk-java
@@ -1 +1 @@
-1.1.7-1 java/
+1.1.8-1 java/
13 years, 11 months
3 commits - java/code
by Tomas Lestach
java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java | 65 ++++-
java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml | 30 +-
java/code/src/com/redhat/rhn/frontend/action/channel/ssm/BaseSubscribeAction.java | 3
java/code/src/com/redhat/rhn/frontend/xmlrpc/NoSuchDistChannelMapException.java | 36 ++
java/code/src/com/redhat/rhn/frontend/xmlrpc/distchannel/DistChannelHandler.java | 121 ++++++++++
java/code/src/com/redhat/rhn/frontend/xmlrpc/handler-manifest.xml | 1
java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/DistChannelMapSerializer.java | 65 +++++
java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/SerializerRegistry.java | 1
java/code/src/com/redhat/rhn/manager/channel/ChannelManager.java | 12
java/code/src/com/redhat/rhn/manager/channel/test/ChannelManagerTest.java | 4
10 files changed, 313 insertions(+), 25 deletions(-)
New commits:
commit f5826bcf1582d57bf866b01ec576e51a1ab58335
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed Apr 28 20:46:31 2010 +0200
introducing DistChannelHandler
diff --git a/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java b/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
index f082bad..5fbc56b 100644
--- a/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
+++ b/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
@@ -161,7 +161,14 @@ public class ChannelFactory extends HibernateFactory {
singleton.saveObject(c);
}
-
+ /**
+ * Insert or Update a DistChannelMap.
+ * @param dcm DistChannelMap to be stored in database.
+ */
+ public static void save(DistChannelMap dcm) {
+ singleton.saveObject(dcm);
+ }
+
/**
* Remove a Channel from the DB
* @param c Action to be removed from database.
@@ -180,7 +187,15 @@ public class ChannelFactory extends HibernateFactory {
m.execute(inParams, new HashMap());
}
-
+
+ /**
+ * Remove a DistChannelMap from the DB
+ * @param dcm Action to be removed from database.
+ */
+ public static void remove(DistChannelMap dcm) {
+ singleton.removeObject(dcm);
+ }
+
/**
* Returns the base channel for the given server id.
* @param sid Server id whose base channel we want.
diff --git a/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml b/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
index 5bec984..0c254e5 100644
--- a/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
+++ b/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
@@ -5,12 +5,8 @@ PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
<hibernate-mapping>
<class name="com.redhat.rhn.domain.channel.DistChannelMap"
table="rhnDistChannelMap">
- <composite-id>
- <key-many-to-one name="channel"
- class="com.redhat.rhn.domain.channel.Channel"
- column="channel_id"/>
-
+ <composite-id>
<key-property name="os" column="os" type="string"
length="64"/>
<key-property name="release" column="release" type="string"
@@ -21,6 +17,10 @@ PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
column="channel_arch_id"/>
</composite-id>
+
+ <many-to-one name="channel"
+ class="com.redhat.rhn.domain.channel.Channel"
+ column="channel_id" />
</class>
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/NoSuchDistChannelMapException.java b/java/code/src/com/redhat/rhn/frontend/xmlrpc/NoSuchDistChannelMapException.java
new file mode 100644
index 0000000..04f1cdb
--- /dev/null
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/NoSuchDistChannelMapException.java
@@ -0,0 +1,36 @@
+/**
+ * Copyright (c) 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.
+ */
+package com.redhat.rhn.frontend.xmlrpc;
+
+import com.redhat.rhn.FaultException;
+
+/**
+ * NoSuchDistChannelMapException
+ */
+public class NoSuchDistChannelMapException extends FaultException {
+
+ /**
+ * Comment for <code>serialVersionUID</code>
+ */
+ private static final long serialVersionUID = 5943788841375288144L;
+
+
+ /**
+ * Constructor
+ */
+ public NoSuchDistChannelMapException() {
+ super(-215 , "noSuchDistChannelMap" , "No such dist channel map");
+ }
+}
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/distchannel/DistChannelHandler.java b/java/code/src/com/redhat/rhn/frontend/xmlrpc/distchannel/DistChannelHandler.java
new file mode 100644
index 0000000..c75b2f3
--- /dev/null
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/distchannel/DistChannelHandler.java
@@ -0,0 +1,121 @@
+/**
+ * Copyright (c) 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.
+ */
+package com.redhat.rhn.frontend.xmlrpc.distchannel;
+
+import com.redhat.rhn.common.security.PermissionException;
+import com.redhat.rhn.domain.channel.Channel;
+import com.redhat.rhn.domain.channel.ChannelArch;
+import com.redhat.rhn.domain.channel.ChannelFactory;
+import com.redhat.rhn.domain.channel.DistChannelMap;
+import com.redhat.rhn.domain.role.RoleFactory;
+import com.redhat.rhn.domain.user.User;
+import com.redhat.rhn.frontend.xmlrpc.BaseHandler;
+import com.redhat.rhn.frontend.xmlrpc.InvalidChannelArchException;
+import com.redhat.rhn.frontend.xmlrpc.NoSuchChannelException;
+import com.redhat.rhn.frontend.xmlrpc.NoSuchDistChannelMapException;
+
+/**
+ * DistChannelHandler - provides methods to access distribution channel information.
+ * @version $Rev$
+ * @xmlrpc.namespace distchannel
+ * @xmlrpc.doc Provides methods to access and modify distribution channel information
+ */
+public class DistChannelHandler extends BaseHandler {
+
+ /**
+ * Lists the default distribution channel maps defined per satellite
+ * @param sessionKey The sessionKey containing the logged in user
+ * @return List of dist channel maps
+ *
+ * @xmlrpc.doc Lists the default distribution channel maps defined per satellite
+ * @xmlrpc.param #session_key()
+ * @xmlrpc.returntype
+ * #array("dist channel map")
+ * @DistChannelMapSerializer
+ * #array_end()
+ */
+ public Object[] listDefaultMaps(String sessionKey) {
+ return ChannelFactory.listAllDistChannelMaps().toArray();
+ }
+
+ /**
+ * Sets (/removes if channelLabel empty) a default distribution channel map
+ * @param sessionKey The sessionKey containing the logged in user
+ * @param os OS
+ * @param release Relase
+ * @param archLabel architecture label
+ * @param channelLabel channel label
+ * @return Returns 1 if successful, exception otherwise
+ *
+ * @xmlrpc.doc Sets (/removes if channelLabel empty) a default distribution channel map
+ * @xmlrpc.param #session_key()
+ * @xmlrpc.param #param("string", "os")
+ * @xmlrpc.param #param("string", "release")
+ * @xmlrpc.param #param("string", "archLabel")
+ * @xmlrpc.param #param("string", "channelLabel")
+ * @xmlrpc.returntype #return_int_success()
+ */
+ public int setDefaultMap(String sessionKey, String os, String release,
+ String archLabel, String channelLabel) {
+ User loggedInUser = getLoggedInUser(sessionKey);
+ if (!loggedInUser.hasRole(RoleFactory.SAT_ADMIN)) {
+ throw new PermissionException(RoleFactory.SAT_ADMIN);
+ }
+
+ ChannelArch channelArch = ChannelFactory.lookupArchByName(archLabel);
+ if (channelArch == null) {
+ throw new InvalidChannelArchException(archLabel);
+ }
+ DistChannelMap dcm = ChannelFactory.lookupDistChannelMapByOsReleaseArch(os,
+ release, channelArch);
+ if ((dcm != null) && (dcm.getChannel().getProductName() != null)) {
+ throw new PermissionException("It's not possible to change " +
+ dcm.getChannel().getProductName().getName() + " channel maps.");
+ }
+
+ if (channelLabel.isEmpty()) {
+ // remove dist channel map
+ if (dcm != null) {
+ ChannelFactory.remove(dcm);
+ }
+ else {
+ throw new NoSuchDistChannelMapException();
+ }
+ }
+ else {
+ Channel channel = ChannelFactory.lookupByLabel(channelLabel);
+ if (channel == null) {
+ throw new NoSuchChannelException();
+ }
+
+ if (dcm != null) {
+ // update channel map
+ dcm.setChannel(channel);
+ ChannelFactory.save(dcm);
+ }
+ else {
+ // create new channel map
+ dcm = new DistChannelMap();
+ dcm.setOs(os);
+ dcm.setRelease(release);
+ dcm.setChannelArch(channelArch);
+ dcm.setChannel(channel);
+ ChannelFactory.save(dcm);
+ }
+ }
+
+ return 1;
+ }
+}
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/handler-manifest.xml b/java/code/src/com/redhat/rhn/frontend/xmlrpc/handler-manifest.xml
index 54ffbfb..0c945b1 100644
--- a/java/code/src/com/redhat/rhn/frontend/xmlrpc/handler-manifest.xml
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/handler-manifest.xml
@@ -34,4 +34,5 @@
<template name="org" classname="com.redhat.rhn.frontend.xmlrpc.org.OrgHandler" />
<template name="org.trusts" classname="com.redhat.rhn.frontend.xmlrpc.org.trusts.OrgTrustHandler" />
<template name="schedule" classname="com.redhat.rhn.frontend.xmlrpc.schedule.ScheduleHandler" />
+ <template name="distchannel" classname="com.redhat.rhn.frontend.xmlrpc.distchannel.DistChannelHandler" />
</factory>
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/DistChannelMapSerializer.java b/java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/DistChannelMapSerializer.java
new file mode 100644
index 0000000..a6db62d
--- /dev/null
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/DistChannelMapSerializer.java
@@ -0,0 +1,65 @@
+/**
+ * Copyright (c) 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.
+ */
+package com.redhat.rhn.frontend.xmlrpc.serializer;
+
+import com.redhat.rhn.domain.channel.DistChannelMap;
+import com.redhat.rhn.frontend.xmlrpc.serializer.util.SerializerHelper;
+
+import java.io.IOException;
+import java.io.Writer;
+
+import redstone.xmlrpc.XmlRpcCustomSerializer;
+import redstone.xmlrpc.XmlRpcException;
+import redstone.xmlrpc.XmlRpcSerializer;
+
+/**
+ *
+ * DistChannelMapSerializer
+ * @version $Rev$
+ *
+ * @xmlrpc.doc
+ * #struct("distChannelMap")
+ * #prop_desc("string", "os", "Operationg System")
+ * #prop_desc("string", "release", "OS Relase")
+ * #prop_desc("string", "arch_label", "Channel architecture")
+ * #prop_desc("string", "channel_label", "Channel label")
+ * #struct_end()
+ */
+public class DistChannelMapSerializer implements XmlRpcCustomSerializer {
+
+ /**
+ * {@inheritDoc}
+ */
+ public Class getSupportedClass() {
+ return DistChannelMap.class;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public void serialize(Object value, Writer output, XmlRpcSerializer builtInSerializer)
+ throws XmlRpcException, IOException {
+
+ DistChannelMap dstChannelMap = (DistChannelMap) value;
+ SerializerHelper helper = new SerializerHelper(builtInSerializer);
+
+ helper.add("os", dstChannelMap.getOs());
+ helper.add("release", dstChannelMap.getRelease());
+ helper.add("arch_name", dstChannelMap.getChannelArch().getName());
+ helper.add("channel_label", dstChannelMap.getChannel().getLabel());
+
+ helper.writeTo(output);
+ }
+}
diff --git a/java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/SerializerRegistry.java b/java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/SerializerRegistry.java
index 95fef8b..dc93fac 100644
--- a/java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/SerializerRegistry.java
+++ b/java/code/src/com/redhat/rhn/frontend/xmlrpc/serializer/SerializerRegistry.java
@@ -112,6 +112,7 @@ public class SerializerRegistry {
SERIALIZER_CLASSES.add(PackageOverviewSerializer.class);
SERIALIZER_CLASSES.add(SnippetSerializer.class);
SERIALIZER_CLASSES.add(NetworkDtoSerializer.class);
+ SERIALIZER_CLASSES.add(DistChannelMapSerializer.class);
}
/**
commit c68afa462e0f5302c8ce7d48717052518ec976b7
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed Apr 28 20:22:00 2010 +0200
add 2 new DistChannelMap related queries with appropriate methods
diff --git a/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java b/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
index c8a44bb..f082bad 100644
--- a/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
+++ b/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
@@ -708,7 +708,19 @@ public class ChannelFactory extends HibernateFactory {
Collections.sort(list);
return list.get(0);
}
-
+
+ /**
+ * List all defined dist channel maps
+ *
+ * Returns empty array if none is found.
+ *
+ * @return DistChannelMap[], empty if none is found
+ */
+ public static List<DistChannelMap> listAllDistChannelMaps() {
+
+ return singleton.listObjectsByNamedQuery("DistChannelMap.listAll", null);
+ }
+
/**
* Lookup the dist channel map for the given product name, release, and channel arch.
* Returns null if none is found.
@@ -728,7 +740,27 @@ public class ChannelFactory extends HibernateFactory {
return (DistChannelMap)singleton.lookupObjectByNamedQuery(
"DistChannelMap.findByProductNameReleaseAndChannelArch", params);
}
-
+
+ /**
+ * Lookup the dist channel map for the given os, release, and channel arch.
+ * Returns null if none is found.
+ *
+ * @param os OS
+ * @param release Version.
+ * @param channelArch Channel arch.
+ * @return DistChannelMap, null if none is found
+ */
+ public static DistChannelMap lookupDistChannelMapByOsReleaseArch(String os,
+ String release, ChannelArch channelArch) {
+
+ Map params = new HashMap();
+ params.put("os", os);
+ params.put("release", release);
+ params.put("channelArch", channelArch);
+ return (DistChannelMap)singleton.lookupObjectByNamedQuery(
+ "DistChannelMap.findByOsReleaseArch", params);
+ }
+
/**
* Lookup the dist channel map for the given channel.
* Returns null if none is found.
diff --git a/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml b/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
index 509efd3..5bec984 100644
--- a/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
+++ b/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
@@ -24,6 +24,12 @@ PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
</class>
+ <query name="DistChannelMap.listAll">
+ <![CDATA[
+ from com.redhat.rhn.domain.channel.DistChannelMap
+ ]]>
+ </query>
+
<query name="DistChannelMap.findByProductNameReleaseAndChannelArch">
<![CDATA[
select dcm
@@ -38,6 +44,16 @@ PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
]]>
</query>
+ <query name="DistChannelMap.findByOsReleaseArch">
+ <![CDATA[
+ select dcm
+ from com.redhat.rhn.domain.channel.DistChannelMap as dcm
+ where dcm.release = :release
+ and dcm.channelArch = :channelArch
+ and dcm.os = :os
+ ]]>
+ </query>
+
<query name="DistChannelMap.findByChannel">
<![CDATA[
from com.redhat.rhn.domain.channel.DistChannelMap as dcm
commit dd563ae9998d0b7f67f3434a461ca6e2a73d9ab2
Author: Tomas Lestach <tlestach(a)redhat.com>
Date: Wed Apr 28 19:43:55 2010 +0200
rename {lookup,find}ByOsReleaseAndChannelArch -> ByProductNameReleaseAndChannelArch
diff --git a/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java b/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
index e9bf8c2..c8a44bb 100644
--- a/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
+++ b/java/code/src/com/redhat/rhn/domain/channel/ChannelFactory.java
@@ -710,23 +710,23 @@ public class ChannelFactory extends HibernateFactory {
}
/**
- * Lookup the dist channel map for the given os, release, and channel arch.
+ * Lookup the dist channel map for the given product name, release, and channel arch.
* Returns null if none is found.
*
- * @param os Product name.
+ * @param productName Product name.
* @param release Version.
* @param channelArch Channel arch.
* @return DistChannelMap, null if none is found
*/
- public static DistChannelMap lookupDistChannelMap(String os, String release,
- ChannelArch channelArch) {
+ public static DistChannelMap lookupDistChannelMapByPnReleaseArch(
+ String productName, String release, ChannelArch channelArch) {
Map params = new HashMap();
- params.put("os", os);
+ params.put("productName", productName);
params.put("release", release);
params.put("channelArch", channelArch);
return (DistChannelMap)singleton.lookupObjectByNamedQuery(
- "DistChannelMap.findByOsReleaseAndChannelArch", params);
+ "DistChannelMap.findByProductNameReleaseAndChannelArch", params);
}
/**
diff --git a/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml b/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
index 03538b4..509efd3 100644
--- a/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
+++ b/java/code/src/com/redhat/rhn/domain/channel/DistChannelMap.hbm.xml
@@ -24,7 +24,7 @@ PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
</class>
- <query name="DistChannelMap.findByOsReleaseAndChannelArch">
+ <query name="DistChannelMap.findByProductNameReleaseAndChannelArch">
<![CDATA[
select dcm
from com.redhat.rhn.domain.channel.DistChannelMap as dcm,
@@ -34,7 +34,7 @@ PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
and dcm.channelArch = :channelArch
and dcm.channel = chan
and chan.productName = pn
- and pn.label = :os
+ and pn.label = :productName
]]>
</query>
diff --git a/java/code/src/com/redhat/rhn/frontend/action/channel/ssm/BaseSubscribeAction.java b/java/code/src/com/redhat/rhn/frontend/action/channel/ssm/BaseSubscribeAction.java
index b92d4c6..6acdfd9 100644
--- a/java/code/src/com/redhat/rhn/frontend/action/channel/ssm/BaseSubscribeAction.java
+++ b/java/code/src/com/redhat/rhn/frontend/action/channel/ssm/BaseSubscribeAction.java
@@ -166,7 +166,8 @@ public class BaseSubscribeAction extends RhnLookupDispatchAction {
DistChannelMap dcm = ChannelFactory.lookupDistChannelMap(oldBase);
if (dcm != null && oldBase != null) {
String version = dcm.getRelease();
- DistChannelMap defaultDcm = ChannelManager.lookupDistChannelMap(
+ DistChannelMap defaultDcm =
+ ChannelManager.lookupDistChannelMapByPnReleaseArch(
ChannelManager.RHEL_PRODUCT_NAME, version,
oldBase.getChannelArch());
newBase = defaultDcm.getChannel();
diff --git a/java/code/src/com/redhat/rhn/manager/channel/ChannelManager.java b/java/code/src/com/redhat/rhn/manager/channel/ChannelManager.java
index 29bba83..7c88f4d 100644
--- a/java/code/src/com/redhat/rhn/manager/channel/ChannelManager.java
+++ b/java/code/src/com/redhat/rhn/manager/channel/ChannelManager.java
@@ -2000,8 +2000,8 @@ public class ChannelManager extends BaseManager {
private static Channel getDefaultBaseChannel(String version, ChannelArch
arch) {
- DistChannelMap dcm = ChannelManager.lookupDistChannelMap(RHEL_PRODUCT_NAME,
- version, arch);
+ DistChannelMap dcm = ChannelManager.lookupDistChannelMapByPnReleaseArch(
+ RHEL_PRODUCT_NAME, version, arch);
if (dcm == null) {
return null;
}
@@ -2236,14 +2236,14 @@ public class ChannelManager extends BaseManager {
* Lookup the dist channel map for the given os, release, and channel arch.
* Returns null if none is found.
*
- * @param os Product name.
+ * @param productName Product name.
* @param release Version.
* @param channelArch Channel arch.
* @return DistChannelMap, null if none is found
*/
- public static DistChannelMap lookupDistChannelMap(String os, String release,
- ChannelArch channelArch) {
- return ChannelFactory.lookupDistChannelMap(os, release,
+ public static DistChannelMap lookupDistChannelMapByPnReleaseArch(String productName,
+ String release, ChannelArch channelArch) {
+ return ChannelFactory.lookupDistChannelMapByPnReleaseArch(productName, release,
channelArch);
}
diff --git a/java/code/src/com/redhat/rhn/manager/channel/test/ChannelManagerTest.java b/java/code/src/com/redhat/rhn/manager/channel/test/ChannelManagerTest.java
index 3dc1b7c..7c1ab74 100644
--- a/java/code/src/com/redhat/rhn/manager/channel/test/ChannelManagerTest.java
+++ b/java/code/src/com/redhat/rhn/manager/channel/test/ChannelManagerTest.java
@@ -815,8 +815,8 @@ public class ChannelManagerTest extends BaseTestCaseWithUser {
String release = MAP_RELEASE + TestUtils.randomString();
ChannelTestUtils.addDistMapToChannel(c, TEST_OS, release);
- DistChannelMap dcm = ChannelManager.lookupDistChannelMap(TEST_OS, release,
- c.getChannelArch());
+ DistChannelMap dcm = ChannelManager.lookupDistChannelMapByPnReleaseArch(TEST_OS,
+ release, c.getChannelArch());
assertNotNull(dcm);
assertEquals(c.getId(), dcm.getChannel().getId());
}
13 years, 11 months
client/rhel
by Šimon Lukašík
client/rhel/rhnlib/test/test_server.py | 5 +++++
1 file changed, 5 insertions(+)
New commits:
commit 07cd27e31550f45fee26b704532d93679f61997a
Author: Simon Lukasik <slukasik(a)redhat.com>
Date: Thu Apr 29 11:17:32 2010 +0200
Adding shebang
diff --git a/client/rhel/rhnlib/test/test_server.py b/client/rhel/rhnlib/test/test_server.py
index ef3738a..ff6145c 100644
--- a/client/rhel/rhnlib/test/test_server.py
+++ b/client/rhel/rhnlib/test/test_server.py
@@ -1,3 +1,8 @@
+#!/usr/bin/python
+#
+#
+# $Id$
+
import unittest
from rhn.rpclib import Server
from rhn.rpclib import MalformedURIError
13 years, 11 months
client/rhel
by Šimon Lukašík
client/rhel/rhnlib/test/19-redirects.py | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
New commits:
commit 739ed49bd51965e501266a8cf8c88d44d2c6dd19
Author: Simon Lukasik <slukasik(a)redhat.com>
Date: Thu Apr 29 11:11:22 2010 +0200
Fixing return value
diff --git a/client/rhel/rhnlib/test/19-redirects.py b/client/rhel/rhnlib/test/19-redirects.py
old mode 100644
new mode 100755
index fc0de38..12cbd69
--- a/client/rhel/rhnlib/test/19-redirects.py
+++ b/client/rhel/rhnlib/test/19-redirects.py
@@ -41,8 +41,11 @@ def main():
global SYSTEM_ID
SYSTEM_ID = open(systemid_path).read()
+ ret = 0
for t in tests:
- ret = apply(run_test, t)
+ ret = apply(run_test, t) or ret
+ return ret
+
def run_test(url, allow_redirect, should_fail, text_message):
global SYSTEM_ID
@@ -59,17 +62,17 @@ def run_test(url, allow_redirect, should_fail, text_message):
except Exception, e:
if should_fail and isinstance(e, should_fail):
print "PASS"
- return 1
+ return 0
print "FAIL (exception: %s)" % (e.__class__.__name__)
- return 0
+ return 1
if should_fail:
print "FAIL (no exception)"
- return 0
+ return 1
print "PASS"
- return 1
+ return 0
if __name__ == '__main__':
13 years, 11 months
6 commits - backend/satellite_tools backend/server
by Jan Pazdziora
backend/satellite_tools/disk_dumper/dumper.py | 13 ++++++++-----
backend/satellite_tools/exporter/exportLib.py | 20 +++++++++++++++++++-
backend/satellite_tools/satsync.py | 4 ++--
backend/satellite_tools/xmlSource.py | 3 +++
backend/server/importlib/importLib.py | 1 +
5 files changed, 33 insertions(+), 8 deletions(-)
New commits:
commit a26cb1eda3a9aeb206cc2fa18715901d72ae606a
Merge: 9336283... ba45228...
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Thu Apr 29 11:03:30 2010 +0200
585233 - use the exportLib._dbtime2timestamp approach.
Now that we've investigated two ways of doing
rhn-channel-comps-last-modified export, we shall pick the extra
select + exportLib._dbtime2timestamp approach.
commit 93362832d55ae958f54fbd4048e297c7295618ae
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Apr 28 14:01:00 2010 +0200
585233 - replace has-comps with rhn-channel-comps-last-modified for inter-sat-sync.
diff --git a/backend/satellite_tools/disk_dumper/dumper.py b/backend/satellite_tools/disk_dumper/dumper.py
index a48973d..1a2d30d 100644
--- a/backend/satellite_tools/disk_dumper/dumper.py
+++ b/backend/satellite_tools/disk_dumper/dumper.py
@@ -1170,19 +1170,6 @@ class _ChannelsDumper(exportLib._ChannelDumper):
""")
# Things that can be overwriten in subclasses
- _query_channel_comps_last_modified = rhnSQL.Statement("""
- select to_char(last_modified, 'YYYYMMDDHH24MISS') as comps_last_modified
- from rhnChannelComps
- where channel_id = :channel_id
- order by id desc
- """)
-
- def _channel_comps_last_modified(self):
- channel_id = self._row['id']
- h = rhnSQL.prepare(self._query_channel_comps_last_modified)
- h.execute(channel_id=channel_id)
- return h.fetchone()
-
def _get_package_ids(self):
channel_id = self._row['id']
if LOWER_LIMIT:
@@ -1284,8 +1271,7 @@ class ChannelsDumperEx(CachedDumper, exportLib.ChannelsDumper):
cp.version channel_product_version,
cp.beta channel_product_beta,
c.receiving_updates,
- ct.label checksum_type,
- nvl(( select 'True' from rhnChannelComps where c.id = rhnChannelComps.channel_id and rownum = 1 ), 'False') as has_comps
+ ct.label checksum_type
from rhnChannel c, rhnChannelArch ca, rhnChannel pc, rhnChannelProduct cp,
rhnChecksumType ct
where c.id = :channel_id
diff --git a/backend/satellite_tools/exporter/exportLib.py b/backend/satellite_tools/exporter/exportLib.py
index 244bdb3..265fc8c 100644
--- a/backend/satellite_tools/exporter/exportLib.py
+++ b/backend/satellite_tools/exporter/exportLib.py
@@ -190,7 +190,6 @@ class _ChannelDumper(BaseRowDumper):
'packages' : string.join(packages),
'channel-errata' : string.join(errata),
'kickstartable-trees' : string.join(ks_trees),
- 'has-comps' : self._row['has_comps'],
}
_query_channel_families = rhnSQL.Statement("""
@@ -232,6 +231,12 @@ class _ChannelDumper(BaseRowDumper):
arr.append(SimpleDumper(self._writer, 'rhn-channel-product-beta',
channel_product_details[2]))
+ comp_last_modified = self._channel_comps_last_modified()
+ if comp_last_modified != None:
+ arr.append(exportLib.SimpleDumper(self._writer, 'rhn-channel-comps-last-modified',
+ exportLib._dbtime2timestamp(comp_last_modified[0]))
+ )
+
h = rhnSQL.prepare(self._query_channel_families)
h.execute(channel_id=channel_id)
arr.append(ChannelFamiliesDumper(self._writer, data_iterator=h,
@@ -343,6 +348,19 @@ class _ChannelDumper(BaseRowDumper):
else:
return (row['name'], row['version'], row['beta'])
+ _query_channel_comps_last_modified = rhnSQL.Statement("""
+ select to_char(last_modified, 'YYYYMMDDHH24MISS') as comps_last_modified
+ from rhnChannelComps
+ where channel_id = :channel_id
+ order by id desc
+ """)
+
+ def _channel_comps_last_modified(self):
+ channel_id = self._row['id']
+ h = rhnSQL.prepare(self._query_channel_comps_last_modified)
+ h.execute(channel_id=channel_id)
+ return h.fetchone()
+
class ChannelDumper(_ChannelDumper):
def __init__(self, writer, row):
commit ba452283dde11d7d09b6d10f4eb8fa8d295763d6
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Apr 28 11:04:05 2010 +0200
585233 - replace has-comps with rhn-channel-comps-last-modified for inter-sat-sync.
diff --git a/backend/satellite_tools/disk_dumper/dumper.py b/backend/satellite_tools/disk_dumper/dumper.py
index 7665049..e0eab8f 100644
--- a/backend/satellite_tools/disk_dumper/dumper.py
+++ b/backend/satellite_tools/disk_dumper/dumper.py
@@ -1270,7 +1270,9 @@ class ChannelsDumperEx(CachedDumper, exportLib.ChannelsDumper):
cp.beta channel_product_beta,
c.receiving_updates,
ct.label checksum_type,
- nvl(( select 'True' from rhnChannelComps where c.id = rhnChannelComps.channel_id and rownum = 1 ), 'False') as has_comps
+ ( select max(round((rhnChannelComps.last_modified - to_date('19700101', 'YYYYMMDD')) * 86400))
+ from rhnChannelComps
+ where c.id = rhnChannelComps.channel_id ) as comps_last_modified
from rhnChannel c, rhnChannelArch ca, rhnChannel pc, rhnChannelProduct cp,
rhnChecksumType ct
where c.id = :channel_id
diff --git a/backend/satellite_tools/exporter/exportLib.py b/backend/satellite_tools/exporter/exportLib.py
index 244bdb3..4e65544 100644
--- a/backend/satellite_tools/exporter/exportLib.py
+++ b/backend/satellite_tools/exporter/exportLib.py
@@ -190,7 +190,6 @@ class _ChannelDumper(BaseRowDumper):
'packages' : string.join(packages),
'channel-errata' : string.join(errata),
'kickstartable-trees' : string.join(ks_trees),
- 'has-comps' : self._row['has_comps'],
}
_query_channel_families = rhnSQL.Statement("""
@@ -217,6 +216,7 @@ class _ChannelDumper(BaseRowDumper):
('rhn-channel-description', 'description'),
('rhn-channel-gpg-key-url', 'gpg_key_url'),
('rhn-channel-checksum-type', 'checksum_type'),
+ ('rhn-channel-comps-last-modified', 'comps_last_modified'),
]
for k, v in mappings:
arr.append(SimpleDumper(self._writer, k, self._row[v]))
commit 289bfc9d6006bc7590749ce56cb1921a9d8cd606
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Apr 28 10:30:13 2010 +0200
585233 - replace has-comps with rhn-channel-comps-last-modified for disk channel dumps.
diff --git a/backend/satellite_tools/disk_dumper/dumper.py b/backend/satellite_tools/disk_dumper/dumper.py
index 19cde06..7665049 100644
--- a/backend/satellite_tools/disk_dumper/dumper.py
+++ b/backend/satellite_tools/disk_dumper/dumper.py
@@ -1046,7 +1046,9 @@ class ChannelsDumper(exportLib.ChannelsDumper):
ct.label checksum_type,
TO_CHAR(c.last_modified, 'YYYYMMDDHH24MISS') last_modified,
pc.label parent_channel,
- nvl(( select 'True' from rhnChannelComps where c.id = rhnChannelComps.channel_id and rownum = 1 ), 'False') as has_comps
+ ( select max(round((rhnChannelComps.last_modified - to_date('19700101', 'YYYYMMDD')) * 86400))
+ from rhnChannelComps
+ where c.id = rhnChannelComps.channel_id ) as comps_last_modified
from rhnChannel c, rhnChannelArch ca, rhnChannel pc,
rhnChecksumType ct
where c.id = :channel_id
@@ -1092,7 +1094,6 @@ class _ChannelsDumper(exportLib._ChannelDumper):
'packages' : string.join(packages),
'channel-errata' : string.join(errata),
'kickstartable-trees' : string.join(ks_trees),
- 'has-comps' : self._row['has_comps'],
}
_query_channel_families = rhnSQL.Statement("""
@@ -1119,6 +1120,7 @@ class _ChannelsDumper(exportLib._ChannelDumper):
('rhn-channel-description', 'description'),
('rhn-channel-gpg-key-url', 'gpg_key_url'),
('rhn-channel-checksum-type', 'checksum_type'),
+ ('rhn-channel-comps-last-modified', 'comps_last_modified'),
]
for k, v in mappings:
arr.append(exportLib.SimpleDumper(self._writer, k, self._row[v]))
diff --git a/backend/server/importlib/importLib.py b/backend/server/importlib/importLib.py
index 423f8af..c0b2b64 100644
--- a/backend/server/importlib/importLib.py
+++ b/backend/server/importlib/importLib.py
@@ -200,6 +200,7 @@ class Channel(Information):
'summary' : StringType,
'description' : StringType,
'last_modified' : DateType,
+ 'comps_last_modified' : DateType,
'gpg_key_url' : StringType,
'product_name_id' : IntType,
'channel_product_id': IntType,
commit 8b61a047ddbaa4493634860a29e5a39174129e63
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Apr 28 10:30:13 2010 +0200
585233 - replace has-comps with rhn-channel-comps-last-modified for disk channel dumps.
diff --git a/backend/satellite_tools/disk_dumper/dumper.py b/backend/satellite_tools/disk_dumper/dumper.py
index 19cde06..a48973d 100644
--- a/backend/satellite_tools/disk_dumper/dumper.py
+++ b/backend/satellite_tools/disk_dumper/dumper.py
@@ -1045,8 +1045,7 @@ class ChannelsDumper(exportLib.ChannelsDumper):
c.summary, c.description, c.gpg_key_url,
ct.label checksum_type,
TO_CHAR(c.last_modified, 'YYYYMMDDHH24MISS') last_modified,
- pc.label parent_channel,
- nvl(( select 'True' from rhnChannelComps where c.id = rhnChannelComps.channel_id and rownum = 1 ), 'False') as has_comps
+ pc.label parent_channel
from rhnChannel c, rhnChannelArch ca, rhnChannel pc,
rhnChecksumType ct
where c.id = :channel_id
@@ -1092,7 +1091,6 @@ class _ChannelsDumper(exportLib._ChannelDumper):
'packages' : string.join(packages),
'channel-errata' : string.join(errata),
'kickstartable-trees' : string.join(ks_trees),
- 'has-comps' : self._row['has_comps'],
}
_query_channel_families = rhnSQL.Statement("""
@@ -1127,6 +1125,12 @@ class _ChannelsDumper(exportLib._ChannelDumper):
exportLib._dbtime2timestamp(self._row['last_modified']))
)
+ comp_last_modified = self._channel_comps_last_modified()
+ if comp_last_modified != None:
+ arr.append(exportLib.SimpleDumper(self._writer, 'rhn-channel-comps-last-modified',
+ exportLib._dbtime2timestamp(comp_last_modified[0]))
+ )
+
h = rhnSQL.prepare(self._query_channel_families)
h.execute(channel_id=channel_id)
arr.append(exportLib.ChannelFamiliesDumper(self._writer, data_iterator=h,
@@ -1166,6 +1170,19 @@ class _ChannelsDumper(exportLib._ChannelDumper):
""")
# Things that can be overwriten in subclasses
+ _query_channel_comps_last_modified = rhnSQL.Statement("""
+ select to_char(last_modified, 'YYYYMMDDHH24MISS') as comps_last_modified
+ from rhnChannelComps
+ where channel_id = :channel_id
+ order by id desc
+ """)
+
+ def _channel_comps_last_modified(self):
+ channel_id = self._row['id']
+ h = rhnSQL.prepare(self._query_channel_comps_last_modified)
+ h.execute(channel_id=channel_id)
+ return h.fetchone()
+
def _get_package_ids(self):
channel_id = self._row['id']
if LOWER_LIMIT:
diff --git a/backend/server/importlib/importLib.py b/backend/server/importlib/importLib.py
index 423f8af..c0b2b64 100644
--- a/backend/server/importlib/importLib.py
+++ b/backend/server/importlib/importLib.py
@@ -200,6 +200,7 @@ class Channel(Information):
'summary' : StringType,
'description' : StringType,
'last_modified' : DateType,
+ 'comps_last_modified' : DateType,
'gpg_key_url' : StringType,
'product_name_id' : IntType,
'channel_product_id': IntType,
commit 2677bffbd2b65e393b5e0ebcfac53af81c869fe8
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Apr 28 08:23:33 2010 +0200
585233 - use the rhn-channel-comps-last-modified element instead of boolean has-comps.
Fall back to channel's last-modified value if
rhn-channel-comps-last-modified is not present and the channel
has has-comps set.
diff --git a/backend/satellite_tools/satsync.py b/backend/satellite_tools/satsync.py
index d9c6839..607aa56 100644
--- a/backend/satellite_tools/satsync.py
+++ b/backend/satellite_tools/satsync.py
@@ -690,8 +690,8 @@ Please contact your RHN representative""" % (generation, sat_cert.generation))
for label in requested_channels:
timestamp = self._channel_collection.get_channel_timestamp(label)
ch = self._channel_collection.get_channel(label, timestamp)
- if ch.has_key('has_comps') and ch['has_comps'] == 'True':
- self._process_comps(importer.backend, label, timestamp)
+ if ch.has_key('comps_last_modified') and ch['comps_last_modified'] != None::
+ self._process_comps(importer.backend, label, sync_handlers._to_timestamp(ch['comps_last_modified']))
except InvalidChannelFamilyError:
raise RhnSyncException(messages.invalid_channel_family_error %
diff --git a/backend/satellite_tools/xmlSource.py b/backend/satellite_tools/xmlSource.py
index 1ea7b18..7064af0 100644
--- a/backend/satellite_tools/xmlSource.py
+++ b/backend/satellite_tools/xmlSource.py
@@ -463,12 +463,15 @@ class ChannelItem(BaseItem):
'rhn-channel-product-beta' : 'product_beta',
'rhn-channel-receiving-updates' : 'receiving_updates',
'rhn-channel-checksum-type' : 'checksum_type',
+ 'rhn-channel-comps-last-modified' : 'comps_last_modified',
'has-comps' : 'has_comps',
}
def populateFromElements(self, obj, elements):
BaseItem.populateFromElements(self, obj, elements)
if obj['checksum_type'] == 'sha':
obj['checksum_type'] = 'sha1'
+ if not obj.has_key('comps_last_modified') and obj.has_key('has_comps'):
+ obj['comps_last_modified'] = obj['last_modified']
addItem(ChannelItem)
class BaseChecksummedItem(BaseItem):
13 years, 11 months
java/code web/html
by Partha Aji
java/code/src/com/redhat/rhn/frontend/taglibs/list/ExpandableColumnTag.java | 25 +
java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTag.java | 36 +
java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagHelper.java | 35 +
java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagUtil.java | 11
java/code/src/com/redhat/rhn/frontend/taglibs/list/NonExpandableColumnTag.java | 2
java/code/src/com/redhat/rhn/frontend/taglibs/list/decorators/ExpansionDecorator.java | 60 +++
java/code/src/com/redhat/rhn/frontend/taglibs/list/row/ExpandableRowRenderer.java | 35 +
java/code/src/com/redhat/rhn/frontend/taglibs/list/row/RowRenderer.java | 24 +
java/code/webapp/WEB-INF/decorators/layout_head.jsp | 1
java/code/webapp/WEB-INF/pages/systems/duplicate/duplicateIPList.jsp | 6
web/html/javascript/tree.js | 187 ++++++++++
11 files changed, 387 insertions(+), 35 deletions(-)
New commits:
commit 0259643968c5054c992af081b6ee529bf117b6d9
Author: Partha Aji <paji(a)redhat.com>
Date: Wed Apr 28 16:37:03 2010 -0400
Added all the javascript macgic needed to show and hide stuff
diff --git a/java/code/src/com/redhat/rhn/frontend/taglibs/list/ExpandableColumnTag.java b/java/code/src/com/redhat/rhn/frontend/taglibs/list/ExpandableColumnTag.java
index 7507181..37f3d8f 100644
--- a/java/code/src/com/redhat/rhn/frontend/taglibs/list/ExpandableColumnTag.java
+++ b/java/code/src/com/redhat/rhn/frontend/taglibs/list/ExpandableColumnTag.java
@@ -15,8 +15,7 @@
package com.redhat.rhn.frontend.taglibs.list;
import com.redhat.rhn.frontend.taglibs.RhnListTagFunctions;
-
-import org.apache.commons.lang.BooleanUtils;
+import com.redhat.rhn.frontend.taglibs.list.row.ExpandableRowRenderer;
import javax.servlet.jsp.JspException;
import javax.servlet.jsp.tagext.BodyTagSupport;
@@ -32,13 +31,17 @@ public class ExpandableColumnTag extends BodyTagSupport {
*/
private static final long serialVersionUID = 9164800881253245840L;
private boolean renderIcon;
-
+
+ private static final String IMAGE_SCRIPT = "<a onclick=\"toggleRowVisibility('%s', " +
+ "rowHash%s);\" " +
+ "style=\"cursor: pointer;\"><img name=\"%s\"" +
+ " src=\"/img/list-expand.gif\"/></a>";
/**
* true to render icon
* @param render true to render icon
*/
public void setRendericon(String render) {
- renderIcon = BooleanUtils.toBoolean(render);
+ renderIcon = ListTagUtil.toBoolean(render);
}
protected Object getCurrent() {
ListTag parent = (ListTag)
@@ -74,8 +77,12 @@ public class ExpandableColumnTag extends BodyTagSupport {
}
protected void renderIcon() throws JspException {
- ListTagUtil.write(pageContext, "<img name=\"id101-image\" " +
- "src=\"/img/list-collapse.gif\"/>");
+ String listName = getListName();
+ Object current = getCurrent();
+ String rowId = new ExpandableRowRenderer().getRowId(listName, current);
+ String imageId = rowId + "-image";
+ ListTagUtil.write(pageContext, String.format(IMAGE_SCRIPT,
+ rowId, listName, imageId));
}
/** {@inheritDoc}
@@ -85,4 +92,10 @@ public class ExpandableColumnTag extends BodyTagSupport {
renderIcon = false;
super.release();
}
+
+ protected String getListName() {
+ ListTag parent = (ListTag)
+ BodyTagSupport.findAncestorWithClass(this, ListTag.class);
+ return parent.getUniqueName();
+ }
}
diff --git a/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTag.java b/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTag.java
index 2455da8..90d74b5 100644
--- a/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTag.java
+++ b/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTag.java
@@ -118,9 +118,6 @@ public class ListTag extends BodyTagSupport {
}
return decorators;
}
-
-
-
/**
* Set the row renderer
@@ -365,7 +362,7 @@ public class ListTag extends BodyTagSupport {
*/
if ((refLink != null) && (!isEmpty())) {
ListTagUtil.write(pageContext, "<tr");
- renderRowClass();
+ renderRowClassAndId();
ListTagUtil.write(pageContext, ">");
ListTagUtil.write(pageContext, "<td style=\"text-align: center;\" " +
@@ -529,7 +526,7 @@ public class ListTag extends BodyTagSupport {
}
else {
ListTagUtil.write(pageContext, "<tr");
- renderRowClass();
+ renderRowClassAndId();
ListTagUtil.write(pageContext, ">");
pageContext.setAttribute(rowName, currentObject);
@@ -688,15 +685,25 @@ public class ListTag extends BodyTagSupport {
ListTagUtil.write(pageContext, "</td></tr>");
}
- private void renderRowClass() throws JspException {
+ private void renderRowClassAndId() throws JspException {
rowCounter++;
ListTagUtil.write(pageContext, " class=\"");
- ListTagUtil.write(pageContext, getRowRenderer().getRowStyle(getCurrentObject()));
+ ListTagUtil.write(pageContext, getRowRenderer().getRowClass(getCurrentObject()));
if (rowCounter == manip.findAlphaPosition() % pageSize) {
ListTagUtil.write(pageContext, " alphaResult");
}
- ListTagUtil.write(pageContext, "\"");
+ ListTagUtil.write(pageContext, "\" ");
+ ListTagUtil.write(pageContext, "id=\"");
+ ListTagUtil.write(pageContext, getRowRenderer().getRowId(getUniqueName(),
+ getCurrentObject()));
+ ListTagUtil.write(pageContext, "\" ");
+ String style = getRowRenderer().getRowStyle(getCurrentObject());
+ if (!StringUtils.isBlank(style)) {
+ ListTagUtil.write(pageContext, "style=\"");
+ ListTagUtil.write(pageContext, style);
+ ListTagUtil.write(pageContext, "\" ");
+ }
}
private void emitId() throws JspException {
@@ -714,11 +721,11 @@ public class ListTag extends BodyTagSupport {
ListTagUtil.write(pageContext, styleClass);
ListTagUtil.write(pageContext, "\"");
}
- if (styleId != null) {
- ListTagUtil.write(pageContext, " id=\"");
- ListTagUtil.write(pageContext, styleId);
- ListTagUtil.write(pageContext, "\"");
- }
+
+ ListTagUtil.write(pageContext, " id=\"");
+ ListTagUtil.write(pageContext, getStyleId());
+ ListTagUtil.write(pageContext, "\"");
+
if (width != null) {
ListTagUtil.write(pageContext, " width=\"");
ListTagUtil.write(pageContext, width);
@@ -907,6 +914,9 @@ public class ListTag extends BodyTagSupport {
* @return CSS ID for <table>
*/
public String getStyleId() {
+ if (StringUtils.isBlank(styleId)) {
+ styleId = "list_" + getUniqueName() + "style_id";
+ }
return styleId;
}
diff --git a/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagHelper.java b/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagHelper.java
index 7628f89..3dccde0 100644
--- a/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagHelper.java
+++ b/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagHelper.java
@@ -14,6 +14,8 @@
*/
package com.redhat.rhn.frontend.taglibs.list;
+import com.redhat.rhn.domain.Identifiable;
+import com.redhat.rhn.frontend.struts.Selectable;
import com.redhat.rhn.frontend.taglibs.list.decorators.PageSizeDecorator;
import com.redhat.rhn.manager.rhnset.RhnSetDecl;
@@ -224,5 +226,36 @@ public class ListTagHelper {
return newValue;
}
- }
+ }
+ /**
+ * Returns the object id given an object
+ * deals with selectable/identifiable objects
+ * or uses hashcode for general
+ * @param current the current object
+ * @return the id representing the object
+ */
+ public static String getObjectId(Object current) {
+ String id;
+ if (current instanceof Selectable) {
+ id = ((Selectable)current).getSelectionKey();
+ }
+ else if (current instanceof Identifiable) {
+ id = String.valueOf(((Identifiable)current).getId());
+ }
+ else {
+ id = String.valueOf(current.hashCode());
+ }
+ return id;
+ }
+
+ /**
+ * Makes the tr row ids useful especially for expandable row renderers.
+ * @param listName the name of the list
+ * @param current the object to be expanded on
+ * @return the row id value
+ */
+ public static String makeRowId(String listName, Object current) {
+ return "row_" + listName + "_" + ListTagHelper.getObjectId(current);
+ }
+
}
diff --git a/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagUtil.java b/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagUtil.java
index 1fc524a..ebb06ef 100644
--- a/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagUtil.java
+++ b/java/code/src/com/redhat/rhn/frontend/taglibs/list/ListTagUtil.java
@@ -302,7 +302,16 @@ public class ListTagUtil {
}
+ /**
+ * provides the filter label (what to sort by) url key
+ * @param listName the list name
+ * @return the url key for filter value label
+ */
+ public static String makeImageNameByLabel(String listName) {
+ return "list_" + listName + "_filterattr";
+ }
+
/**
* provides the filter name (the name value for the go button on the filter box)
* @param listName the list name
@@ -679,6 +688,4 @@ public class ListTagUtil {
return url;
}
-
-
}
diff --git a/java/code/src/com/redhat/rhn/frontend/taglibs/list/NonExpandableColumnTag.java b/java/code/src/com/redhat/rhn/frontend/taglibs/list/NonExpandableColumnTag.java
index de71cef..ae84783 100644
--- a/java/code/src/com/redhat/rhn/frontend/taglibs/list/NonExpandableColumnTag.java
+++ b/java/code/src/com/redhat/rhn/frontend/taglibs/list/NonExpandableColumnTag.java
@@ -39,5 +39,5 @@ public class NonExpandableColumnTag extends ExpandableColumnTag {
protected void renderIcon() throws JspException {
ListTagUtil.write(pageContext, "<img style=\"margin-left: 4px;\"" +
" src=\"/img/channel_child_node.gif\"/>");
- }
+ }
}
diff --git a/java/code/src/com/redhat/rhn/frontend/taglibs/list/decorators/ExpansionDecorator.java b/java/code/src/com/redhat/rhn/frontend/taglibs/list/decorators/ExpansionDecorator.java
new file mode 100644
index 0000000..3198608
--- /dev/null
+++ b/java/code/src/com/redhat/rhn/frontend/taglibs/list/decorators/ExpansionDecorator.java
@@ -0,0 +1,60 @@
+/**
+ * Copyright (c) 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.
+ */
+package com.redhat.rhn.frontend.taglibs.list.decorators;
+
+import com.redhat.rhn.frontend.taglibs.list.ListTag;
+import com.redhat.rhn.frontend.taglibs.list.ListTagUtil;
+
+import javax.servlet.jsp.JspException;
+
+
+/**
+ * ExpandableDecorator
+ * @version $Rev$
+ */
+public class ExpansionDecorator extends BaseListDecorator {
+
+ private static final String SHOW_ALL_SCRIPT =
+ "<a href=\"javascript:showAllRows(rowHash%s);\"" +
+ " style=\"cursor: pointer;\">Show All</a> | " +
+ "<a href=\"javascript:hideAllRows(rowHash%s);\" " +
+ "style=\"cursor: pointer;\">Hide All</a>";
+
+ private static final String NEW_VAR_SCRIPT = "<script type=\"text/javascript\">var " +
+ "rowHash%s = new Array();</script>";
+
+ private static final String LOAD_SCRIPT = "<script type=\"text/javascript\">" +
+ "onLoadStuff(%s, '%s', rowHash%s);</script>";
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public void beforeList() throws JspException {
+ ListTagUtil.write(pageContext, String.format(NEW_VAR_SCRIPT, listName));
+ ListTagUtil.write(pageContext, String.format(SHOW_ALL_SCRIPT, listName, listName));
+
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public void afterList() throws JspException {
+ ListTag list = getCurrentList();
+ ListTagUtil.write(pageContext, String.format(LOAD_SCRIPT,
+ list.getColumnCount(), list.getStyleId(), listName));
+ }
+}
diff --git a/java/code/src/com/redhat/rhn/frontend/taglibs/list/row/ExpandableRowRenderer.java b/java/code/src/com/redhat/rhn/frontend/taglibs/list/row/ExpandableRowRenderer.java
index a4ef964..5c8da35 100644
--- a/java/code/src/com/redhat/rhn/frontend/taglibs/list/row/ExpandableRowRenderer.java
+++ b/java/code/src/com/redhat/rhn/frontend/taglibs/list/row/ExpandableRowRenderer.java
@@ -14,7 +14,8 @@
*/
package com.redhat.rhn.frontend.taglibs.list.row;
-import com.redhat.rhn.frontend.struts.Expandable;
+import com.redhat.rhn.frontend.taglibs.RhnListTagFunctions;
+import com.redhat.rhn.frontend.taglibs.list.ListTagHelper;
/**
*
@@ -33,18 +34,38 @@ public class ExpandableRowRenderer extends RowRenderer {
/**
* get the row style for the current object
- * @param currentObject the current object that is being rendered
+ * @param current the current object that is being rendered
* @return the string that is the style to add to the row
*/
- public String getRowStyle(Object currentObject) {
- if (currentObject instanceof Expandable) {
+ @Override
+ public String getRowClass(Object current) {
+ if (RhnListTagFunctions.isExpandable(current)) {
return rowClasses[1];
}
else {
return rowClasses[0];
}
}
-
-
-
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public String getRowId(String listName, Object current) {
+ if (RhnListTagFunctions.isExpandable(current)) {
+ return super.getRowId(listName, current);
+ }
+ return "child-" + listName + "-" + ListTagHelper.getObjectId(current);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public String getRowStyle(Object currentObject) {
+ if (!RhnListTagFunctions.isExpandable(currentObject)) {
+ return "display: none;";
+ }
+ return super.getRowStyle(currentObject);
+ }
}
diff --git a/java/code/src/com/redhat/rhn/frontend/taglibs/list/row/RowRenderer.java b/java/code/src/com/redhat/rhn/frontend/taglibs/list/row/RowRenderer.java
index 73b22d4..b7c7517 100644
--- a/java/code/src/com/redhat/rhn/frontend/taglibs/list/row/RowRenderer.java
+++ b/java/code/src/com/redhat/rhn/frontend/taglibs/list/row/RowRenderer.java
@@ -14,6 +14,7 @@
*/
package com.redhat.rhn.frontend.taglibs.list.row;
+import com.redhat.rhn.frontend.taglibs.list.ListTagHelper;
import com.redhat.rhn.frontend.taglibs.list.ListTagUtil;
/**
@@ -38,11 +39,11 @@ public class RowRenderer {
}
/**
- * get the row style for the current object
+ * get the row class for the current object
* @param currentObject the current object that is being rendered
* @return the string that is the style to add to the row
*/
- public String getRowStyle(Object currentObject) {
+ public String getRowClass(Object currentObject) {
rowNum++;
return rowClasses[rowNum % rowClasses.length];
}
@@ -54,7 +55,22 @@ public class RowRenderer {
public void setRowClasses(String stylesIn) {
rowClasses = ListTagUtil.parseStyles(stylesIn);
}
+ /**
+ * Returns the row id given the list name and the current object
+ * @param listName the listname
+ * @param currentObject the current object
+ * @return the row id
+ */
+ public String getRowId(String listName, Object currentObject) {
+ return ListTagHelper.makeRowId(listName, currentObject);
+ }
-
-
+ /**
+ * get the row style for the current object
+ * @param currentObject the current object that is being rendered
+ * @return the string that is the style to add to the row
+ */
+ public String getRowStyle(Object currentObject) {
+ return "";
+ }
}
diff --git a/java/code/webapp/WEB-INF/decorators/layout_head.jsp b/java/code/webapp/WEB-INF/decorators/layout_head.jsp
index 94e5a98..e79288c 100644
--- a/java/code/webapp/WEB-INF/decorators/layout_head.jsp
+++ b/java/code/webapp/WEB-INF/decorators/layout_head.jsp
@@ -24,6 +24,7 @@
<link rel="stylesheet" href="/css/rhn-base.css" type="text/css" />
<script src="/javascript/prototype-1.6.0.js" type="text/javascript"> </script>
<script src="/javascript/check_all.js" type="text/javascript"> </script>
+
<!--[if IE]>
<link rel="stylesheet" type="text/css" href="/css/rhn-iecompat.css" />
<![endif]-->
diff --git a/java/code/webapp/WEB-INF/pages/systems/duplicate/duplicateIPList.jsp b/java/code/webapp/WEB-INF/pages/systems/duplicate/duplicateIPList.jsp
index 78397f4..e874c45 100644
--- a/java/code/webapp/WEB-INF/pages/systems/duplicate/duplicateIPList.jsp
+++ b/java/code/webapp/WEB-INF/pages/systems/duplicate/duplicateIPList.jsp
@@ -8,6 +8,7 @@
<html>
<head>
<meta name="page-decorator" content="none" />
+ <script src="/javascript/tree.js" type="text/javascript"></script>
</head>
<body>
<rhn:toolbar base="h1" img="/img/rhn-icon-system.gif" imgAlt="system.common.systemAlt"
@@ -17,13 +18,15 @@
<p>
<bean:message key="duplicate-ip.jsp.message"/>
</p>
+
<rl:listset name="DupesListSet" legend="system">
<rl:list
emptykey="nosystems.message"
>
<rl:rowrenderer name="ExpandableRowRenderer" />
- <rl:decorator name="SelectableDecorator"/>
+ <rl:decorator name="SelectableDecorator"/>
+ <rl:decorator name="ExpansionDecorator"/>
<c:choose>
<c:when test = "${rl:expandable(current)}">
<rl:selectablecolumn value="${current.key}"
@@ -60,5 +63,6 @@
</rl:listset>
+
</body>
</html>
diff --git a/web/html/javascript/tree.js b/web/html/javascript/tree.js
new file mode 100755
index 0000000..b2ca1c9
--- /dev/null
+++ b/web/html/javascript/tree.js
@@ -0,0 +1,187 @@
+IMAGE_COLLAPSED_PATH = '/img/list-expand.gif';
+IMAGE_EXPANDED_PATH = '/img/list-collapse.gif';
+IMAGE_CHILDLESS_PATH = '/img/rhn-bullet-parentchannel.gif';
+
+
+var browserType;
+
+// tip of the Red Hat to Mar Orlygsson for this little IE detection script
+var is_ie/*@cc_on = {
+ quirksmode : (document.compatMode=="BackCompat"),
+ version : parseFloat(navigator.appVersion.match(/MSIE (.+?);/)[1])
+}@*/;
+browserType = is_ie;
+
+function onLoadStuff(columns, tableId, rowHash) {
+ var channelTable = document.getElementById(tableId);
+ createParentRows(channelTable, rowHash, columns);
+ reuniteChildrenWithParents(channelTable, rowHash);
+ iconifyChildlessParents(rowHash);
+}
+
+function iconifyChildlessParents(rowHash) {
+ for (var i in rowHash) {
+ if (!rowHash[i].hasChildren && rowHash[i].image) { rowHash[i].image.src = IMAGE_CHILDLESS_PATH; }
+ }
+}
+
+// called from clicking the show/hide button on individual rows in the page
+function toggleRowVisibility(id, rowHash) {
+ if (!rowHash[id]) { return; }
+ if (!rowHash[id].hasChildren) { alert("No Kids");return; }
+ rowHash[id].toggleVisibility();
+ return;
+}
+
+function showAllRows(rowHash) {
+ var row;
+ for (var i in rowHash) {
+ row = rowHash[i];
+ if (!row) { continue; }
+ if (!row.hasChildren) { continue; }
+ row.show();
+ }
+ return;
+}
+
+function hideAllRows(rowHash) {
+ var row;
+ for (var i in rowHash) {
+ row = rowHash[i];
+ if (!row) { continue; }
+ if (!row.hasChildren) { continue; }
+ row.hide();
+ }
+ return;
+}
+
+function Row(cells, image, columns) {
+ this.cells = new Array();
+ this.columnsPerRow = columns;
+ for (var i = 0; i < cells.length; i++) { this.cells[i] = cells[i]; }
+ this.image = image;
+ this.hasChildren = 0;
+ this.isHidden = 1; // 1 = hidden; 0 = visible. all rows are hidden by default
+
+// Row object methods below!
+ this.toggleVisibility = function() {
+ if (this.isHidden == 1) { this.show(); }
+ else if (this.isHidden == 0) { this.hide(); }
+ return;
+ }
+
+ this.hide = function hide() {
+ this.image.src = IMAGE_COLLAPSED_PATH;
+// we start with columnsPerRow, because we want to skip the td cells of the parent tr.
+ for (var i = this.columnsPerRow; i < this.cells.length; i++) {
+ this.cells[i].parentNode.style.display = 'none';
+ this.cells[i].style.display = 'none';
+ }
+ this.isHidden = 1;
+ return;
+ }
+
+ this.show = function() {
+ displayType = '';
+ this.image.src = IMAGE_EXPANDED_PATH;
+
+ for (var i = 0; i < this.cells.length; i++) {
+ this.cells[i].style.display = displayType;
+ this.cells[i].parentNode.style.display = displayType;
+ }
+ this.isHidden = 0;
+ return;
+ }
+}
+
+function createParentRows(channelTable, rowHash, columnsPerRow) {
+ for (var i = 0; i < channelTable.rows.length; i++) {
+ tableRowNode = channelTable.rows[i];
+ if (isParentRowNode(tableRowNode)) {
+ if (!tableRowNode.id) { continue; }
+ id = tableRowNode.id;
+ var cells = tableRowNode.cells;
+ var image = findRowImageFromCells(cells, id);
+ if (!image) { continue; }
+ rowHash[id] = new Row(cells, image, columnsPerRow);
+ }
+ }
+ return;
+}
+
+function reuniteChildrenWithParents(channelTable, rowHash) {
+ var parentNode;
+ var childId;
+ var tableChildRowNode;
+ for (var i = 0; i < channelTable.rows.length; i++) {
+ tableChildRowNode = channelTable.rows[i];
+// when we find a parent, set it as parent for the children after it
+ if (isParentRowNode(tableChildRowNode) && tableChildRowNode.id) {
+ parentNode = tableChildRowNode;
+ continue;
+ }
+ if (!parentNode) { continue; }
+
+ // it its not a child node we bail here
+ if (!isChildRowNode(tableChildRowNode)) { continue; }
+ // FIXME: chceck child id against parent id
+ if (!rowHash[parentNode.id]) { /*alert('bailing, cant find parent in hash');*/ continue; }
+ for (var j = 0; j < tableChildRowNode.cells.length; j++) {
+ rowHash[parentNode.id].cells.push(tableChildRowNode.cells[j]);
+ rowHash[parentNode.id].hasChildren = 1;
+ }
+ }
+ return;
+}
+
+
+function getNodeTagName(node) {
+ var tagName;
+ var nodeId;
+ tagName = new String(node.tagName);
+ return tagName.toLowerCase();
+}
+
+function isParentRowNode(node) {
+ var nodeInLowercase = getNodeTagName(node);
+ if (nodeInLowercase != 'tr') { return 0; }
+ nodeId = node.id;
+ if ((nodeId.indexOf('id')) && !(nodeId.indexOf('child'))) { return 0; }
+ return 1;
+}
+
+function isChildRowNode(node) {
+ var nodeInLowercase = getNodeTagName(node);
+ var nodeId;
+ if (nodeInLowercase != 'tr') { return 0; }
+ nodeId = node.id;
+ if (nodeId.indexOf('child')) { return 0; }
+ return 1;
+}
+
+
+function findRowImageFromCells(cells, id) {
+ var imageId = id + '-image';
+ var childNodes; // first level child
+ var grandchildNodes; // second level child
+ for (var i = 0; i < cells.length; i++) {
+ childNodes = null;
+ grandchildNodes = null;
+
+ if (!cells[i].hasChildNodes()) { continue; }
+
+ childNodes = cells[i].childNodes;
+
+ for (var j = 0; j < childNodes.length; j++) {
+ if (!childNodes[j].hasChildNodes()) { continue; }
+ if (getNodeTagName(childNodes[j]) != 'a') { continue; }
+ grandchildNodes = childNodes[j].childNodes;
+
+ for (var k = 0; k < grandchildNodes.length; k++) {
+ if (grandchildNodes[k].name != imageId) { continue; }
+ if (grandchildNodes[k].nodeName == 'IMG' || grandchildNodes[k].nodeName == 'img') { return grandchildNodes[k]; }
+ }
+ }
+ }
+ return null;
+}
13 years, 11 months
Changes to 'refs/tags/spacewalk-repo-1.0-2'
by Shannon Hughes
Tag 'spacewalk-repo-1.0-2' created by Shannon Hughes <shughes(a)redhat.com> at 2010-04-28 18:29 +0000
Tagging package [spacewalk-repo] version [1.0-2] in directory [spec-tree/spacewalk-repo/].
Changes since spacewalk-web-1.0.3-1:
Shannon Hughes (2):
modify repo version
Automatic commit of package [spacewalk-repo] minor release [1.0-2].
---
rel-eng/packages/spacewalk-repo | 2 +-
spec-tree/spacewalk-repo/spacewalk-repo.spec | 7 +++++--
2 files changed, 6 insertions(+), 3 deletions(-)
---
13 years, 11 months
Branch 'SPACEWALK-1.0' - rel-eng/packages spec-tree/spacewalk-repo
by Shannon Hughes
rel-eng/packages/spacewalk-repo | 2 +-
spec-tree/spacewalk-repo/spacewalk-repo.spec | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
New commits:
commit 0033dd9a264daed8838e69a59dc26f4fe6a1ad63
Author: Shannon Hughes <shughes(a)redhat.com>
Date: Wed Apr 28 14:29:19 2010 -0400
Automatic commit of package [spacewalk-repo] minor release [1.0-2].
diff --git a/rel-eng/packages/spacewalk-repo b/rel-eng/packages/spacewalk-repo
index 8c59d76..f3e897e 100644
--- a/rel-eng/packages/spacewalk-repo
+++ b/rel-eng/packages/spacewalk-repo
@@ -1 +1 @@
-0.9-1 spec-tree/spacewalk-repo/
+1.0-2 spec-tree/spacewalk-repo/
diff --git a/spec-tree/spacewalk-repo/spacewalk-repo.spec b/spec-tree/spacewalk-repo/spacewalk-repo.spec
index 9813342..eb473c9 100644
--- a/spec-tree/spacewalk-repo/spacewalk-repo.spec
+++ b/spec-tree/spacewalk-repo/spacewalk-repo.spec
@@ -1,7 +1,7 @@
Summary: Spacewalk packages yum repository configuration
Name: spacewalk-repo
Version: 1.0
-Release: 1%{?dist}
+Release: 2%{?dist}
License: GPLv2
Group: System Environment/Base
# This src.rpm is cannonical upstream
@@ -67,6 +67,9 @@ rm -rf $RPM_BUILD_ROOT
%config %{_sysconfdir}/yum.repos.d/spacewalk-client.repo
%changelog
+* Wed Apr 28 2010 Shannon Hughes <shughes(a)redhat.com> 1.0-2
+- modify repo version (shughes(a)redhat.com)
+
* Thu Feb 11 2010 Michael Mraka <michael.mraka(a)redhat.com> 0.9-1
- pointed to Spacewalk 0.9 repo
13 years, 11 months
Branch 'SPACEWALK-1.0' - spec-tree/spacewalk-repo
by Shannon Hughes
spec-tree/spacewalk-repo/spacewalk-repo.spec | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 26b675622023cc6c26b82b465d713cb5137a1961
Author: Shannon Hughes <shughes(a)redhat.com>
Date: Wed Apr 28 14:28:44 2010 -0400
modify repo version
diff --git a/spec-tree/spacewalk-repo/spacewalk-repo.spec b/spec-tree/spacewalk-repo/spacewalk-repo.spec
index a71e2de..9813342 100644
--- a/spec-tree/spacewalk-repo/spacewalk-repo.spec
+++ b/spec-tree/spacewalk-repo/spacewalk-repo.spec
@@ -1,6 +1,6 @@
Summary: Spacewalk packages yum repository configuration
Name: spacewalk-repo
-Version: 0.9
+Version: 1.0
Release: 1%{?dist}
License: GPLv2
Group: System Environment/Base
13 years, 11 months
java/code
by Partha Aji
java/code/src/com/redhat/rhn/manager/system/DuplicateSystemGrouping.java | 1 -
1 file changed, 1 deletion(-)
New commits:
commit f6e697bc7ade339123346384e1ded9da3e4396f0
Author: Partha Aji <paji(a)redhat.com>
Date: Wed Apr 28 13:36:51 2010 -0400
Fixed a Compile typo to work with 1.5 compiler
diff --git a/java/code/src/com/redhat/rhn/manager/system/DuplicateSystemGrouping.java b/java/code/src/com/redhat/rhn/manager/system/DuplicateSystemGrouping.java
index 7ca4ff3..3f2f6b1 100644
--- a/java/code/src/com/redhat/rhn/manager/system/DuplicateSystemGrouping.java
+++ b/java/code/src/com/redhat/rhn/manager/system/DuplicateSystemGrouping.java
@@ -91,7 +91,6 @@ public class DuplicateSystemGrouping implements Expandable, Identifiable {
/**
* {@inheritDoc}
*/
- @Override
public Long getId() {
return Long.valueOf(key.hashCode());
}
13 years, 11 months