Skip to content

Commit cc06c8f

Browse files
committed
Merge release/1.7.0
2 parents 0932254 + eec28e8 commit cc06c8f

File tree

109 files changed

+2634
-18382
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

109 files changed

+2634
-18382
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# OpenStack.NET
22

3+
Need Help? Email us at [sdk-support@rackspace.com](mailto:sdk-support@rackspace.com).
4+
35
[![Join the chat at https://gitter.im/openstacknetsdk/openstack.net](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/openstacknetsdk/openstack.net?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
46

57
OpenStack.NET is an OpenStack .NET SDK, written for the Microsoft .NET platform, is designed to enable developers to seamlessly work with

src/Documentation/AdditionalReferenceDocumentation.shfbproj

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,13 @@
2727
<Argument Key="maxVersionParts" Value="" xmlns="" />
2828
</TransformComponentArguments>
2929
<DocumentationSources>
30-
<DocumentationSource sourceFile="..\packages\Newtonsoft.Json.6.0.4\lib\net40\Newtonsoft.Json.dll" />
31-
<DocumentationSource sourceFile="..\packages\Newtonsoft.Json.6.0.4\lib\net40\Newtonsoft.Json.xml" />
30+
<DocumentationSource sourceFile="..\packages\Newtonsoft.Json.8.0.3\lib\net40\Newtonsoft.Json.dll" />
31+
<DocumentationSource sourceFile="..\packages\Newtonsoft.Json.8.0.3\lib\net40\Newtonsoft.Json.xml" />
3232
<DocumentationSource sourceFile="..\packages\SimpleRESTServices.1.3.0.1\lib\net40\SimpleRESTServices.dll" />
3333
<DocumentationSource sourceFile="..\packages\SimpleRESTServices.1.3.0.1\lib\net40\SimpleRESTServices.xml" />
3434
</DocumentationSources>
35+
<PlugInConfigurations>
36+
</PlugInConfigurations>
3537
</PropertyGroup>
3638
<!-- There are no properties for these groups. AnyCPU needs to appear in order for Visual Studio to perform
3739
the build. The others are optional common platform types that may appear. -->
@@ -56,4 +58,4 @@
5658
</ItemGroup>
5759
<!-- Import the SHFB build targets -->
5860
<Import Project="$(SHFBROOT)\SandcastleHelpFileBuilder.targets" />
59-
</Project>
61+
</Project>

src/Documentation/Documentation.v4.0.shfbproj

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -99,14 +99,8 @@
9999
</versions>
100100
</configuration>
101101
</PlugInConfig>
102-
<PlugInConfig id="Additional Reference Links" enabled="True">
103-
<configuration>
104-
<targets>
105-
<target htmlSdkLinkType="None" help2SdkLinkType="Index" helpViewerSdkLinkType="Id" websiteSdkLinkType="None" helpFileProject="AdditionalReferenceDocumentation.shfbproj" />
106-
</targets>
107-
</configuration>
108-
</PlugInConfig>
109-
</PlugInConfigurations>
102+
<PlugInConfig id="Additional Reference Links" enabled="True"><configuration><targets><target htmlSdkLinkType="None" help2SdkLinkType="Index" helpViewerSdkLinkType="Id" websiteSdkLinkType="None" helpFileProject="AdditionalReferenceDocumentation.shfbproj" /></targets></configuration></PlugInConfig>
103+
<PlugInConfig id="Assembly Binding Redirection" enabled="True"><configuration useGAC="false"><assemblyBinding><dependentAssembly><assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" /><bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" /></dependentAssembly></assemblyBinding><ignoreIfUnresolved /></configuration></PlugInConfig></PlugInConfigurations>
110104
<ApiFilter>
111105
<Filter entryType="Namespace" fullName="Flurl.Extensions" isExposed="False" />
112106
<Filter entryType="Namespace" fullName="Flurl.Http" isExposed="False" />
@@ -129,11 +123,12 @@
129123
<HelpAttributes />
130124
<NamespaceSummaries>
131125
<NamespaceSummaryItem name="Flurl.Http" isDocumented="False" />
132-
<NamespaceSummaryItem name="OpenStack.Compute.v2_1.Serialization" isDocumented="False" />
133-
<NamespaceSummaryItem name="OpenStack.Compute.v2_2.Serialization" isDocumented="False" />
134-
<NamespaceSummaryItem name="OpenStack.Compute.v2_6.Serialization" isDocumented="False" />
135-
<NamespaceSummaryItem name="OpenStack.Serialization" isDocumented="False" />
136-
<NamespaceSummaryItem name="OpenStack.Synchronous" isDocumented="True" /></NamespaceSummaries>
126+
<NamespaceSummaryItem name="OpenStack.Compute.v2_1.Serialization" isDocumented="False" />
127+
<NamespaceSummaryItem name="OpenStack.Compute.v2_2.Serialization" isDocumented="False" />
128+
<NamespaceSummaryItem name="OpenStack.Compute.v2_6.Serialization" isDocumented="False" />
129+
<NamespaceSummaryItem name="OpenStack.Serialization" isDocumented="False" />
130+
<NamespaceSummaryItem name="OpenStack.Synchronous" isDocumented="True" />
131+
</NamespaceSummaries>
137132
<BuildLogFile />
138133
<HtmlHelp1xCompilerPath />
139134
<HtmlHelp2xCompilerPath />
@@ -190,4 +185,4 @@
190185
</ItemGroup>
191186
<!-- Import the SHFB build targets -->
192187
<Import Project="$(SHFBROOT)\SandcastleHelpFileBuilder.targets" />
193-
</Project>
188+
</Project>

src/Documentation/History/Current/Documentation.Current.shfbproj

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,17 @@
7272
<HelpAttributes />
7373
<NamespaceSummaries />
7474
<PlugInConfigurations>
75+
<PlugInConfig id="Assembly Binding Redirection" enabled="True">
76+
<configuration useGAC="false">
77+
<assemblyBinding>
78+
<dependentAssembly>
79+
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
80+
<bindingRedirect oldVersion="0.0.0.0-8.0.0.0" newVersion="8.0.0.0" />
81+
</dependentAssembly>
82+
</assemblyBinding>
83+
<ignoreIfUnresolved />
84+
</configuration>
85+
</PlugInConfig>
7586
</PlugInConfigurations>
7687
<BuildLogFile />
7788
<HtmlHelp1xCompilerPath />
@@ -94,4 +105,4 @@
94105
</PropertyGroup>
95106
<!-- Import the SHFB build targets -->
96107
<Import Project="$(SHFBROOT)\SandcastleHelpFileBuilder.targets" />
97-
</Project>
108+
</Project>

src/Documentation/History/Current/packages.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
<package id="Flurl.Http.Signed" version="0.6.2.2015062601" targetFramework="net45" />
55
<package id="Flurl.Signed" version="1.0.8" targetFramework="net45" />
66
<package id="Marvin.JsonPatch.Signed" version="0.7.0" targetFramework="net45" />
7-
<package id="Newtonsoft.Json" version="6.0.4" targetFramework="net45" />
7+
<package id="Newtonsoft.Json" version="8.0.3" targetFramework="net45" />
88
<package id="SimpleRESTServices" version="1.3.0.1" targetFramework="net40" />
99
</packages>
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
using Newtonsoft.Json;
2+
using OpenStack.Serialization;
3+
4+
namespace OpenStack.Compute.v2_1
5+
{
6+
/// <summary>
7+
/// Associates a floating IP address to a server.
8+
/// </summary>
9+
[JsonConverterWithConstructor(typeof(RootWrapperConverter), "addFloatingIp")]
10+
public class AssociateFloatingIPRequest
11+
{
12+
/// <summary>
13+
/// Initializes a new instance of the <see cref="AssociateFloatingIPRequest"/> class.
14+
/// </summary>
15+
/// <param name="floatingIPAddress">The floating ip address.</param>
16+
public AssociateFloatingIPRequest(string floatingIPAddress)
17+
{
18+
FloatingIPAddress = floatingIPAddress;
19+
}
20+
21+
/// <summary>
22+
/// The floating IP address.
23+
/// </summary>
24+
[JsonProperty("address")]
25+
public string FloatingIPAddress { get; set; }
26+
27+
/// <summary>
28+
/// The fixed IP address with which you want to associate the floating IP address.
29+
/// </summary>
30+
[JsonProperty("fixed_address")]
31+
public string FixedIPAddress { get; set; }
32+
}
33+
}

src/corelib/Compute/v2_1/ComputeService.cs

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,6 @@ public ComputeService(IAuthenticationProvider authenticationProvider, string reg
109109
return _computeApi.DeleteServerMetadataAsync(serverId, key, cancellationToken);
110110
}
111111

112-
113112
/// <inheritdoc cref="ComputeApi.WaitUntilServerIsDeletedAsync{TServer,TStatus}" />
114113
public Task WaitUntilServerIsDeletedAsync(Identifier serverId, TimeSpan? refreshDelay = null, TimeSpan? timeout = null, IProgress<bool> progress = null, CancellationToken cancellationToken = default(CancellationToken))
115114
{
@@ -212,6 +211,18 @@ public ComputeService(IAuthenticationProvider authenticationProvider, string reg
212211
return _computeApi.CancelResizeServerAsync(serverId, cancellationToken);
213212
}
214213

214+
/// <inheritdoc cref="ComputeApi.AssociateFloatingIPAsync" />
215+
public virtual Task AssociateFloatingIPAddressAsync(Identifier serverId, AssociateFloatingIPRequest request, CancellationToken cancellationToken = default(CancellationToken))
216+
{
217+
return _computeApi.AssociateFloatingIPAsync(serverId, request, cancellationToken);
218+
}
219+
220+
/// <inheritdoc cref="ComputeApi.DisassociateFloatingIPAsync" />
221+
public virtual Task DisassociateFloatingIPAsync(Identifier serverId, string floatingIPAddress, CancellationToken cancellationToken = default(CancellationToken))
222+
{
223+
return _computeApi.DisassociateFloatingIPAsync(serverId, floatingIPAddress, cancellationToken);
224+
}
225+
215226
/// <inheritdoc cref="ComputeApi.ListServerActionSummariesAsync{T}" />
216227
public virtual async Task<IEnumerable<ServerActionSummary>> ListServerActionSummariesAsync(Identifier serverId, CancellationToken cancellationToken = default(CancellationToken))
217228
{

src/corelib/Compute/v2_1/ComputeServiceExtensions.cs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,18 @@ public static void CancelResizeServer(this ComputeService service, Identifier se
181181
service.CancelResizeServerAsync(serverId).ForceSynchronous();
182182
}
183183

184+
/// <inheritdoc cref="ComputeService.AssociateFloatingIPAddressAsync" />
185+
public static void AssociateFloatingIPAddressAsync(this ComputeService service, Identifier serverId, AssociateFloatingIPRequest request)
186+
{
187+
service.AssociateFloatingIPAddressAsync(serverId, request).ForceSynchronous();
188+
}
189+
190+
/// <inheritdoc cref="ComputeService.DisassociateFloatingIPAsync" />
191+
public static void DisassociateFloatingIPAsync(this ComputeService service, Identifier serverId, string floatingIPAddress)
192+
{
193+
service.DisassociateFloatingIPAsync(serverId, floatingIPAddress).ForceSynchronous();
194+
}
195+
184196
/// <inheritdoc cref="ComputeService.ListServerActionSummariesAsync" />
185197
public static IEnumerable<ServerActionSummary> ListServerActions(this ComputeService service, Identifier serverId)
186198
{
Lines changed: 2 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,8 @@
1-
using OpenStack.Serialization;
2-
31
namespace OpenStack.Compute.v2_1
42
{
53
/// <summary>
64
/// Internet Protocols.
75
/// </summary>
8-
public class IPProtocol : StringEnumeration
9-
{
10-
/// <summary />
11-
protected IPProtocol(string displayName)
12-
: base(displayName)
13-
{ }
14-
15-
/// <summary>
16-
/// ICMP
17-
/// </summary>
18-
public static readonly IPProtocol ICMP = new IPProtocol("icmp");
19-
20-
/// <summary>
21-
/// TCP
22-
/// </summary>
23-
public static readonly IPProtocol TCP = new IPProtocol("tcp");
24-
25-
/// <summary>
26-
/// UDP
27-
/// </summary>
28-
public static readonly IPProtocol UDP = new IPProtocol("udp");
29-
}
6+
public class IPProtocol : Networking.v2.Serialization.IPProtocol<IPProtocol>
7+
{ }
308
}

src/corelib/Compute/v2_1/Serialization/ComputeApi.cs

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -765,6 +765,37 @@ protected ComputeApi(IServiceType serviceType, IAuthenticationProvider authentic
765765
.SendAsync();
766766
}
767767

768+
/// <summary>
769+
/// Associates a floating IP address to the server.
770+
/// </summary>
771+
/// <param name="serverId">The server identifier.</param>
772+
/// <param name="request">The request.</param>
773+
/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
774+
/// <exception cref="ArgumentNullException"></exception>
775+
public virtual Task AssociateFloatingIPAsync(string serverId, object request, CancellationToken cancellationToken = default(CancellationToken))
776+
{
777+
return BuildServerActionRequest(serverId, request, cancellationToken).SendAsync();
778+
}
779+
780+
/// <summary>
781+
/// Disassociate a floating IP address from a server.
782+
/// </summary>
783+
/// <param name="serverId">The server identifier.</param>
784+
/// <param name="floatingIPAddress">The floating IP address to remove.</param>
785+
/// <param name="cancellationToken">A cancellation token that can be used by other objects or threads to receive notice of cancellation.</param>
786+
/// <exception cref="ArgumentNullException"></exception>
787+
public virtual Task DisassociateFloatingIPAsync(string serverId, string floatingIPAddress, CancellationToken cancellationToken = default(CancellationToken))
788+
{
789+
var request = new
790+
{
791+
removeFloatingIp = new
792+
{
793+
address = floatingIPAddress
794+
}
795+
};
796+
return BuildServerActionRequest(serverId, request, cancellationToken).SendAsync();
797+
}
798+
768799
/// <summary>
769800
/// Builds a server action request, where the server operation is specified in the request body.
770801
/// </summary>

0 commit comments

Comments
 (0)