diff --git a/protogeni/flack/src/com/flack/geni/GeniUniverse.as b/protogeni/flack/src/com/flack/geni/GeniUniverse.as index 5936caf5bf0fd33aeb845ab210a90a39384fea15..34e0a2b19c7dbea1bb59f10ff4e4926eb3000c5f 100644 --- a/protogeni/flack/src/com/flack/geni/GeniUniverse.as +++ b/protogeni/flack/src/com/flack/geni/GeniUniverse.as @@ -92,7 +92,7 @@ package com.flack.geni if(user.authority == null || user.authority.type != GeniAuthority.TYPE_EMULAB) SharedMain.tasker.add(new InitializeUserTaskGroup(user, true)); - SharedMain.tasker.add(new GetResourcesTaskGroup(managers.length == 0)); + SharedMain.tasker.add(new GetResourcesTaskGroup()); if(GeniMain.useSlice != null) { diff --git a/protogeni/flack/src/com/flack/geni/RspecUtil.as b/protogeni/flack/src/com/flack/geni/RspecUtil.as index 7d6608a1e7a4572c0af8831628dd6b3463af79eb..fbe4291546ef9e18166551b6f1f8ed8ff439379a 100644 --- a/protogeni/flack/src/com/flack/geni/RspecUtil.as +++ b/protogeni/flack/src/com/flack/geni/RspecUtil.as @@ -51,7 +51,7 @@ package com.flack.geni public static var clientNamespace:Namespace = new Namespace("client", "http://www.protogeni.net/resources/rspec/ext/client/1"); public static var historyNamespace:Namespace = new Namespace("history", "http://www.protogeni.net/resources/rspec/ext/history/1"); public static var emulabNamespace:Namespace = new Namespace("emulab", "http://www.protogeni.net/resources/rspec/ext/emulab/1"); - public static var sharedVlanNamespace:Namespace = new Namespace("vlan", "http://www.protogeni.net/resources/rspec/ext/shared-vlan/1"); + public static var sharedVlanNamespace:Namespace = new Namespace("vlan", "http://www.geni.net/resources/rspec/ext/shared-vlan/1"); public static var stitchingNamespace:Namespace = new Namespace("stitching", "http://hpn.east.isi.edu/rspec/ext/stitch/0.1/"); diff --git a/protogeni/flack/src/com/flack/geni/display/VirtualBoundInterfaceEditor.mxml b/protogeni/flack/src/com/flack/geni/display/VirtualBoundInterfaceEditor.mxml new file mode 100644 index 0000000000000000000000000000000000000000..f82fa911fabdf8a2233768a5a86cf86aaa238086 --- /dev/null +++ b/protogeni/flack/src/com/flack/geni/display/VirtualBoundInterfaceEditor.mxml @@ -0,0 +1,163 @@ + + + + + + + + + + + + + + + + + + + diff --git a/protogeni/flack/src/com/flack/geni/display/VirtualBoundInterfaceGridRenderer.mxml b/protogeni/flack/src/com/flack/geni/display/VirtualBoundInterfaceGridRenderer.mxml new file mode 100644 index 0000000000000000000000000000000000000000..b2e96340035914dbc556dc01f914a86efffcc428 --- /dev/null +++ b/protogeni/flack/src/com/flack/geni/display/VirtualBoundInterfaceGridRenderer.mxml @@ -0,0 +1,94 @@ + + + + + + + + + + + + + + + + diff --git a/protogeni/flack/src/com/flack/geni/display/areas/VirtualLinkArea.mxml b/protogeni/flack/src/com/flack/geni/display/areas/VirtualLinkArea.mxml index 06f1ae99d7e2e56532cf8e56d603043c910d7ed3..06ff6aff8ce5525c2abc7c52d053c3253c7abdb7 100644 --- a/protogeni/flack/src/com/flack/geni/display/areas/VirtualLinkArea.mxml +++ b/protogeni/flack/src/com/flack/geni/display/areas/VirtualLinkArea.mxml @@ -37,7 +37,7 @@ IN THE WORK. xmlns:areas="com.flack.geni.display.areas.*" xmlns:components="com.flack.shared.display.components.*" creationComplete="init()" - title="{link.clientId}" xmlns:areas1="com.flack.shared.display.areas.*"> + title="{link.clientId}" xmlns:areas1="com.flack.shared.display.areas.*" xmlns:display="com.flack.geni.display.*"> - + - + - - - + - + - + diff --git a/protogeni/flack/src/com/flack/geni/display/areas/VirtualNodeArea.mxml b/protogeni/flack/src/com/flack/geni/display/areas/VirtualNodeArea.mxml index 4fa1a88c68309194863a0e6f069dd46254068d95..948d98bfe381e4e62f922b21e0c890a09c29c81a 100644 --- a/protogeni/flack/src/com/flack/geni/display/areas/VirtualNodeArea.mxml +++ b/protogeni/flack/src/com/flack/geni/display/areas/VirtualNodeArea.mxml @@ -86,6 +86,7 @@ IN THE WORK. import com.flack.shared.utils.ColorUtil; import com.flack.shared.utils.ImageUtil; import com.flack.shared.utils.NetUtil; + import com.hurlant.math.bi_internal; import mx.collections.ArrayCollection; import mx.controls.Alert; @@ -202,6 +203,8 @@ IN THE WORK. loginGroup.visible = true; usernameText.text = node.services.loginServices[0].username; hostnameText.text = node.services.loginServices[0].FullHostname; + visitButton.toolTip = "Click to launch http://" + node.services.loginServices[0].hostname; + sshButton.toolTip = "Click to launch ssh://" + node.services.loginServices[0].FullLogin; } managerList.selectedItem = node.manager; @@ -259,7 +262,7 @@ IN THE WORK. source: iface, clientId: iface.clientId, macAddress: iface.macAddress, - physicalName: iface.physicalId.name, + binding: {physicalId: iface.physicalId.full, bound: iface.bound}, ipaddress: iface.ip.address, ipnetmask: iface.ip.netmask, iptype: iface.ip.type @@ -474,7 +477,7 @@ IN THE WORK. protected function hardwareList_valueCommitHandler(event:FlexEvent):void { - hardwareTypeCheckbox.selected = hardwareList.selectedItem != null + hardwareTypeCheckbox.selected = hardwareList.selectedItem != null; if(!okButton.enabled) okButton.enabled = node.hardwareType.name != hardwareList.selectedItem; } @@ -663,11 +666,15 @@ IN THE WORK. else node.hardwareType.name = hardwareList.selectedItem.name; node.physicalId.full = ""; + node.flackInfo.unbound = true; } else { node.hardwareType.name = ""; - node.physicalId.full = this.SelectedBoundNode.id.full; + var boundId:String = SelectedBoundNode.id.full; + if(node.physicalId.full != boundId) + node.flackInfo.unbound = false; + node.physicalId.full = boundId; } node.exclusive = exclusiveCheckbox.selected; @@ -727,7 +734,10 @@ IN THE WORK. { var iface:VirtualInterface = ifaceObj.source; iface.clientId = ifaceObj.clientId; + iface.ip.bound = iface.ip.address != ifaceObj.ipaddress; iface.ip.address = ifaceObj.ipaddress; + iface.bound = ifaceObj.binding.bound; + iface.physicalId.full = ifaceObj.binding.physicalId; iface.ip.netmask = ifaceObj.ipnetmask; iface.ip.type = ifaceObj.iptype; } @@ -849,8 +859,8 @@ IN THE WORK. - - + + - + - + + + + + + 0) - interfaceXml.@sliver_id = current.id.full; - if(current.physicalId != null && current.physicalId.full.length > 0) - interfaceXml.@component_id = current.physicalId.full; - } - if(current.ip != null && current.ip.address.length > 0 && !(removeNonexplicitBinding && current.ip.unset)) + if(includeManifest && current.id != null && current.id.full.length > 0) + interfaceXml.@sliver_id = current.id.full; + if(current.physicalId != null && current.physicalId.full.length > 0 && (includeManifest || current.bound)) + interfaceXml.@component_id = current.physicalId.full; + if(current.ip != null && current.ip.address.length > 0 && !(removeNonexplicitBinding && !current.ip.bound)) { var ipXml:XML = current.ip.extensions.createAndApply("ip"); ipXml.@address = current.ip.address; @@ -556,7 +553,8 @@ package com.flack.geni.tasks.process var interfaceFlackXml:XML = ; interfaceFlackXml.setNamespace(RspecUtil.flackNamespace); - interfaceFlackXml.@addressUnset = current.ip == null || current.ip.unset; + interfaceFlackXml.@addressBound = current.ip != null && current.ip.bound && !removeNonexplicitBinding; + interfaceFlackXml.@bound = current.bound; interfaceXml.appendChild(interfaceFlackXml); nodeXml.appendChild(interfaceXml); diff --git a/protogeni/flack/src/com/flack/geni/tasks/process/ParseAdvertisementTask.as b/protogeni/flack/src/com/flack/geni/tasks/process/ParseAdvertisementTask.as index eae71f86cfc7795893b19853dd766cf6f25b5f37..d063b5c3e6747002c43be6eb05772eef1b008188 100644 --- a/protogeni/flack/src/com/flack/geni/tasks/process/ParseAdvertisementTask.as +++ b/protogeni/flack/src/com/flack/geni/tasks/process/ParseAdvertisementTask.as @@ -539,7 +539,6 @@ package com.flack.geni.tasks.process manager.supportedSliverTypes.getOrCreateByName(hardwareTypeSliverType.name); } } - } } diff --git a/protogeni/flack/src/com/flack/geni/tasks/process/ParseRequestManifestTask.as b/protogeni/flack/src/com/flack/geni/tasks/process/ParseRequestManifestTask.as index ba7493a3eae4096cfeeac2ec2049350ef95dc77f..099db709ed8911ea32eed2aa3d6175a7e9006b28 100644 --- a/protogeni/flack/src/com/flack/geni/tasks/process/ParseRequestManifestTask.as +++ b/protogeni/flack/src/com/flack/geni/tasks/process/ParseRequestManifestTask.as @@ -519,7 +519,7 @@ package com.flack.geni.tasks.process for each(var ipXml:XML in interfaceXml.defaultNamespace::ip) { - virtualInterface.ip.unset = false; + virtualInterface.ip.bound = true; virtualInterface.ip.address = String(ipXml.@address); virtualInterface.ip.type = String(ipXml.@type); if(ipXml.@mask.length() == 1) @@ -534,12 +534,16 @@ package com.flack.geni.tasks.process var flackNamespace:Namespace = RspecUtil.flackNamespace; for each(var interfaceFlackXml:XML in interfaceXml.flackNamespace::interface_info) { - if(interfaceFlackXml.@addressUnset.length() == 1) + if(interfaceFlackXml.@addressBound.length() == 1) { - var addressUnset:Boolean = String(interfaceFlackXml.@addressUnset).toLowerCase() == "true" || String(interfaceFlackXml.@addressUnset) == "1"; - if(addressUnset && !parseManifest) + var addressBound:Boolean = String(interfaceFlackXml.@addressBound).toLowerCase() == "true" || String(interfaceFlackXml.@addressBound) == "1"; + if(!addressBound && !parseManifest) virtualInterface.ip = new Ip(); } + if(interfaceFlackXml.@bound.length() == 1) + { + virtualInterface.bound = String(interfaceFlackXml.@bound).toLowerCase() == "true" || String(interfaceFlackXml.@addressUnset) == "1"; + } } if(virtualNode.manager == sliver.manager) @@ -550,6 +554,15 @@ package com.flack.geni.tasks.process interfacesById[virtualInterface.id.full] = virtualInterface; } + // Bind interfaces that need it. + for each(var interfaceToTest:VirtualInterface in virtualNode.interfaces.collection) + { + if(interfaceToTest.physicalId.full.length == 0 && virtualNode.Bound) + { + interfaceToTest.physicalId.full = virtualNode.allocateExperimentalInterface().physicalId.full; + } + } + // go through the other children for each(var nodeChildXml:XML in nodeXml.children()) { diff --git a/protogeni/flack/src/com/flack/geni/tasks/xmlrpc/protogeni/ch/ListComponentsChTask.as b/protogeni/flack/src/com/flack/geni/tasks/xmlrpc/protogeni/ch/ListComponentsChTask.as index 99649d825498f478c83b2f90a24d0484eef2cadb..730a670088c3fff59ac8c7807091db50cab994e7 100644 --- a/protogeni/flack/src/com/flack/geni/tasks/xmlrpc/protogeni/ch/ListComponentsChTask.as +++ b/protogeni/flack/src/com/flack/geni/tasks/xmlrpc/protogeni/ch/ListComponentsChTask.as @@ -196,6 +196,8 @@ package com.flack.geni.tasks.xmlrpc.protogeni.ch GeniMain.geniUniverse.managers.add(newManager); + relatedTo.push(newManager); + addMessage( "Added manager", newManager.toString(), diff --git a/protogeni/flack/src/com/flack/shared/SharedMain.as b/protogeni/flack/src/com/flack/shared/SharedMain.as index 26295c34d4a6c54f940d37c6fa76275d7ebd299c..e5b72a856f4c9f757e7c13c6569b965f9951e55a 100644 --- a/protogeni/flack/src/com/flack/shared/SharedMain.as +++ b/protogeni/flack/src/com/flack/shared/SharedMain.as @@ -51,7 +51,7 @@ package com.flack.shared /** * Flack version */ - public static const version:String = "v14.41"; + public static const version:String = "v14.47"; public static const MODE_GENI:int = 0; public static const MODE_EMULAB:int = 1; diff --git a/protogeni/flack/src/com/flack/shared/tasks/xmlrpc/XmlrpcTask.as b/protogeni/flack/src/com/flack/shared/tasks/xmlrpc/XmlrpcTask.as index f1d79c5d1b2346f55b8d6d98dfcc5587a2e62e35..d4e015d8ed7ac9499b1c02c2e320ae9c6966e352 100644 --- a/protogeni/flack/src/com/flack/shared/tasks/xmlrpc/XmlrpcTask.as +++ b/protogeni/flack/src/com/flack/shared/tasks/xmlrpc/XmlrpcTask.as @@ -37,6 +37,7 @@ package com.flack.shared.tasks.xmlrpc import com.flack.shared.utils.NetUtil; import com.flack.shared.utils.StringUtil; import com.mattism.http.xmlrpc.ConnectionImpl; + import com.mattism.http.xmlrpc.JSLoader; import com.mattism.http.xmlrpc.MethodFault; import flash.display.Sprite; @@ -45,6 +46,7 @@ package com.flack.shared.tasks.xmlrpc import flash.events.IOErrorEvent; import flash.events.SecurityErrorEvent; import flash.events.TimerEvent; + import flash.net.URLLoader; import flash.utils.Timer; import mx.controls.Alert; @@ -176,7 +178,7 @@ package com.flack.shared.tasks.xmlrpc { clearFields(); createFields(); - server = new ConnectionImpl(url); + server = new ConnectionImpl(url, JSLoader); server.addEventListener(Event.COMPLETE, callSuccess); server.addEventListener(ErrorEvent.ERROR, callErrorFailure); server.addEventListener(IOErrorEvent.IO_ERROR, callErrorFailure); diff --git a/protogeni/flack/src/com/mattism/http/xmlrpc/ConnectionImpl.as b/protogeni/flack/src/com/mattism/http/xmlrpc/ConnectionImpl.as index 6c7a793756c59f70b8d221ade24688d0ab45becb..2e4f815a9ec5c46cf0282499956ee6d0a5aadec7 100644 --- a/protogeni/flack/src/com/mattism/http/xmlrpc/ConnectionImpl.as +++ b/protogeni/flack/src/com/mattism/http/xmlrpc/ConnectionImpl.as @@ -9,10 +9,10 @@ package com.mattism.http.xmlrpc { + import com.flack.geni.GeniMain; import com.flack.shared.SharedMain; import com.flack.shared.logging.LogMessage; import com.flack.shared.logging.Logger; - import com.flack.geni.GeniMain; import flash.events.ErrorEvent; import flash.events.Event; @@ -38,12 +38,12 @@ package com.mattism.http.xmlrpc public var _request : URLRequest; private var _rpc_response : Object; private var _parser : Parser; - public var _response:JSLoader; + public var _response:Object; private var _parsed_response : Object; private var _fault : MethodFault; - public function ConnectionImpl(url : String) + public function ConnectionImpl(url : String, loaderClass:Class) { //prepare method response handler //ignoreWhite = true; @@ -55,7 +55,7 @@ package com.mattism.http.xmlrpc _parser = new ParserImpl(); //init response - _response = new JSLoader(); + _response = new loaderClass(); _response.addEventListener(Event.COMPLETE, _onLoad); _response.addEventListener(SecurityErrorEvent.SECURITY_ERROR, securityError);