Skip to content

Commit

Permalink
Merge pull request #5 from EVOLVED-5G/sm_fix
Browse files Browse the repository at this point in the history
Fix SliceId expansion, exception on SingleSliceCreationTime.
  • Loading branch information
NaniteBased authored May 4, 2022
2 parents 5c85f3f + b29028f commit 0ad5273
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
**04/05/2022** [Version 3.3.1]

- Fix SliceId expansion, exception on SingleSliceCreationTime

**01/04/2022** [Version 3.3.0]

- TestCase definition Version 2
Expand Down
2 changes: 1 addition & 1 deletion Executor/Tasks/Run/single_slice_creation_time.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def Run(self):
self.Log(Level.INFO, f"Waiting for slice to be running. Timeout: {timeout}")
while True:
count += 1
status = Management.SliceManager().Check(sliceId).get('status', '<SliceManager check error>')
status = Management.SliceManager().CheckSlice(sliceId).get('status', '<SliceManager check error>')
self.Log(Level.DEBUG, f'Slice {sliceId} status: {status} (retry {count})')
if status == 'Running' or (timeout is not None and timeout >= count): break
else: sleep(1)
Expand Down
3 changes: 2 additions & 1 deletion Experiment/variable_expander.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ def expand(cls, item: str, context: Union[ExecutorBase, ExperimentRun], config:
# Dynamic values
"@{TempFolder}": context.TempFolder,
"@{ExecutionId}": context.ExecutionId,
"@{SliceId}": context.Params.get("SliceId", "None"),
"@{SliceId}": context.Params.get("DeployedSliceId", "None"),
"@{DeployedSliceId}": context.Params.get("DeployedSliceId", "None"),
"@{Application}": context.Descriptor.Application,
"@{JSONParameters}": dumps(context.Descriptor.Parameters, indent=None),
"@{ReservationTime}": duration,
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -630,7 +630,7 @@ Results\{Identifier}\{Date}-{ResultType}-{Identifier}.csv
It's possible to expand the value of some variables enclosed by @{ }. (Use quotes where required in order to generate
valid YAML format). Available values are:
- `@{ExecutionId}`: Experiment execution ID (unique identifier)
- `@{SliceId}`: ID of the slice deployed by the Slice Manager during the PreRun stage
- `@{SliceId}`, `@{DeployedSliceId}`: ID of the slice deployed by the Slice Manager during the PreRun stage
- `@{TempFolder}`: Temporal folder exclusive to the current executor, it's deleted when the experiment finishes.
- `@{Application}`: The `Application` field from the Experiment Descriptor
- `@{JSONParameters}`: The `Parameters` dictionary from the Experiment Descriptor, in JSON format (a single line string)
Expand Down

0 comments on commit 0ad5273

Please sign in to comment.