Commit 58628ee0 authored by Leigh Stoller's avatar Leigh Stoller

Fixes; do not use dots in cooked mode experiment names. Add the

virtualization_type on to links so that emulated links work properly.
parent 568005a2
......@@ -267,16 +267,17 @@ sub CreateFromLocal($$$)
}
#
# XXX Form hrn from the domain.
# This mirrors the code in GeniSA.pm
#
my $hrn = "${PGENIDOMAIN}.slices." . $experiment->idx();
my $urn = GeniHRN::Generate( "@OURDOMAIN@", "slice",
"slices." . $experiment->idx() );
my $hrn = "CE" . $experiment->idx();
my $urn = GeniHRN::Generate("@OURDOMAIN@", "slice", $hrn);
$hrn = "${PGENIDOMAIN}.${hrn}";
#
# Generate a certificate.
#
$certificate = GeniCertificate->Create("slice", $urn, $hrn, $user->email());
$certificate = GeniCertificate->Create("slice", $urn, $hrn,
$user->email());
if (!defined($certificate)) {
print STDERR "GeniSlice::CreateFromLocal: ".
"Could not generate new certificate $experiment\n";
......
......@@ -2036,6 +2036,9 @@ sub GenVirtLans($)
'virtual_interface_id' => "$member1" },
],
};
if ($emulated) {
$ref->{'virtualization_type'} = $vlan->_encapstyle();
}
if (!exists($self->rspec()->{'link'})) {
$self->rspec()->{'link'} = [];
}
......@@ -2299,9 +2302,8 @@ sub GenVirtLans($)
$noderef->{'component_urn'} =
GeniHRN::Generate($authority, "node", "*");
}
push(@{ $self->rspec()->{'link'} },
{ 'virtual_id' => "$vname:$member",
my $ref = {
'virtual_id' => "$vname:$member",
# The list references are so XML::Simple does not
# turn them into attributes. Need a better solution.
'latency' => [0],
......@@ -2316,8 +2318,11 @@ sub GenVirtLans($)
{ 'virtual_node_id' => "lan-$vname",
'virtual_interface_id' => "$member" }
]
});
};
if ($emulated) {
$ref->{'virtualization_type'} = $vlan->_encapstyle();
}
push(@{ $self->rspec()->{'link'} }, $ref);
push(@nrefs, { 'virtual_id' => "$member"});
}
$noderef->{'interface'} = \@nrefs;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment