WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] Added backreference from PIF_metrics to P

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] Added backreference from PIF_metrics to PIF, and added a uuid to the session
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 31 Jan 2007 07:05:20 -0800
Delivery-date: Wed, 31 Jan 2007 07:07:33 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Ewan Mellor <ewan@xxxxxxxxxxxxx>
# Date 1170165224 0
# Node ID bb34cc5784c13fffc9f8663d4c2c61db5ad2e284
# Parent  aff5b538fcdf53dc7b232bc6d20a8b6458ed3c10
Added backreference from PIF_metrics to PIF, and added a uuid to the session
record.

Signed-off-by: Ewan Mellor <ewan@xxxxxxxxxxxxx>
---
 tools/python/xen/xend/XendAPI.py |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diff -r aff5b538fcdf -r bb34cc5784c1 tools/python/xen/xend/XendAPI.py
--- a/tools/python/xen/xend/XendAPI.py  Tue Jan 30 13:52:03 2007 +0000
+++ b/tools/python/xen/xend/XendAPI.py  Tue Jan 30 13:53:44 2007 +0000
@@ -497,7 +497,8 @@ class XendAPI(object):
         auth_manager().logout(session)
         return xen_api_success_void()
     def session_get_record(self, session):
-        record = {'this_host': XendNode.instance().uuid,
+        record = {'uuid'     : session,
+                  'this_host': XendNode.instance().uuid,
                   'this_user': auth_manager().get_user(session)}
         return xen_api_success(record)
     def session_get_all(self):
@@ -902,7 +903,8 @@ class XendAPI(object):
     # Xen API: Class PIF_metrics
     # ----------------------------------------------------------------
 
-    PIF_metrics_attr_ro = ['io_read_kbs',
+    PIF_metrics_attr_ro = ['PIF',
+                           'io_read_kbs',
                            'io_write_kbs']
     PIF_metrics_attr_rw = []
     PIF_methods = []
@@ -912,6 +914,9 @@ class XendAPI(object):
 
     def PIF_metrics_get_record(self, _, ref):
         return xen_api_success(self._PIF_metrics_get(ref).get_record())
+
+    def PIF_metrics_get_PIF(self, _, ref):
+        return xen_api_success(self._PIF_metrics_get(ref).pif.uuid)
 
     def PIF_metrics_get_io_read_kbs(self, _, ref):
         return xen_api_success(self._PIF_metrics_get(ref).get_io_read_kbs())

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] Added backreference from PIF_metrics to PIF, and added a uuid to the session, Xen patchbot-unstable <=