From: rmccabe@sourceware.org <rmccabe@sourceware.org>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] conga ./conga.spec.in.in luci/cluster/resource ...
Date: 6 Nov 2007 23:05:08 -0000 [thread overview]
Message-ID: <20071106230508.23473.qmail@sourceware.org> (raw)
CVSROOT: /cvs/cluster
Module name: conga
Changes by: rmccabe at sourceware.org 2007-11-06 23:05:07
Modified files:
. : conga.spec.in.in
luci/cluster : resource-form-macros
luci/site/luci/Extensions: LuciClusterInfo.py
cluster_adapters.py
luci/site/luci/Extensions/ClusterModel: ModelBuilder.py
Log message:
fix 264161
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/conga.spec.in.in.diff?cvsroot=cluster&r1=1.89&r2=1.90
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/resource-form-macros.diff?cvsroot=cluster&r1=1.44&r2=1.45
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/LuciClusterInfo.py.diff?cvsroot=cluster&r1=1.16&r2=1.17
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/cluster_adapters.py.diff?cvsroot=cluster&r1=1.274&r2=1.275
http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/ClusterModel/ModelBuilder.py.diff?cvsroot=cluster&r1=1.12&r2=1.13
--- conga/conga.spec.in.in 2007/11/06 19:58:00 1.89
+++ conga/conga.spec.in.in 2007/11/06 23:05:06 1.90
@@ -300,6 +300,7 @@
- Fixed bz320411 (conga should use the node name in cluster.conf and not FQDN for fencing)
- Fixed bz253727 (RFE: graphical view should be default in partiton tables view)
- Fixed bz337041 (Add option to not fail-back service)
+- Fixed bz264161 (RFE: support setting the "__independent_subtree" attribute on cluster resources)
* Mon Aug 27 2007 Ryan McCabe <rmccabe@redhat.com> 0.10.0-6
- Fixed bz253783
--- conga/luci/cluster/resource-form-macros 2007/10/09 20:24:42 1.44
+++ conga/luci/cluster/resource-form-macros 2007/11/06 23:05:06 1.45
@@ -14,19 +14,32 @@
<body>
<div metal:define-macro="res_form_footer" tal:omit-tag="">
- <p class="hbSubmit">
- <input type="button"
- onClick="validate_form(this.form);"
- value="Submit"
- tal:condition="not: sinfo" />
+ <tal:block tal:condition="not:sinfo">
+ <p class="hbSubmit">
+ <input type="button" value="Submit"
+ onClick="validate_form(this.form)" />
+ </p>
+ </tal:block>
+
+ <tal:block tal:condition="sinfo">
+ <table tal:condition="exists:res">
+ <tr>
+ <td>This resource is an independent subtree</td>
+ <td tal:define="isubtree res/attrs/__independent_subtree|nothing">
+ <input class="vanilla" type="checkbox"
+ name="__independent_subtree"
+ tal:attributes="checked python:(isubtree in ['1', 'true', 'True', True, 1]) and 'checked' or None" />
+ </td>
+ </tr>
+ </table>
- <tal:block tal:condition="sinfo">
+ <p class="hbSubmit">
<input type="button" value="Add a child"
onClick="add_child_resource(this.form)" />
<input type="button" value="Delete this resource"
onClick="delete_resource(this.form)" />
- </tal:block>
- </p>
+ </p>
+ </tal:block>
<tal:block tal:condition="not:exists:res"
tal:define="global expclass string: invisible expander" />
--- conga/luci/site/luci/Extensions/LuciClusterInfo.py 2007/11/06 19:58:00 1.16
+++ conga/luci/site/luci/Extensions/LuciClusterInfo.py 2007/11/06 23:05:07 1.17
@@ -287,10 +287,12 @@
#Note: Final version needs all resource attrs
if child.isRefObject() is True:
+ child_obj = child.getObj()
+ rc_map['attrs'] = child.getAttributes().copy()
+ rc_map['attrs'].update(child_obj.getAttributes())
+ rc_map['type'] = child_obj.getResourceType()
rc_map['ref_object'] = True
- rc_map['tag_name'] = child.getObj().TAG_NAME
- rc_map['type'] = child.getObj().getResourceType()
- rc_map['attrs'] = child.getObj().getAttributes()
+ rc_map['tag_name'] = child_obj.TAG_NAME
else:
rc_map['tag_name'] = child.TAG_NAME
rc_map['type'] = child.getResourceType()
--- conga/luci/site/luci/Extensions/cluster_adapters.py 2007/11/06 19:58:00 1.274
+++ conga/luci/site/luci/Extensions/cluster_adapters.py 2007/11/06 23:05:07 1.275
@@ -809,6 +809,11 @@
if resObj is None:
return (False, { 'errors': [ 'An error occurred while adding %s' % res_type ]})
+
+ if dummy_form.has_key('__independent_subtree'):
+ resObj.addAttribute('__independent_subtree', '1')
+ else:
+ resObj.removeAttribute('__independent_subtree')
form_hash[form_id]['obj'] = resObj
if len(errors) > 0:
--- conga/luci/site/luci/Extensions/ClusterModel/ModelBuilder.py 2007/10/03 19:40:37 1.12
+++ conga/luci/site/luci/Extensions/ClusterModel/ModelBuilder.py 2007/11/06 23:05:07 1.13
@@ -413,6 +413,15 @@
if result is False:
return result
+ try:
+ entity_attr = entity.getAttributes()
+ if entity_attr is not None:
+ for i in entity_attr.iterkeys():
+ if not rf.attr_hash.has_key(i):
+ rf.addAttribute(i, entity_attr[i])
+ except:
+ pass
+
if parent is None: #Must be a service
self.resourcemanager_ptr.addChild(rf)
self.resourcemanager_ptr.removeChild(entity)
next reply other threads:[~2007-11-06 23:05 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-06 23:05 rmccabe [this message]
-- strict thread matches above, loose matches on Subject: below --
2008-05-12 17:37 [Cluster-devel] conga ./conga.spec.in.in luci/cluster/resource rmccabe
2008-04-18 4:19 rmccabe
2008-04-18 4:15 rmccabe
2008-02-07 6:53 rmccabe
2007-10-09 20:24 rmccabe
2007-09-20 21:03 rmccabe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20071106230508.23473.qmail@sourceware.org \
--to=rmccabe@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).