From: Julien Tribino Date: Tue, 25 Mar 2014 09:58:12 +0000 (+0100) Subject: Update the OMF 5.4 part for the netflix experiment X-Git-Tag: nepi-3.1.0~94 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=0faa779327737ead70ec8b263a44a977335b01bb;p=nepi.git Update the OMF 5.4 part for the netflix experiment --- diff --git a/src/nepi/resources/omf/interface.py b/src/nepi/resources/omf/interface.py index 1fcd59b9..d6ce0a17 100644 --- a/src/nepi/resources/omf/interface.py +++ b/src/nepi/resources/omf/interface.py @@ -180,16 +180,20 @@ class OMFWifiInterface(OMFResource): raise RuntimeError, msg # Just for information - self.debug(" " + self.get_rtype() + " ( Guid : " + str(self._guid) +") : " + \ + self.info(" " + self.get_rtype() + " ( Guid : " + str(self._guid) +") : " + \ self.get('mode') + " : " + self.get('type') + " : " + \ - self.get('essid') + " : " + self.get('ip')) + self.get('essid') + " : " + self.get('ip') + " : " + str(self.state)) # Check if the node is already deployed if self.state < ResourceState.PROVISIONED: if self._conf == False: self._conf = self.configure_iface() + res = False if self._conf == True: - self.configure_ip() + res = self.configure_ip() + + if not (res or self._conf): + return super(OMFWifiInterface, self).do_deploy() diff --git a/src/nepi/resources/omf/omf_api.py b/src/nepi/resources/omf/omf_api.py index 5def17b9..edd13971 100644 --- a/src/nepi/resources/omf/omf_api.py +++ b/src/nepi/resources/omf/omf_api.py @@ -236,6 +236,7 @@ class OMFAPI(Logger): :type value: str """ + payload = self._message.configure_function(hostname, value, attribute) xmpp_node = self._host_session_id(hostname) self._client.publish(payload, xmpp_node)