Skip to content

Commit

Permalink
Revert "Adds new endpoints for creating Runbook Runs"
Browse files Browse the repository at this point in the history
This reverts commit a6878a6.
  • Loading branch information
andrewabest committed Jun 22, 2020
1 parent a6878a6 commit 771e969
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 76 deletions.
63 changes: 0 additions & 63 deletions source/Octopus.Client/Model/RunbookRunParameters.cs

This file was deleted.

5 changes: 0 additions & 5 deletions source/Octopus.Client/Repositories/Async/RunbookRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,6 @@ public Task<RunbookRunPreviewResource> GetPreview(DeploymentPromotionTarget prom
}

public Task<RunbookRunResource> Run(RunbookResource runbook, RunbookRunResource runbookRun)
{
return Run(runbook, RunbookRunParameters.MapFrom(runbookRun));
}

public Task<RunbookRunResource> Run(RunbookResource runbook, RunbookRunParameters runbookRun)
{
return Client.Post<object, RunbookRunResource>(runbook.Link("CreateRunbookRun"), runbookRun);
}
Expand Down
10 changes: 2 additions & 8 deletions source/Octopus.Client/Repositories/RunbookRepository.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
using System.Linq;
using Octopus.Client.Editors;
using Octopus.Client.Model;

Expand All @@ -13,7 +12,7 @@ public interface IRunbookRepository : IFindByName<RunbookResource>, IGet<Runbook
RunbookRunPreviewResource GetPreview(DeploymentPromotionTarget promotionTarget);
RunbookRunResource Run(RunbookResource runbook, RunbookRunResource runbookRun);
}

class RunbookRepository : BasicRepository<RunbookResource>, IRunbookRepository
{
public RunbookRepository(IOctopusRepository repository)
Expand Down Expand Up @@ -45,15 +44,10 @@ public RunbookRunPreviewResource GetPreview(DeploymentPromotionTarget promotionT
{
return Client.Get<RunbookRunPreviewResource>(promotionTarget.Link("RunbookRunPreview"));
}
public RunbookRunResource Run(RunbookResource runbook, RunbookRunResource runbookRun)
{
return Run(runbook, RunbookRunParameters.MapFrom(runbookRun));
}

public RunbookRunResource Run(RunbookResource runbook, RunbookRunParameters runbookRun)
public RunbookRunResource Run(RunbookResource runbook, RunbookRunResource runbookRun)
{
return Client.Post<object, RunbookRunResource>(runbook.Link("CreateRunbookRun"), runbookRun);
}

}
}

0 comments on commit 771e969

Please sign in to comment.