Skip to content

Commit

Permalink
Merge pull request #230 from aws/dev
Browse files Browse the repository at this point in the history
Release 0.8
  • Loading branch information
philasmar authored Jun 1, 2021
2 parents 98dca27 + 5906a2b commit 92c4f73
Show file tree
Hide file tree
Showing 7 changed files with 129 additions and 4 deletions.
Binary file added public.snk
Binary file not shown.
1 change: 0 additions & 1 deletion src/AWS.Deploy.CLI/AWS.Deploy.CLI.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
<PackageTags>AWS;Amazon;ElasticBeanstalk;ECS;Deploy</PackageTags>
<AssemblyName>AWS.Deploy.CLI</AssemblyName>
<RootNamespace>AWS.Deploy.CLI</RootNamespace>
<LangVersion>Latest</LangVersion>
<PackageIcon>icon.png</PackageIcon>
<PackageProjectUrl>https://github.com/aws/aws-dotnet-deploy</PackageProjectUrl>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

<PropertyGroup>
<TargetFrameworks>netstandard2.0</TargetFrameworks>
<Product>AWS .NET deployment tool Server Mode Client</Product>
<Description>Package to access the APIs exposed by the deployment tool server mode. This package is not intended for direct usage.</Description>
<PackageId>AWS.Deploy.ServerMode.Client</PackageId>
<PackageTags>AWS;Amazon;Deploy;ServerMode</PackageTags>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<PackageIcon>icon.png</PackageIcon>
<PackageProjectUrl>https://github.com/aws/aws-dotnet-deploy</PackageProjectUrl>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>..\..\public.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>

<ItemGroup>
Expand All @@ -10,4 +19,14 @@
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
</ItemGroup>

<ItemGroup>
<None Include="..\..\LICENSE" Pack="true" PackagePath="" />
<None Include="..\..\NOTICE" Pack="true" PackagePath="" />
<None Include="..\..\THIRD_PARTY_LICENSES" Pack="true" PackagePath="" />
</ItemGroup>

<ItemGroup>
<None Include="..\..\icon.png" Pack="true" PackagePath="" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,20 @@

namespace AWS.Deploy.ServerMode.Client
{
public class DeploymentCommunicationClient : IDisposable
public interface IDeploymentCommunicationClient : IDisposable
{
Action<string>? ReceiveLogDebugLine { get; set; }

Action<string>? ReceiveLogErrorMessageLine { get; set; }

Action<string>? ReceiveLogMessageLineAction { get; set; }

Action<string>? ReceiveLogAllLogAction { get; set; }

Task JoinSession(string sessionId);
}

public class DeploymentCommunicationClient : IDeploymentCommunicationClient
{
private bool _disposedValue;

Expand Down
95 changes: 94 additions & 1 deletion src/AWS.Deploy.ServerMode.Client/RestAPI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,100 @@ namespace AWS.Deploy.ServerMode.Client
using System = global::System;

[System.CodeDom.Compiler.GeneratedCode("NSwag", "13.10.9.0 (NJsonSchema v10.4.1.0 (Newtonsoft.Json v12.0.0.0))")]
public partial class RestAPIClient
public partial interface IRestAPIClient
{
/// <summary>Start a deployment session. A session id will be generated. This session id needs to be passed in future API calls to configure and execute deployment.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<StartDeploymentSessionOutput> StartDeploymentSessionAsync(StartDeploymentSessionInput body);

/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
/// <summary>Start a deployment session. A session id will be generated. This session id needs to be passed in future API calls to configure and execute deployment.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<StartDeploymentSessionOutput> StartDeploymentSessionAsync(StartDeploymentSessionInput body, System.Threading.CancellationToken cancellationToken);

/// <summary>Closes the deployment session. This removes any session state for the session id.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task CloseDeploymentSessionAsync(string sessionId);

/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
/// <summary>Closes the deployment session. This removes any session state for the session id.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task CloseDeploymentSessionAsync(string sessionId, System.Threading.CancellationToken cancellationToken);

/// <summary>Set the target recipe and name for the deployment.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task SetDeploymentTargetAsync(string sessionId, SetDeploymentTargetInput body);

/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
/// <summary>Set the target recipe and name for the deployment.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task SetDeploymentTargetAsync(string sessionId, SetDeploymentTargetInput body, System.Threading.CancellationToken cancellationToken);

/// <summary>Gets the list of compatible deployments for the session's project. The list is ordered with the first recommendation in the list being the most compatible recommendation.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<GetRecommendationsOutput> GetRecommendationsAsync(string sessionId);

/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
/// <summary>Gets the list of compatible deployments for the session's project. The list is ordered with the first recommendation in the list being the most compatible recommendation.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<GetRecommendationsOutput> GetRecommendationsAsync(string sessionId, System.Threading.CancellationToken cancellationToken);

/// <summary>Gets the list of existing deployments that are compatible with the session's project.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<GetExistingDeploymentsOutput> GetExistingDeploymentsAsync(string sessionId);

/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
/// <summary>Gets the list of existing deployments that are compatible with the session's project.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<GetExistingDeploymentsOutput> GetExistingDeploymentsAsync(string sessionId, System.Threading.CancellationToken cancellationToken);

/// <summary>Begin execution of the deployment.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task StartDeploymentAsync(string sessionId);

/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
/// <summary>Begin execution of the deployment.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task StartDeploymentAsync(string sessionId, System.Threading.CancellationToken cancellationToken);

/// <summary>Gets the status of the deployment.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<GetDeploymentStatusOutput> GetDeploymentStatusAsync(string sessionId);

/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
/// <summary>Gets the status of the deployment.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<GetDeploymentStatusOutput> GetDeploymentStatusAsync(string sessionId, System.Threading.CancellationToken cancellationToken);

/// <summary>Gets the health of the deployment tool. Use this API after starting the command line to see if the tool is ready to handle requests.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<HealthStatusOutput> HealthAsync();

/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
/// <summary>Gets the health of the deployment tool. Use this API after starting the command line to see if the tool is ready to handle requests.</summary>
/// <returns>Success</returns>
/// <exception cref="ApiException">A server side error occurred.</exception>
System.Threading.Tasks.Task<HealthStatusOutput> HealthAsync(System.Threading.CancellationToken cancellationToken);

}

[System.CodeDom.Compiler.GeneratedCode("NSwag", "13.10.9.0 (NJsonSchema v10.4.1.0 (Newtonsoft.Json v12.0.0.0))")]
public partial class RestAPIClient : IRestAPIClient
{
private string _baseUrl = "";
private ServerModeHttpClient _httpClient;
Expand Down
1 change: 1 addition & 0 deletions src/AWS.Deploy.ServerMode.ClientGenerator/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ static async Task Main(string[] args)
var settings = new CSharpClientGeneratorSettings
{
ClassName = "RestAPIClient",
GenerateClientInterfaces = true,
CSharpGeneratorSettings =
{
Namespace = "AWS.Deploy.ServerMode.Client",
Expand Down
2 changes: 1 addition & 1 deletion version.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"$schema": "https://raw.githubusercontent.com/dotnet/Nerdbank.GitVersioning/master/src/NerdBank.GitVersioning/version.schema.json",
"version": "0.7",
"version": "0.8",
"publicReleaseRefSpec": [
".*"
],
Expand Down

0 comments on commit 92c4f73

Please sign in to comment.