Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License. See License.txt in the project root for license information.
/** * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for * license information. */
package com.microsoft.azure.management.network; import com.microsoft.azure.management.apigeneration.Beta; import com.microsoft.azure.management.apigeneration.Beta.SinceVersion; import com.microsoft.azure.management.apigeneration.Fluent; import com.microsoft.azure.management.network.model.HasNetworkInterfaces; import com.microsoft.azure.management.network.model.HasProtocol; import com.microsoft.azure.management.resources.fluentcore.arm.models.HasParent; import com.microsoft.azure.management.resources.fluentcore.model.Executable; import java.util.List;
A client-side representation allowing user to verify the possibility of establishing a direct TCP connection from a virtual machine to a given endpoint including another VM or an arbitrary remote server.
/** * A client-side representation allowing user to verify the possibility of establishing a direct TCP connection * from a virtual machine to a given endpoint including another VM or an arbitrary remote server. */
@Fluent @Beta(SinceVersion.V1_3_0) public interface ConnectivityCheck extends Executable<ConnectivityCheck>, HasParent<NetworkWatcher> {
Returns:list of hops between the source and the destination
/** * @return list of hops between the source and the destination */
List<ConnectivityHop> hops();
Returns:the connection status
/** * @return the connection status */
ConnectionStatus connectionStatus();
Returns:average latency in milliseconds
/** * @return average latency in milliseconds */
int avgLatencyInMs();
Returns:minimum latency in milliseconds
/** * @return minimum latency in milliseconds */
int minLatencyInMs();
Returns:maximum latency in milliseconds
/** * @return maximum latency in milliseconds */
int maxLatencyInMs();
Returns:total number of probes sent
/** * @return total number of probes sent */
int probesSent();
Returns:number of failed probes
/** * @return number of failed probes */
int probesFailed();
The entirety of connectivity check parameters definition.
/** * The entirety of connectivity check parameters definition. */
interface Definition extends DefinitionStages.ToDestination, DefinitionStages.ToDestinationPort, DefinitionStages.FromSourceVirtualMachine, DefinitionStages.WithExecute { }
Grouping of connectivity check parameters definition stages.
/** * Grouping of connectivity check parameters definition stages. */
interface DefinitionStages {
Sets the source property.
/** * Sets the source property. */
interface FromSourceVirtualMachine {
Params:
  • resourceId – the ID of the virtual machine from which a connectivity check will be initiated
Returns:next definition stage
/** * @param resourceId the ID of the virtual machine from which a connectivity check will be initiated * @return next definition stage */
WithExecute fromSourceVirtualMachine(String resourceId);
Params:
  • vm – virtual machine from which a connectivity check will be initiated
Returns:next definition stage
/** * @param vm virtual machine from which a connectivity check will be initiated * @return next definition stage */
WithExecute fromSourceVirtualMachine(HasNetworkInterfaces vm); }
Sets the destination property.
/** * Sets the destination property. */
interface ToDestination {
Params:
  • resourceId – the ID of the resource to which a connection attempt will be made
Returns:next definition stage
/** * @param resourceId the ID of the resource to which a connection attempt will be made * @return next definition stage */
ToDestinationPort toDestinationResourceId(String resourceId);
Params:
  • address – the IP address or URI the resource to which a connection attempt will be made
Returns:next definition stage
/** * @param address the IP address or URI the resource to which a connection attempt will be made * @return next definition stage */
ToDestinationPort toDestinationAddress(String address); }
Sets the destination port on which check connectivity will be performed.
/** * Sets the destination port on which check connectivity will be performed. */
interface ToDestinationPort {
Params:
  • port – destination port
Returns:next definition stage
/** * @param port destination port * @return next definition stage */
FromSourceVirtualMachine toDestinationPort(int port); }
Sets the source port from which a connectivity check will be performed.
/** * Sets the source port from which a connectivity check will be performed. */
interface FromSourcePort {
Params:
  • port – source port
Returns:next definition stage
/** * @param port source port * @return next definition stage */
WithExecute fromSourcePort(int port); }
The stage of the definition which contains all the minimum required inputs for execution, but also allows for any other optional settings to be specified.
/** * The stage of the definition which contains all the minimum required inputs for execution, but also allows * for any other optional settings to be specified. */
interface WithExecute extends Executable<ConnectivityCheck>, FromSourcePort, HasProtocol.DefinitionStages.WithProtocol<WithExecute, Protocol> { } } }