Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

plugging lantorrent daemon into the daemon management

removed the need for group id et all from workspace control
  • Loading branch information...
commit f056cf6ccd7254d43af4f2b8c7cac4d55e048c95 1 parent 3c63e29
BuzzTroll authored
View
13 control/src/python/workspacecontrol/defaults/imageprocurement/propagate_lantorrent.py
@@ -94,7 +94,7 @@ def _lt_command(self, local, remote):
ra = remote.split("?", 1)
if len(ra) != 2:
- raise InvalidInput("invalid lantorrent url, %s. It must contain parameters for groupid groupcount and remoteexe" % (remote))
+ raise InvalidInput("invalid lantorrent url, %s. It must contain parameters the remoteexe" % (remote))
url = ra[0]
lt_exe = ra[1]
@@ -119,21 +119,12 @@ def _lt_command(self, local, remote):
else:
self.c.log.debug("using the program runner for ssh account")
- try:
- group_id = self.p.get_arg_or_none(wc_args.GROUP_TRANSFER_ID)
- group_count = self.p.get_arg_or_none(wc_args.GROUP_COUNT)
- group_count = int(group_count)
- except Exception, ex:
- self.c.log.debug("error parsing query string for lantorrent %s" % (str(ex)))
- raise InvalidInput("invalid lantorrent url %s. You must have parametes for remoteexe,groupid, and groupcount." % (remote))
-
-
if xfer_user:
xfer_user = xfer_user + "@"
else:
xfer_user = ""
rid = str(uuid.uuid1())
- cmd = self.ssh + " -p %d %s%s %s %s %s %s %d %s:%d" % (xfer_port, xfer_user, xfer_host, lt_exe, xfer_path, local, group_id, group_count, self.ltip, self.ltport, rid)
+ cmd = self.ssh + " -p %d %s%s %s %s %s %s:%d" % (xfer_port, xfer_user, xfer_host, lt_exe, xfer_path, local, rid, self.ltip, self.ltport)
self.c.log.debug("lantorrent command %s " % (cmd))
View
8 control/src/python/workspacecontrol/main/wc_args.py
@@ -69,14 +69,6 @@ def __repr__(self):
DRYRUN.help = "Do as little as possible 'for real', will still affect filesystem, for example logs and information persistence"
a.append(DRYRUN)
-GROUP_TRANSFER_ID = ControlArg("group-transfer-id", None)
-GROUP_TRANSFER_ID.help = "Group transfer ID for cluster deployment"
-a.append(GROUP_TRANSFER_ID)
-
-GROUP_COUNT = ControlArg("group-count", None)
-GROUP_COUNT.help = "Total nimber of members of a cluster group"
-a.append(GROUP_COUNT)
-
KERNEL = ControlArg("kernel", "-k", metavar="FILENAME (not path)")
KERNEL.help = "Override the configured kernel"
a.append(KERNEL)
View
1  home/libexec/nimbusconfigure.py
@@ -34,6 +34,7 @@
services.wait: 10
web.enabled: False
cumulus.enabled: True
+lantorrent.enabled: False
"""
CONFIG_STATE_PATH = 'nimbus-setup.conf'
View
18 home/libexec/nimbusctl.py
@@ -42,7 +42,8 @@
sys.exit(_NO_CONFIG_ERROR)
web_enabled = config.getboolean('nimbussetup', 'web.enabled')
services_enabled = config.getboolean('nimbussetup', 'services.enabled')
-cumulus_enabled = config.getboolean('nimbussetup', 'services.enabled')
+cumulus_enabled = config.getboolean('nimbussetup', 'cumulus.enabled')
+lantorrent_enabled = config.getboolean('nimbussetup', 'lantorrent.enabled')
if not (web_enabled or services_enabled or cumulus_enabled):
sys.exit("Neither Nimbus services nor Nimbus web are enabled. "+
@@ -107,6 +108,21 @@
postStartDelay=5
))
+if lantorrent_enabled:
+ LT_HOME = os.path.join(NIMBUS_HOME, "lantorrent/")
+ LT_SERVICE_EXE = os.path.join(LT_HOME, "bin/lt-daemon")
+ if not os.path.exists(LT_SERVICE_EXE):
+ sys.exit("The services executable does not exist: " +
+ LT_SERVICE_EXE)
+ ProcessManager.add( Process(
+ name = "lantorrent",
+ desc = "Lantorrent services",
+ program = LT_SERVICE_EXE,
+ args = [],
+ workingDir = LT_HOME,
+ postStartDelay=2
+ ))
+
argv = sys.argv
if len(argv) == 2:
View
20 service/service/java/source/src/org/globus/workspace/service/binding/vm/VirtualMachine.java
@@ -49,9 +49,6 @@
private CustomizationNeed[] customizationNeeds;
private String mdUserData;
-
- private int groupCount;
- private String groupTransferID;
//requested vmm type
private String vmm;
//requested vmm version
@@ -147,23 +144,6 @@ public void setMdUserData(String mdUserData) {
this.mdUserData = mdUserData;
}
- public String getGroupTransferID() {
- return this.groupTransferID;
- }
-
- public void setGroupTransferID(String groupTransferID) {
- this.groupTransferID = groupTransferID;
- }
-
-
- public int getGroupCount() {
- return this.groupCount;
- }
-
- public void setGroupCount(int groupCount) {
- this.groupCount = groupCount;
- }
-
public synchronized void addCustomizationNeed(CustomizationNeed need) {
if (this.customizationNeeds == null) {
this.customizationNeeds = new CustomizationNeed[1];
View
27 service/service/java/source/src/org/globus/workspace/sqlauthz/AuthzDecisionLogic.java
@@ -39,7 +39,7 @@
private String repoDir = null;
private boolean schemePassthrough;
private String passthroughSchemes = null;
- private Resource lantorrentFetchPathResouce;
+ private Resource lantorrentFetchPathResouce = null;
public AuthzDecisionLogic(
DataSource ds,
@@ -121,30 +121,19 @@ protected String translateCumulus(
String rc = null;
String dataKey = this.authDB.getDataKey(fileIds[1]);
- if(scheme.equals("lantorrent"))
+ rc = scheme + "://" + this.getRepoHost() + "/" + dataKey;
+ if(lantorrentFetchPathResouce != null)
{
- if(vm.getGroupTransferID() == null || vm.getGroupCount() < 2)
+ try
{
- scheme = "scp";
+ String params = this.lantorrentFetchPathResouce.getFile().getAbsolutePath();
+ rc = rc + "?" + params;
}
- else
+ catch(Exception ex)
{
- rc = scheme + "://" + this.getRepoHost() + "/" + dataKey;
- try
- {
- String params = this.lantorrentFetchPathResouce.getFile().getAbsolutePath();
- rc = rc + "?" + params;
- }
- catch(Exception ex)
- {
- throw new AuthorizationException("fetch file doesnt exist");
- }
+ throw new AuthorizationException("fetch file doesnt exist");
}
}
- if(scheme.equals("scp"))
- {
- rc = scheme + "://" + this.getRepoHost() + "/" + dataKey;
- }
logger.debug("converted " + objectName + " to " + rc + "scheme " + scheme);
return rc;
View
12 service/service/java/source/src/org/globus/workspace/xen/XenUtil.java
@@ -170,17 +170,7 @@ public static ArrayList constructPropagateCommand(VirtualMachine vm,
break;
}
}
- }
-
- final String groupTransferID = vm.getGroupTransferID();
- if (groupTransferID != null) {
- cmd.add("--group-transfer-id");
- cmd.add(vm.getGroupTransferID());
-
- cmd.add("--group-count");
- String gc = new Integer(vm.getGroupCount()).toString();
- cmd.add(gc);
- }
+ }
if (notificationInfo != null) {
cmd.add("--notify");
Please sign in to comment.
Something went wrong with that request. Please try again.